Buildroot Archive on lore.kernel.org
 help / color / mirror / Atom feed
From: jacmet at uclibc.org <jacmet@uclibc.org>
To: buildroot@busybox.net
Subject: [Buildroot] svn commit: trunk/buildroot/toolchain/external-toolchain
Date: Mon,  3 Nov 2008 02:32:59 -0800 (PST)	[thread overview]
Message-ID: <20081103103259.91CE53C685@busybox.net> (raw)

Author: jacmet
Date: 2008-11-03 02:32:59 -0800 (Mon, 03 Nov 2008)
New Revision: 23909

Log:
More external toolchain fixes

Fix issues with binary external toolchains

Fix two problems encountered while using an external binary toolchain
generated by crosstool-ng:

 - Don't remove the ending / in LIB_DIR, otherwise find $LIB_DIR
   -maxdepth 1 doesn't find any file in the case LIB_DIR is a symbolic
   link and not a directory.

   For some reason, find -maxdepth 1 doesn't have the same behaviour
   on directories and symbolic links. Demonstration:

   $ mkdir foobar
   $ touch foobar/t1
   $ touch foobar/t2
   $ ln -s foobar barfoo
   $ find foobar -maxdepth 1 -name 't*'
   foobar/t1
   foobar/t2
   $ find barfoo -maxdepth 1 -name 't*'
   $ find barfoo/ -maxdepth 1 -name 't*'
   barfoo/t1
   barfoo/t2

 * Make sure the libraries are writable, otherwise the strip operation
   might fail. The library files may not be writable if the toolchain
   is not writable (which may happen if one wants to prevent anyone
   from overwriting the toolchain, which is done by crosstool-ng, for
   example).

Signed-off-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>

Modified:
   trunk/buildroot/toolchain/external-toolchain/ext-tool.mk


Changeset:
Modified: trunk/buildroot/toolchain/external-toolchain/ext-tool.mk
===================================================================
--- trunk/buildroot/toolchain/external-toolchain/ext-tool.mk	2008-11-03 10:18:39 UTC (rev 23908)
+++ trunk/buildroot/toolchain/external-toolchain/ext-tool.mk	2008-11-03 10:32:59 UTC (rev 23909)
@@ -10,7 +10,7 @@
 	DST="$(strip $2)"; \
 	STRIP="$(strip $3)"; \
  \
-	LIB_DIR=`$(TARGET_CC) -print-file-name=$${LIB} | sed -e "s,/$${LIB}\$$,,"`; \
+	LIB_DIR=`$(TARGET_CC) -print-file-name=$${LIB} | sed -e "s,$${LIB}\$$,,"`; \
  \
 	if test -z "$${LIB_DIR}"; then \
 		echo "copy_toolchain_lib_root: lib=$${LIB} not found"; \
@@ -27,7 +27,7 @@
 			if test -h $${LIB_DIR}/$${LIB}; then \
 				cp -d $${LIB_DIR}/$${LIB} $(TARGET_DIR)$${DST}/; \
 			elif test -f $${LIB_DIR}/$${LIB}; then \
-				cp $${LIB_DIR}/$${LIB} $(TARGET_DIR)$${DST}/$${LIB}; \
+				$(INSTALL) -D -m0755 $${LIB_DIR}/$${LIB} $(TARGET_DIR)$${DST}/$${LIB}; \
 				case "$${STRIP}" in \
 				(0 | n | no) \
 ;; \

             reply	other threads:[~2008-11-03 10:32 UTC|newest]

Thread overview: 21+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2008-11-03 10:32 jacmet at uclibc.org [this message]
  -- strict thread matches above, loose matches on Subject: below --
2009-01-12 12:54 [Buildroot] svn commit: trunk/buildroot/toolchain/external-toolchain laird at uclibc.org
2008-11-03 10:37 jacmet at uclibc.org
2008-10-17 10:19 jacmet at uclibc.org
2008-06-16 12:22 jacmet at uclibc.org
2008-06-16 13:54 ` Bernhard Fischer
2008-06-16 14:07   ` Peter Korsgaard
2008-06-16 15:35     ` Bernhard Fischer
2008-06-17  4:23 ` Hamish Moffatt
2008-06-17  7:16   ` Peter Korsgaard
2008-06-17 10:47     ` Hamish Moffatt
2008-06-17 13:45       ` Peter Korsgaard
2008-06-17 14:29         ` Bernhard Fischer
2008-06-17 14:55           ` Peter Korsgaard
2008-06-17 15:45             ` Bernhard Fischer
2008-06-18  1:18         ` Hamish Moffatt
2008-06-18  7:36           ` Peter Korsgaard
2008-06-18  1:05       ` Hamish Moffatt
2007-07-17  0:18 sjhill at uclibc.org
2007-04-28 17:10 sjhill at uclibc.org
2007-04-19  2:04 sjhill at uclibc.org

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20081103103259.91CE53C685@busybox.net \
    --to=jacmet@uclibc.org \
    --cc=buildroot@busybox.net \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox