Bug 1893 - Interix fails build due to makedev() as wrong macro name
Interix fails build due to makedev() as wrong macro name
Status: CLOSED FIXED
Product: rsync
Classification: Unclassified
Component: core
2.6.3
All other
: P3 trivial
: ---
Assigned To: Wayne Davison
Rsync QA Contact
:
Depends on:
Blocks:
  Show dependency treegraph
 
Reported: 2004-10-08 13:51 UTC by Todd Vierling
Modified: 2005-04-01 11:21 UTC (History)
0 users

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Todd Vierling 2004-10-08 13:51:23 UTC
Under Interix (Windows Services for Unix), the build of rsync fails at link
because flist.c is calling makedev(), which is actually named mkdev() on Interix.

To make rsync compatible with this, I suggest the following change (similar to
what pkgsrc.org uses at the moment to make rsync work on Interix).

--- rsync.h.orig
+++ rsync.h
@@ -255,6 +255,9 @@ enum msgcode {
 
 #if MAJOR_IN_MKDEV
 #include <sys/mkdev.h>
+# if !defined(makedev) && defined(mkdev)
+#  define makedev mkdev
+# endif
 #elif MAJOR_IN_SYSMACROS
 #include <sys/sysmacros.h>
 #endif
Comment 1 Wayne Davison 2004-10-08 14:51:14 UTC
I checked-in your suggested fix.  Thanks!