]> code.ossystems Code Review - openembedded-core.git/commitdiff
sysvinit - Remove sulogin dependency on /usr/lib*/libcrypt.a
authorJeff Dike <jdike@x86_64.user-mode-linux.org>
Wed, 14 Jul 2010 18:35:52 +0000 (14:35 -0400)
committerRichard Purdie <rpurdie@linux.intel.com>
Thu, 15 Jul 2010 12:44:56 +0000 (13:44 +0100)
The sulogin compile checked for /usr/lib*/libcrypt.a to decide whether
to add -lcrypt to the final compile.  However, the recipe puts LCRYPT
in the environment, so crypt-lib.patch makes the Makefile check for
this before looking at the host /usr/lib.

Signed-off-by: Jeff Dike <jdike@linux.intel.com>
meta/packages/sysvinit/sysvinit-2.88dsf/crypt-lib.patch [new file with mode: 0644]
meta/packages/sysvinit/sysvinit_2.88dsf.bb

diff --git a/meta/packages/sysvinit/sysvinit-2.88dsf/crypt-lib.patch b/meta/packages/sysvinit/sysvinit-2.88dsf/crypt-lib.patch
new file mode 100644 (file)
index 0000000..b9511f0
--- /dev/null
@@ -0,0 +1,23 @@
+# The src Makefile was checking for libcrypt.a on the host, not in the
+# build environment.  This patch checks for $LCRYPT in the environment
+# and uses it if it's there.
+# - jdike@linux.intel.com
+
+Index: sysvinit-2.88dsf/src/Makefile
+===================================================================
+--- sysvinit-2.88dsf.orig/src/Makefile
++++ sysvinit-2.88dsf/src/Makefile
+@@ -85,9 +85,13 @@ else
+ endif
+ # Additional libs for GNU libc.
++ifneq ($(LCRYPT),)
++  SULOGINLIBS += $(LCRYPT)
++else
+ ifneq ($(wildcard /usr/lib*/libcrypt.a),)
+   SULOGINLIBS += -lcrypt
+ endif
++endif
+ all:          $(BIN) $(SBIN) $(USRBIN)
index d7821459debc773a6fd14faba15e195bb6557926..db38064548f99323fe4df2595f74f8f4c71f10f9 100644 (file)
@@ -4,7 +4,7 @@ SECTION = "base"
 LICENSE = "GPLv2+"
 LIC_FILES_CHKSUM = "file://COPYING;md5=751419260aa954499f7abaabaa882bbe \
                     file://COPYRIGHT;endline=15;md5=349c872e0066155e1818b786938876a4"
-PR = "r0"
+PR = "r1"
 
 # USE_VT and SERIAL_CONSOLE are generally defined by the MACHINE .conf.
 # Set PACKAGE_ARCH appropriately.
@@ -22,6 +22,7 @@ SYSVINIT_ENABLED_GETTYS ?= "1"
 
 SRC_URI = "http://download.savannah.gnu.org/releases-noredirect/sysvinit/sysvinit-${PV}.tar.bz2 \
           file://install.patch \
+          file://crypt-lib.patch \
            file://need \
            file://provide \
            file://inittab \