Skip to contentSkip to conversation

Fixes for 2010.05

GIT PULL New llandwerlin at gmail.com 3 participants 22 messages Apr 30, 2010 – May 2, 2010

lore
Share & tools
lore
#0 lore raw

Here are some patches already sent to the mailing list, taking into account reviews (thanks to people reviewing).

Available at :

          git://git.potipota.net/buildroot 2010.05-lionels-fixes

Regards,

--
Lionel Landwerlin

#1 lore raw

PATCH 1/8 package: Force copy of .la files at the post install hook (readonly files might be problematic)

From: Lionel Landwerlin <[email protected]>

---
 package/Makefile.autotools.in |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)
package/Makefile.autotools.in +1 -1
index a4be8c8..38e57cd 100644
@@ -200,7 +200,7 @@ ifndef $(2)_INSTALL_STAGING_CMDS
 define $(2)_INSTALL_STAGING_CMDS
 	$$($$(PKG)_MAKE_ENV) $$($$(PKG)_MAKE) $$($$(PKG)_INSTALL_STAGING_OPT) -C $$($$(PKG)_SRCDIR)
 	for i in $$$$(find $(STAGING_DIR)/usr/lib* -name "*.la"); do \
-		cp $$$$i $$$$i~; \
+		cp -f $$$$i $$$$i~; \
 		$$(SED) "s:\(['= ]\)/usr:\\1$(STAGING_DIR)/usr:g" $$$$i; \
 	done
 endef
Signature · 1 line
1.7.0.4
#2 lore raw

PATCH 1/8 package: Force copy of .la files at the post install hook (readonly files might be problematic)

Quoted 1 line
Quoted 1 line
Quoted 1 line
Quoted 1 line
Quoted 1 line

"llandwerlin" == llandwerlin <[email protected]> writes:

llandwerlin> From: Lionel Landwerlin <[email protected]> llandwerlin> Signed-off-by: Lionel Landwerlin <[email protected]>

Committed, thanks.

Signature · 1 line
Bye, Peter Korsgaard
#3 lore raw

PATCH 2/8 package: Add $(HOST_DIR)/usr/lib to LD_LIBRARY_PATH for host but not target

In reply to llandwerlin at gmail.com

From: Lionel Landwerlin <[email protected]>

Some packages like icu requires to be compiled against the host system first to be able to compile against the target. This is due to the usage of self generated binaries by the package to build itself. When the generated tools also depends on generated libraries it is required to add the path to these libraries in the library path (LD_LIBRARY_PATH) especially for the configure step.

Adding $(HOST_DIR)/usr/lib to LD_LIBRARY_PATH for target compilation might break the link step by mixing host libraries and target binaries.

---
 package/Makefile.in |    7 ++++---
 1 files changed, 4 insertions(+), 3 deletions(-)
package/Makefile.in +4 -3
index 3dfc712..507c59e 100644
@@ -205,11 +205,11 @@ TARGET_CONFIGURE_OPTS=PATH=$(TARGET_PATH) \
 		NM_FOR_TARGET="$(TARGET_NM)" \
 		DEFAULT_ASSEMBLER="$(TARGET_AS)" \
 		DEFAULT_LINKER="$(TARGET_LD)" \
+		PKG_CONFIG_ALLOW_SYSTEM_LIBS=1 \
 		PKG_CONFIG_SYSROOT_DIR="$(STAGING_DIR)" \
 		PKG_CONFIG="$(PKG_CONFIG_HOST_BINARY)" \
 		PKG_CONFIG_PATH="$(STAGING_DIR)/usr/lib/pkgconfig:$(PKG_CONFIG_PATH)" \
 		PERLLIB="$(HOST_DIR)/usr/lib/perl" \
-		LD_LIBRARY_PATH="$(HOST_DIR)/usr/lib" \
 		STAGING_DIR="$(STAGING_DIR)"
 
 TARGET_CONFIGURE_ENV=\
@@ -219,7 +219,6 @@ TARGET_CONFIGURE_ENV=\
 	FCFLAGS="$(TARGET_FCFLAGS)" \
 
 TARGET_MAKE_ENV=PATH=$(TARGET_PATH) \
-		LD_LIBRARY_PATH="$(HOST_DIR)/usr/lib:$(LD_LIBRARY_PATH)" \
 		PERLLIB="$(HOST_DIR)/usr/lib/perl"
 
 HOST_CONFIGURE_OPTS=PATH=$(HOST_PATH) \
@@ -257,9 +256,11 @@ HOST_CONFIGURE_OPTS=PATH=$(HOST_PATH) \
 		ORIGINAL_LD_FOR_TARGET="$(TARGET_LD)" \
 		ORIGINAL_NM_FOR_TARGET="$(TARGET_NM)" \
 		ORIGINAL_OBJDUMP_FOR_TARGET="$(TARGET_OBJDUMP)" \
+		PKG_CONFIG_ALLOW_SYSTEM_LIBS=1 \
 		PKG_CONFIG="$(PKG_CONFIG_HOST_BINARY)" \
 		PKG_CONFIG_LIBDIR="$(HOST_DIR)/usr/lib/pkgconfig" \
-		PERLLIB="$(HOST_DIR)/usr/lib/perl"
+		PERLLIB="$(HOST_DIR)/usr/lib/perl" \
+		LD_LIBRARY_PATH="$(HOST_DIR)/usr/lib:$(LD_LIBRARY_PATH)"
 
 HOST_MAKE_ENV=PATH=$(HOST_PATH) \
 		LD_LIBRARY_PATH="$(HOST_DIR)/usr/lib:$(LD_LIBRARY_PATH)" \
Signature · 1 line
1.7.0.4
#4 lore raw

PATCH 1/1 package: Add $(HOST_DIR)/usr/lib to LD_LIBRARY_PATH for host but not target

From: Lionel Landwerlin <[email protected]>

Some packages like icu requires to be compiled against the host system first to be able to compile against the target. This is due to the usage of self generated binaries by the package to build itself. When the generated tools also depends on generated libraries it is required to add the path to these libraries in the library path (LD_LIBRARY_PATH) especially for the configure step.

Adding $(HOST_DIR)/usr/lib to LD_LIBRARY_PATH for target compilation might break the link step by mixing host libraries and target binaries.

---
 package/Makefile.in |    6 +++---
 1 files changed, 3 insertions(+), 3 deletions(-)
package/Makefile.in +3 -3
index 3dfc712..6d99205 100644
@@ -209,7 +209,6 @@ TARGET_CONFIGURE_OPTS=PATH=$(TARGET_PATH) \
 		PKG_CONFIG="$(PKG_CONFIG_HOST_BINARY)" \
 		PKG_CONFIG_PATH="$(STAGING_DIR)/usr/lib/pkgconfig:$(PKG_CONFIG_PATH)" \
 		PERLLIB="$(HOST_DIR)/usr/lib/perl" \
-		LD_LIBRARY_PATH="$(HOST_DIR)/usr/lib" \
 		STAGING_DIR="$(STAGING_DIR)"
 
 TARGET_CONFIGURE_ENV=\
@@ -219,7 +218,6 @@ TARGET_CONFIGURE_ENV=\
 	FCFLAGS="$(TARGET_FCFLAGS)" \
 
 TARGET_MAKE_ENV=PATH=$(TARGET_PATH) \
-		LD_LIBRARY_PATH="$(HOST_DIR)/usr/lib:$(LD_LIBRARY_PATH)" \
 		PERLLIB="$(HOST_DIR)/usr/lib/perl"
 
 HOST_CONFIGURE_OPTS=PATH=$(HOST_PATH) \
@@ -257,9 +255,11 @@ HOST_CONFIGURE_OPTS=PATH=$(HOST_PATH) \
 		ORIGINAL_LD_FOR_TARGET="$(TARGET_LD)" \
 		ORIGINAL_NM_FOR_TARGET="$(TARGET_NM)" \
 		ORIGINAL_OBJDUMP_FOR_TARGET="$(TARGET_OBJDUMP)" \
+		PKG_CONFIG_ALLOW_SYSTEM_LIBS=1 \
 		PKG_CONFIG="$(PKG_CONFIG_HOST_BINARY)" \
 		PKG_CONFIG_LIBDIR="$(HOST_DIR)/usr/lib/pkgconfig" \
-		PERLLIB="$(HOST_DIR)/usr/lib/perl"
+		PERLLIB="$(HOST_DIR)/usr/lib/perl" \
+		LD_LIBRARY_PATH="$(HOST_DIR)/usr/lib:$(LD_LIBRARY_PATH)"
 
 HOST_MAKE_ENV=PATH=$(HOST_PATH) \
 		LD_LIBRARY_PATH="$(HOST_DIR)/usr/lib:$(LD_LIBRARY_PATH)" \
Signature · 1 line
1.7.0.4
#5 lore raw

PATCH 3/8 scripts: force copy of files to erase already present and readonly files

In reply to llandwerlin at gmail.com

From: Lionel Landwerlin <[email protected]>

---
 scripts/copy.sh |    4 ++--
 1 files changed, 2 insertions(+), 2 deletions(-)
scripts/copy.sh +2 -2
index 410606d..508ed56 100755
@@ -5,7 +5,7 @@ TARGET_DIR=$2
 
 echo "Copying development files to target..."
 
-cp -a ${STAGING_DIR}/usr/include ${TARGET_DIR}/usr
+cp -af ${STAGING_DIR}/usr/include ${TARGET_DIR}/usr
 
 for LIBSDIR in /lib /usr/lib; do
 	for WILDCARD in *.a *.la; do
@@ -13,7 +13,7 @@ for LIBSDIR in /lib /usr/lib; do
 			STAGING_STRIPPED=${FILE_PATH##${STAGING_DIR}}
 			EXTENDED_DIR=${STAGING_STRIPPED%/${WILDCARD}}
 			mkdir -p ${TARGET_DIR}${EXTENDED_DIR}
-			cp ${FILE_PATH} ${TARGET_DIR}${STAGING_STRIPPED}
+			cp -fa ${FILE_PATH} ${TARGET_DIR}${STAGING_STRIPPED}
 			#echo ${TARGET_DIR}${STAGING_STRIPPED}
 		done
 	done
Signature · 1 line
1.7.0.4
#6 lore raw

PATCH 3/8 scripts: force copy of files to erase already present and readonly files

Quoted 1 line
Quoted 1 line
Quoted 1 line
Quoted 1 line
Quoted 1 line

"llandwerlin" == llandwerlin <[email protected]> writes:

llandwerlin> From: Lionel Landwerlin <[email protected]> llandwerlin> Signed-off-by: Lionel Landwerlin <[email protected]>

Committed, thanks.

Signature · 1 line
Bye, Peter Korsgaard
#7 lore raw

PATCH 4/8 package: added PKG_CONF_ENV variables to host packages

In reply to llandwerlin at gmail.com

From: Lionel Landwerlin <[email protected]>

---
 package/Makefile.autotools.in |    1 +
 1 files changed, 1 insertions(+), 0 deletions(-)
package/Makefile.autotools.in +1 -0
index 38e57cd..b7a7103 100644
@@ -108,6 +108,7 @@ define $(2)_CONFIGURE_CMDS
 	        $$(HOST_CONFIGURE_OPTS) \
 		CFLAGS="$$(HOST_CFLAGS)" \
 		LDFLAGS="$$(HOST_LDFLAGS)" \
+                $$($$(PKG)_CONF_ENV) \
 		./configure \
 		--prefix="$$(HOST_DIR)/usr" \
 		--sysconfdir="$$(HOST_DIR)/etc" \
Signature · 1 line
1.7.0.4
#8 lore raw

PATCH 4/8 package: added PKG_CONF_ENV variables to host packages

Quoted 3 lines · On Fri, 30 Apr 2010 02:24:09 +0200 llandwerlin at gmail.com wrote:

From: Lionel Landwerlin <[email protected]>

Signature · 4 lines
Thomas Petazzoni, Free Electrons
Kernel, drivers, real-time and embedded Linux
development, consulting, training and support.
http://free-electrons.com
#10 lore raw

PATCH 5/8 libtool: added LIBTOOLIZE variable to point on $(HOST_DIR)/usr/bin/libtoolize

In reply to llandwerlin at gmail.com

From: Lionel Landwerlin <[email protected]>

---
 package/libtool/libtool.mk |    1 +
 1 files changed, 1 insertions(+), 0 deletions(-)
package/libtool/libtool.mk +1 -0
index bbabbb0..4278029 100644
@@ -25,3 +25,4 @@ $(eval $(call AUTOTARGETS,package,libtool,host))
 
 # variables used by other packages
 LIBTOOL:=$(HOST_DIR)/usr/bin/libtool
+LIBTOOLIZE:=$(HOST_DIR)/usr/bin/libtoolize
Signature · 1 line
1.7.0.4
#11 lore raw

PATCH 5/8 libtool: added LIBTOOLIZE variable to point on $(HOST_DIR)/usr/bin/libtoolize

Quoted 3 lines · On Fri, 30 Apr 2010 02:24:10 +0200 llandwerlin at gmail.com wrote:

From: Lionel Landwerlin <[email protected]>

Signature · 4 lines
Thomas Petazzoni, Free Electrons
Kernel, drivers, real-time and embedded Linux
development, consulting, training and support.
http://free-electrons.com
#13 lore raw

PATCH 6/8 autoconf: added AUTOHEADER variable

In reply to llandwerlin at gmail.com

From: Lionel Landwerlin <[email protected]>

autoheader is used by autoreconf, therefor we need to give the right path to this tools for host/target autoreconfiguration.

---
 package/autoconf/autoconf.mk |    5 +++--
 1 files changed, 3 insertions(+), 2 deletions(-)
package/autoconf/autoconf.mk +3 -2
index d82c2c5..b7c1fe4 100644
@@ -17,7 +17,7 @@ AUTOCONF_CONF_ENV = EMACS="no" ac_cv_path_M4=$(HOST_DIR)/usr/bin/m4 \
 AUTOCONF_DEPENDENCIES = microperl host-m4
 
 HOST_AUTOCONF_CONF_ENV = ac_cv_path_M4=$(HOST_DIR)/usr/bin/m4 \
-                    	 ac_cv_prog_gnu_m4_gnu=no
+			ac_cv_prog_gnu_m4_gnu=no
 
 HOST_AUTOCONF_DEPENDENCIES = host-m4 host-libtool
 
@@ -26,4 +26,5 @@ $(eval $(call AUTOTARGETS,package,autoconf,host))
 
 # variables used by other packages
 AUTOCONF:=$(HOST_DIR)/usr/bin/autoconf
-AUTORECONF=$(HOST_CONFIGURE_OPTS) ACLOCAL="$(ACLOCAL)" $(HOST_DIR)/usr/bin/autoreconf -v -f -i -I "$(ACLOCAL_DIR)"
+AUTOHEADER:=$(HOST_DIR)/usr/bin/autoheader
+AUTORECONF=$(HOST_CONFIGURE_OPTS) ACLOCAL="$(ACLOCAL)" AUTOHEADER="$(AUTOHEADER)" $(HOST_DIR)/usr/bin/autoreconf -v -f -i -I "$(ACLOCAL_DIR)"
Signature · 1 line
1.7.0.4
#14 lore raw

PATCH 6/8 autoconf: added AUTOHEADER variable

Quoted 6 lines · On Fri, 30 Apr 2010 02:24:11 +0200 llandwerlin at gmail.com wrote:

From: Lionel Landwerlin <[email protected]>

autoheader is used by autoreconf, therefor we need to give the right path to this tools for host/target autoreconfiguration.

Signature · 4 lines
Thomas Petazzoni, Free Electrons
Kernel, drivers, real-time and embedded Linux
development, consulting, training and support.
http://free-electrons.com
#15 lore raw

PATCH 6/8 autoconf: added AUTOHEADER variable

In reply to llandwerlin at gmail.com
Quoted 1 line
Quoted 1 line
Quoted 1 line
Quoted 1 line
Quoted 1 line

"llandwerlin" == llandwerlin <[email protected]> writes:

llandwerlin> From: Lionel Landwerlin <[email protected]> llandwerlin> autoheader is used by autoreconf, therefor we need to give the right llandwerlin> path to this tools for host/target autoreconfiguration.

llandwerlin> Signed-off-by: Lionel Landwerlin <[email protected]>

Committed, thanks

Signature · 1 line
Bye, Peter Korsgaard
#16 lore raw

PATCH 7/8 autoconf: added missing AUTOMAKE variable setting

In reply to llandwerlin at gmail.com

From: Lionel Landwerlin <[email protected]>

---
 package/autoconf/autoconf.mk |    2 +-
 package/automake/automake.mk |    2 +-
 2 files changed, 2 insertions(+), 2 deletions(-)
package/autoconf/autoconf.mk +1 -1
index b7c1fe4..722165c 100644
@@ -27,4 +27,4 @@ $(eval $(call AUTOTARGETS,package,autoconf,host))
 # variables used by other packages
 AUTOCONF:=$(HOST_DIR)/usr/bin/autoconf
 AUTOHEADER:=$(HOST_DIR)/usr/bin/autoheader
-AUTORECONF=$(HOST_CONFIGURE_OPTS) ACLOCAL="$(ACLOCAL)" AUTOHEADER="$(AUTOHEADER)" $(HOST_DIR)/usr/bin/autoreconf -v -f -i -I "$(ACLOCAL_DIR)"
+AUTORECONF=$(HOST_CONFIGURE_OPTS) ACLOCAL="$(ACLOCAL)" AUTOHEADER="$(AUTOHEADER)" AUTOMAKE="$(AUTOMAKE)" $(HOST_DIR)/usr/bin/autoreconf -v -f -i -I "$(ACLOCAL_DIR)"
package/automake/automake.mk +1 -1
index db935a4..46bb773 100644
@@ -25,6 +25,6 @@ $(eval $(call AUTOTARGETS,package,automake))
 $(eval $(call AUTOTARGETS,package,automake,host))
 
 # variables used by other packages
-AUTOMAKE:=$(HOST_DIR)/usr/bin/automake
+AUTOMAKE = $(HOST_DIR)/usr/bin/automake
 ACLOCAL_DIR = $(STAGING_DIR)/usr/share/aclocal
 ACLOCAL = $(HOST_DIR)/usr/bin/aclocal -I $(ACLOCAL_DIR)
Signature · 1 line
1.7.0.4
#17 lore raw

PATCH 7/8 autoconf: added missing AUTOMAKE variable setting

Quoted 3 lines · On Fri, 30 Apr 2010 02:24:12 +0200 llandwerlin at gmail.com wrote:

From: Lionel Landwerlin <[email protected]>

Signature · 4 lines
Thomas Petazzoni, Free Electrons
Kernel, drivers, real-time and embedded Linux
development, consulting, training and support.
http://free-electrons.com
#19 lore raw

PATCH 8/8 autoconf: added AUTOCONF variable setting

In reply to llandwerlin at gmail.com

From: Lionel Landwerlin <[email protected]>

---
 package/autoconf/autoconf.mk |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)
package/autoconf/autoconf.mk +1 -1
index 722165c..e98205e 100644
@@ -27,4 +27,4 @@ $(eval $(call AUTOTARGETS,package,autoconf,host))
 # variables used by other packages
 AUTOCONF:=$(HOST_DIR)/usr/bin/autoconf
 AUTOHEADER:=$(HOST_DIR)/usr/bin/autoheader
-AUTORECONF=$(HOST_CONFIGURE_OPTS) ACLOCAL="$(ACLOCAL)" AUTOHEADER="$(AUTOHEADER)" AUTOMAKE="$(AUTOMAKE)" $(HOST_DIR)/usr/bin/autoreconf -v -f -i -I "$(ACLOCAL_DIR)"
+AUTORECONF=$(HOST_CONFIGURE_OPTS) ACLOCAL="$(ACLOCAL)" AUTOCONF="$(AUTOCONF)" AUTOHEADER="$(AUTOHEADER)" AUTOMAKE="$(AUTOMAKE)" $(HOST_DIR)/usr/bin/autoreconf -v -f -i -I "$(ACLOCAL_DIR)"
Signature · 1 line
1.7.0.4
#20 lore raw

PATCH 8/8 autoconf: added AUTOCONF variable setting

Quoted 3 lines · On Fri, 30 Apr 2010 02:24:13 +0200 llandwerlin at gmail.com wrote:

From: Lionel Landwerlin <[email protected]>

Signature · 4 lines
Thomas Petazzoni, Free Electrons
Kernel, drivers, real-time and embedded Linux
development, consulting, training and support.
http://free-electrons.com