[Buildroot] gcc 4.2.2 patch

Bernhard Fischer rep.dot.nop at gmail.com
Fri Mar 28 20:41:36 UTC 2008


On Fri, Mar 28, 2008 at 08:22:02PM +0000, Nigel Kukard wrote:
>Is this patch ok to bump gcc to 4.2.2?
>
>I grep -r'd the buildroot tree and replaced each occurrence manually and
>removed 4.2.0.
>
>-N

>Index: package/lvm2/lvm2.mk
>===================================================================
>--- package/lvm2/lvm2.mk	(revision 21539)
>+++ package/lvm2/lvm2.mk	(working copy)
>@@ -64,7 +64,7 @@
> $(LVM2_TARGET_SBINS): $(LVM2_DIR)/.configured
> 	$(MAKE) CC=$(TARGET_CC) -C $(LVM2_DIR) DESTDIR=$(STAGING_DIR)
> 	$(MAKE) CC=$(TARGET_CC) -C $(LVM2_DIR) DESTDIR=$(STAGING_DIR) install
>-	for binary in $(LVM2_SBIN); do echo $$binary; cp -a $(STAGING_DIR)/sbin/$$binary $(TARGET_DIR)/sbin; done
>+	for binary in $(LVM2_SBIN); do echo $$binary; install -m0755 -p $(STAGING_DIR)/sbin/$$binary $(TARGET_DIR)/sbin; done

close.
Correct would have been to use $(INSTALL). Also the for loop doesn't
make too much sense, fwiw.

Something like this should do everything that is needed and is not
bloated:
	$(INSTALL) -D -m0755 $(patsubst %,$(STAGING_DIR)/sbin/%,$(LVM2_SBIN)) $(TARGET_DIR)/sbin/

Remember that this is *make* and not your favourite shell..



More information about the buildroot mailing list