Skip to contentSkip to conversation

fix packages/config on OS X

PATCH New Heikki Lindholm 2 participants 2 messages Jul 17, 2007

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 fix packages/config on OS X

Update to linux 2.6.21 config system broke packages/config on OS X. The following patch should allow it to build again. Note that "dylib" is hard-coded in check-lxdialog because HOST_SHREXT, which would be nicer, is not available at that point.

-- Heikki Lindholm
-------------- next part --------------
An embedded and charset-unspecified text was scrubbed...
Name: buildroot-070717-config.patch
Url: http://busybox.net/lists/buildroot/attachments/20070717/f9f47994/attachment.diff

#1 lore raw

PATCH 1/1 fix packages/config on OS X

Quoted 28 lines · Heikki Lindholm

Update to linux 2.6.21 config system broke packages/config on OS X. The following patch should allow it to build again. Note that "dylib" is hard-coded in check-lxdialog because HOST_SHREXT, which would be nicer, is not available at that point.

-- Heikki Lindholm

Index: package/config/lxdialog/check-lxdialog.sh
===================================================================

config/lxdialog/check-lxdialog.sh (working copy) renamed from config/lxdialog/check-lxdialog.sh (revision 19125) +5 -0
@@ -19,6 +19,11 @@
                echo '-lcurses'
                exit
        fi
+       $cc -print-file-name=libncurses.dylib | grep -q /
+       if [ $? -eq 0 ]; then
+               echo '-lncurses'
+               exit
+       fi
        exit 1
 }
 

Index: package/config/foo.h
===================================================================

config/foo.h (working copy) line 8

Quoted 8 lines
config/foo.h (working copy) renamed from config/foo.h (revision 19125) +2 -0
@@ -1,6 +1,8 @@
 #ifndef __KCONFIG_FOO_H
 #define __KCONFIG_FOO_H
+#ifndef __APPLE__
 #include <features.h>
+#endif
 #include <limits.h>
 
 #ifndef PATH_MAX

This second patch, I posted a while back asking if anyone needed features.h. I didn't get any response. I noticed in Linux, it's not needed. Not sure what platform actually needs features.h here. __APPLE__ is defined by Apple's GCC? cool.

Allan