Define _XOPEN_SOURCE when building to get crypt() from <unistd.h> instead of using...
authorPetter Reinholdtsen <pere@hungry.com>
Mon, 27 Jan 2014 22:05:54 +0000 (22:05 +0000)
committerPetter Reinholdtsen <pere@hungry.com>
Mon, 27 Jan 2014 22:05:54 +0000 (22:05 +0000)
git-svn-id: svn://svn.sv.gnu.org/sysvinit/sysvinit/trunk@137 456724a4-4300-0410-8514-c89748c515a2

doc/Changelog
src/Makefile
src/sulogin.c

index 2f77b13f18fb7f07000000628469f5279b62b872..84db0529146cb5cc894bf3b1e863e902b6dc95bf 100644 (file)
@@ -64,6 +64,9 @@ sysvinit (2.89dsf) UNRELEASED; urgency=low
   * Move dovoid() macro from #ifdef__GLIBC__ to #ifdef __linux__,
     to match the condutions of the place where it is used.  Thanks
     to Matias A. Fonzo for noticing.
+  * Define _XOPEN_SOURCE when building to get crypt() from <unistd.h>
+    instead of using <crypt.h> in sulogin.c, to get the source building
+    with the musl C library.
 
  -- Petter Reinholdtsen <pere@hungry.com>  Sun Apr 11 11:28:55 CEST 2010
 
index 9d17febfe7902dd15366e61a213661ebb002b5bf..2189eebb12fa5ba543bea4cdc9da0ab85129377b 100644 (file)
@@ -10,7 +10,7 @@
 
 CPPFLAGS =
 CFLAGS ?= -ansi -O2 -fomit-frame-pointer
-override CFLAGS += -W -Wall -D_GNU_SOURCE
+override CFLAGS += -W -Wall -D_XOPEN_SOURCE -D_GNU_SOURCE
 STATIC =
 MANDB  := s@^\('\\\\\"\)[^\*-]*-\*- coding: [^[:blank:]]\+ -\*-@\1@
 
index 66dfd2c99275bb10df0b65eb5fc79739ed528a77..68c2aa9392e275d58611584754c765df0036670e 100644 (file)
@@ -44,9 +44,6 @@
 #include <sys/ttydefaults.h>
 #include <errno.h>
 #include <sys/ioctl.h>
-#if defined(__GLIBC__)
-#  include <crypt.h>
-#endif
 #ifdef __linux__
 #  include <sys/statfs.h>
 #  include <sys/mount.h>