standardize handling of GNU configure scripts
authorEric Andersen <andersen@codepoet.org>
Fri, 17 Jan 2003 08:03:59 +0000 (08:03 -0000)
committerEric Andersen <andersen@codepoet.org>
Fri, 17 Jan 2003 08:03:59 +0000 (08:03 -0000)
 -Erik

26 files changed:
Makefile
make/autoconf.mk
make/automake.mk
make/bash.mk
make/berkeleydb.mk
make/coreutils.mk
make/ext2root.mk
make/findutils.mk
make/gawk.mk
make/gdb.mk
make/gdbserver.mk
make/libglib12.mk
make/libtool.mk
make/links.mk
make/m4.mk
make/make.mk
make/ncurses.mk
make/newt.mk
make/openssh.mk
make/openssl.mk
make/sed.mk
make/socat.mk
make/strace.mk
make/uclibc_toolchain.mk
make/valgrind.mk
make/zlib.mk

index 8e1f4d3e36f6df9aca6dc411860dd22bd502bee9..cde7e4cc2fcdc6366532abe6a316609e9250160a 100644 (file)
--- a/Makefile
+++ b/Makefile
@@ -55,14 +55,14 @@ BUILD_WITH_LARGEFILE:=true
 WGET:=wget --passive-ftp
 
 # Optimize toolchain for which type of CPU?
-#OPTIMIZE_FOR_CPU:=i486
-#OPTIMIZE_FOR_CPU:=strongarm
-#OPTIMIZE_FOR_CPU:=whatever
-OPTIMIZE_FOR_CPU:=$(ARCH)
+OPTIMIZE_FOR_CPU=$(ARCH)
+#OPTIMIZE_FOR_CPU=i486
+#OPTIMIZE_FOR_CPU=strongarm
+#OPTIMIZE_FOR_CPU=whatever
 
 # Any additional gcc options you may want to include....
-#EXTRA_GCC_CONFIG_OPTIONS:=--without-float
-EXTRA_GCC_CONFIG_OPTIONS:=
+EXTRA_GCC_CONFIG_OPTIONS=
+#EXTRA_GCC_CONFIG_OPTIONS=--without-float
 
 #############################################################
 #
@@ -135,7 +135,8 @@ TARGET_PATH:=$(STAGING_DIR)/bin:$(STAGING_DIR)/usr/bin:/bin:/sbin:/usr/bin:/usr/
 STRIP:=$(TARGET_CROSS)strip --remove-section=.comment --remove-section=.note
 #STRIP:=/bin/true
 IMAGE:=$(BASE_DIR)/root_fs
-GNU_TARGET_NAME:=$(OPTIMIZE_FOR_CPU)-pc-linux-gnu
+MAKE:=make
+GNU_TARGET_NAME:=$(OPTIMIZE_FOR_CPU)-unknown-linux-gnu
 ifneq ($(strip $(ARCH)),i386)
 CROSS:=$(ARCH)-linux-
 endif
index 0ba80381ab0487a86069aab722e060c7fb99dcc5..5554061a91534354879036ddfe84dd580317ad69 100644 (file)
@@ -20,11 +20,20 @@ $(AUTOCONF_DIR)/.unpacked: $(DL_DIR)/$(AUTOCONF_SOURCE)
        touch $(AUTOCONF_DIR)/.unpacked
 
 $(AUTOCONF_DIR)/.configured: $(AUTOCONF_DIR)/.unpacked
-       (cd $(AUTOCONF_DIR); rm -f config.cache; CC=$(TARGET_CC1) \
-           CFLAGS=-D_POSIX_SOURCE EMACS="no" ./configure \
-               --target=i386-uclibc \
+       (cd $(AUTOCONF_DIR); rm -rf config.cache; PATH=$(STAGING_DIR)/bin:$$PATH \
+               CC=$(TARGET_CC1) EMACS="no" \
+               ./configure \
+               --target=$(GNU_TARGET_NAME) \
                --prefix=/usr \
                --exec-prefix=/usr \
+               --bindir=/usr/bin \
+               --sbindir=/usr/sbin \
+               --libexecdir=/usr/lib \
+               --sysconfdir=/etc \
+               --datadir=/usr/share \
+               --localstatedir=/var \
+               --mandir=/usr/man \
+               --infodir=/usr/info \
        );
        touch  $(AUTOCONF_DIR)/.configured
 
@@ -53,7 +62,7 @@ autoconf: uclibc $(TARGET_DIR)/$(AUTOCONF_TARGET_BINARY)
 
 autoconf-clean:
        $(MAKE) DESTDIR=$(TARGET_DIR) CC=$(TARGET_CC1) -C $(AUTOCONF_DIR) uninstall
-       -make -C $(AUTOCONF_DIR) clean
+       -$(MAKE) -C $(AUTOCONF_DIR) clean
 
 autoconf-dirclean:
        rm -rf $(AUTOCONF_DIR)
index 52ffebb4a28c5302e8a1b5e34283a0d535ed4e6d..32b16eaa808c059b94f88479d06cabf4f5a60c0c 100644 (file)
@@ -20,11 +20,20 @@ $(AUTOMAKE_DIR)/.unpacked: $(DL_DIR)/$(AUTOMAKE_SOURCE)
        touch $(AUTOMAKE_DIR)/.unpacked
 
 $(AUTOMAKE_DIR)/.configured: $(AUTOMAKE_DIR)/.unpacked
-       (cd $(AUTOMAKE_DIR); rm -f config.cache; CC=$(TARGET_CC1) \
-           CFLAGS=-D_POSIX_SOURCE ./configure \
-               --target=i386-uclibc \
+       (cd $(AUTOMAKE_DIR); rm -rf config.cache; \
+               PATH=$(STAGING_DIR)/bin:$$PATH CC=$(TARGET_CC1) \
+               ./configure \
+               --target=$(GNU_TARGET_NAME) \
                --prefix=/usr \
                --exec-prefix=/usr \
+               --bindir=/usr/bin \
+               --sbindir=/usr/sbin \
+               --libexecdir=/usr/lib \
+               --sysconfdir=/etc \
+               --datadir=/usr/share \
+               --localstatedir=/var \
+               --mandir=/usr/man \
+               --infodir=/usr/info \
        );
        touch  $(AUTOMAKE_DIR)/.configured
 
@@ -55,7 +64,7 @@ automake: uclibc $(TARGET_DIR)/$(AUTOMAKE_TARGET_BINARY)
 
 automake-clean:
        $(MAKE) DESTDIR=$(TARGET_DIR) CC=$(TARGET_CC1) -C $(AUTOMAKE_DIR) uninstall
-       -make -C $(AUTOMAKE_DIR) clean
+       -$(MAKE) -C $(AUTOMAKE_DIR) clean
 
 automake-dirclean:
        rm -rf $(AUTOMAKE_DIR)
index dc11c36090c7b9da9b4b016480156f855559f79e..c52795fb25253be37106ec16c33867c0567782d0 100644 (file)
@@ -20,10 +20,23 @@ $(BASH_DIR)/.unpacked: $(DL_DIR)/$(BASH_SOURCE)
        touch $(BASH_DIR)/.unpacked
 
 $(BASH_DIR)/.configured: $(BASH_DIR)/.unpacked
-       (cd $(BASH_DIR); autoconf; rm -f config.cache; CC=$(TARGET_CC1) \
-           CFLAGS=-D_POSIX_SOURCE ./configure --prefix=/usr --disable-nls \
-           --mandir=/junk --infodir=/junk \
-           --with-curses --enable-alias \
+       (cd $(BASH_DIR); rm -rf config.cache; \
+               PATH=$(STAGING_DIR)/bin:$$PATH CC=$(TARGET_CC1) \
+               ./configure \
+               --target=$(GNU_TARGET_NAME) \
+               --prefix=/usr \
+               --exec-prefix=/usr \
+               --bindir=/usr/bin \
+               --sbindir=/usr/sbin \
+               --libexecdir=/usr/lib \
+               --sysconfdir=/etc \
+               --datadir=/usr/share \
+               --localstatedir=/var \
+               --mandir=/usr/man \
+               --infodir=/usr/info \
+               --disable-nls \
+               --with-curses \
+               --enable-alias \
        );
        touch  $(BASH_DIR)/.configured
 
@@ -40,7 +53,7 @@ bash: ncurses uclibc $(TARGET_DIR)/$(BASH_TARGET_BINARY)
 
 bash-clean:
        $(MAKE) DESTDIR=$(TARGET_DIR) CC=$(TARGET_CC1) -C $(BASH_DIR) uninstall
-       -make -C $(BASH_DIR) clean
+       -$(MAKE) -C $(BASH_DIR) clean
 
 bash-dirclean:
        rm -rf $(BASH_DIR)
index 09680ef5f06dd1153d72c4e711b3757214dab6a2..7c5d083343fe23b28148a7d04848b1d8c456a57a 100644 (file)
@@ -17,23 +17,31 @@ $(DB_DIR)/.dist: $(DL_DIR)/$(DB_SOURCE)
        zcat $(DL_DIR)/$(DB_SOURCE) | tar -C $(BUILD_DIR) -xvf -
        touch  $(DB_DIR)/.dist
 
-$(DB_DIR)/build_unix/Makefile: $(DB_DIR)/.dist
-       (cd $(DB_DIR)/build_unix; PATH="$(TARGET_PATH)" \
-       CC=$(TARGET_CC1) ../dist/configure \
-                       --prefix=/usr \
-                       --localstatedir=/var \
-                       --sysconfdir=/etc \
-                       --libexecdir=/usr/sbin \
-                       --mandir=/usr/share/man \
-                       --enable-shared=yes \
-       )
-
-$(DB_DIR)/build_unix/.libs/libdb-4.0.so: $(DB_DIR)/build_unix/Makefile
-       PATH="$(TARGET_PATH)" make -C $(DB_DIR)/build_unix  
+$(DB_DIR)/.configured: $(DB_DIR)/.dist
+       (cd $(DB_DIR)/build_unix; rm -rf config.cache; \
+               PATH=$(STAGING_DIR)/bin:$$PATH CC=$(TARGET_CC1) \
+               ../dist/configure \
+               --target=$(GNU_TARGET_NAME) \
+               --prefix=/usr \
+               --exec-prefix=/usr \
+               --bindir=/usr/bin \
+               --sbindir=/usr/sbin \
+               --libexecdir=/usr/lib \
+               --sysconfdir=/etc \
+               --datadir=/usr/share \
+               --localstatedir=/var \
+               --mandir=/usr/man \
+               --infodir=/usr/info \
+               --enable-shared \
+       );
+       touch  $(DB_DIR)/.configured
+
+$(DB_DIR)/build_unix/.libs/libdb-4.0.so: $(DB_DIR)/.configured
+       $(MAKE) CC=$(TARGET_CC1) -C $(DB_DIR)/build_unix
 
 $(STAGING_DIR)/lib/libdb-4.0.so: $(DB_DIR)/build_unix/.libs/libdb-4.0.so
        -mkdir -p $(STAGING_DIR)/man/man1
-       PATH="$(TARGET_PATH)" make -C $(DB_DIR)/build_unix prefix=$(STAGING_DIR) install
+       $(MAKE) DESTDIR=$(STAGING_DIR) CC=$(TARGET_CC1) -C $(DB_DIR)/build_unix install 
        rm -rf $(STAGING_DIR)/man/man1
 
 $(TARGET_DIR)/lib/libdb-4.0.so: $(STAGING_DIR)/lib/libdb-4.0.so
@@ -43,7 +51,7 @@ $(TARGET_DIR)/lib/libdb-4.0.so: $(STAGING_DIR)/lib/libdb-4.0.so
        -$(STRIP) --strip-unneeded $(TARGET_DIR)/lib//libdb*so*
 
 db-clean: 
-       make -C $(DB_DIR)/build_unix clean
+       $(MAKE) -C $(DB_DIR)/build_unix clean
 
 db-dirclean: 
        rm -rf $(DB_DIR) 
index aac13bdc3584d4a4f6e9e290b0f807ecb33b3e00..86b84e4c7a60642f00035104c8b2f60b09083f1b 100644 (file)
@@ -22,10 +22,21 @@ $(COREUTILS_DIR)/.unpacked: $(DL_DIR)/$(COREUTILS_SOURCE)
        touch $(COREUTILS_DIR)/.unpacked
 
 $(COREUTILS_DIR)/.configured: $(COREUTILS_DIR)/.unpacked
-       (cd $(COREUTILS_DIR); rm -f config.cache; CC=$(TARGET_CC1) \
-            CFLAGS=-D_POSIX_SOURCE ./configure --prefix=/usr \
-            --target=$(ARCH)-linux --host=$(ARCH)-linux \
-            --disable-nls --mandir=/junk --infodir=/junk \
+       (cd $(COREUTILS_DIR); rm -rf config.cache; \
+               PATH=$(STAGING_DIR)/bin:$$PATH CC=$(TARGET_CC1) \
+               ./configure \
+               --target=$(GNU_TARGET_NAME) \
+               --prefix=/usr \
+               --exec-prefix=/usr \
+               --bindir=/usr/bin \
+               --sbindir=/usr/sbin \
+               --libexecdir=/usr/lib \
+               --sysconfdir=/etc \
+               --datadir=/usr/share \
+               --localstatedir=/var \
+               --mandir=/usr/man \
+               --infodir=/usr/info \
+               --disable-nls \
        );
        touch  $(COREUTILS_DIR)/.configured
 
@@ -48,7 +59,7 @@ coreutils: uclibc $(TARGET_DIR)/$(COREUTILS_TARGET_BINARY)
 
 coreutils-clean:
        $(MAKE) DESTDIR=$(TARGET_DIR) CC=$(TARGET_CC1) -C $(COREUTILS_DIR) uninstall
-       -make -C $(COREUTILS_DIR) clean
+       -$(MAKE) -C $(COREUTILS_DIR) clean
 
 coreutils-dirclean:
        rm -rf $(COREUTILS_DIR)
index 1e4b9f1339012bdd4405168a796c3005e44d0748..ad0dd1db53c9bf90ae335d05a769cafb2b876045 100644 (file)
@@ -36,6 +36,7 @@ GENEXT2_REALSIZE=$(subst total,, $(shell du $(TARGET_DIR) -s -c -k | grep total
 GENEXT2_SIZE=$(shell expr $(GENEXT2_REALSIZE) + $(GENEXT2_ADDTOROOTSIZE))
 # We currently add about 400 device nodes, so add that into the total
 GENEXT2_INODES=$(shell expr $(shell find $(TARGET_DIR) | wc -l) + 400)
+GENEXT2_SIZE=100000
 
 ext2root: genext2fs
        -@find $(TARGET_DIR)/lib -type f -name \*.so\* | xargs $(STRIP) --strip-unneeded 2>/dev/null || true;
@@ -46,7 +47,7 @@ ext2root: genext2fs
 ext2root-source: $(DL_DIR)/$(GENEXT2_SOURCE)
 
 ext2root-clean:
-       -make -C $(GENEXT2_DIR) clean
+       -$(MAKE) -C $(GENEXT2_DIR) clean
 
 ext2root-dirclean:
        rm -rf $(GENEXT2_DIR)
index c32e9868909f741f5627562d3efda852ab13b2ce..82727d4d4d21cd80e06ac45ee2dbb1c57690e5b1 100644 (file)
@@ -23,10 +23,21 @@ $(FINDUTILS_DIR)/.unpacked: $(DL_DIR)/$(FINDUTILS_SOURCE)
        touch $(FINDUTILS_DIR)/.unpacked
 
 $(FINDUTILS_DIR)/.configured: $(FINDUTILS_DIR)/.unpacked
-       (cd $(FINDUTILS_DIR); rm -f config.cache; CC=$(TARGET_CC1) \
-           CFLAGS=-D_POSIX_SOURCE ./configure --prefix=/usr --disable-nls \
-           --mandir=/junk --infodir=/junk --localstatedir=/var/lib/locate \
-           --libexecdir='$${prefix}/lib/locate' \
+       (cd $(FINDUTILS_DIR); rm -rf config.cache; \
+               PATH=$(STAGING_DIR)/bin:$$PATH CC=$(TARGET_CC1) \
+               ./configure \
+               --target=$(GNU_TARGET_NAME) \
+               --prefix=/usr \
+               --exec-prefix=/usr \
+               --bindir=/usr/bin \
+               --sbindir=/usr/sbin \
+               --libexecdir=/usr/lib \
+               --sysconfdir=/etc \
+               --datadir=/usr/share \
+               --localstatedir=/var/lib \
+               --mandir=/usr/man \
+               --infodir=/usr/info \
+               --disable-nls \
        );
        touch  $(FINDUTILS_DIR)/.configured
 
@@ -34,19 +45,14 @@ $(FINDUTILS_DIR)/$(FINDUTILS_BINARY): $(FINDUTILS_DIR)/.configured
        $(MAKE) CC=$(TARGET_CC1) -C $(FINDUTILS_DIR)
 
 $(TARGET_DIR)/$(FINDUTILS_TARGET_BINARY): $(FINDUTILS_DIR)/$(FINDUTILS_BINARY)
-       $(MAKE) prefix=$(TARGET_DIR)/usr exec_prefix=$(TARGET_DIR)/usr \
-        bindir=$(TARGET_DIR)/usr/bin sbindir=$(TARGET_DIR)/usr/sbin \
-        sysconfdir=$(TARGET_DIR)/usr/etc datadir=$(TARGET_DIR)/usr/share \
-        includedir=$(TARGET_DIR)/usr/include libdir=$(TARGET_DIR)/usr/lib \
-        localstatedir=$(TARGET_DIR)/var mandir=$(TARGET_DIR)/junk \
-        infodir=$(TARGET_DIR)/junk CC=$(TARGET_CC1) -C $(FINDUTILS_DIR) install
+       $(MAKE) DESTDIR=$(TARGET_DIR) CC=$(TARGET_CC1) -C $(FINDUTILS_DIR) install
        rm -rf $(TARGET_DIR)/share/locale $(TARGET_DIR)/junk
 
 findutils: uclibc $(TARGET_DIR)/$(FINDUTILS_TARGET_BINARY)
 
 findutils-clean:
        $(MAKE) DESTDIR=$(TARGET_DIR) CC=$(TARGET_CC1) -C $(FINDUTILS_DIR) uninstall
-       -make -C $(FINDUTILS_DIR) clean
+       -$(MAKE) -C $(FINDUTILS_DIR) clean
 
 findutils-dirclean:
        rm -rf $(FINDUTILS_DIR)
index 84671a6fe5ce5c8852c47c706d2ad5fd302d5269..f801f7ffcd6b2139f63265a0c35554de26033c00 100644 (file)
@@ -20,22 +20,20 @@ $(GAWK_DIR)/.unpacked: $(DL_DIR)/$(GAWK_SOURCE)
        touch $(GAWK_DIR)/.unpacked
 
 $(GAWK_DIR)/.configured: $(GAWK_DIR)/.unpacked
-       (cd $(GAWK_DIR); rm -f config.cache; CC=$(TARGET_CC1) \
-           CFLAGS=-D_POSIX_SOURCE ./configure \
+       (cd $(GAWK_DIR); rm -rf config.cache; \
+               PATH=$(STAGING_DIR)/bin:$$PATH CC=$(TARGET_CC1) \
+               ./configure \
                --target=$(GNU_TARGET_NAME) \
                --prefix=/usr \
                --exec-prefix=/usr \
                --bindir=/usr/bin \
                --sbindir=/usr/sbin \
-               --sysconfdir=/etc \
                --libexecdir=/usr/lib \
+               --sysconfdir=/etc \
                --datadir=/usr/share \
-               --libdir=/usr/lib \
                --localstatedir=/var \
-               --mandir=/junk \
-               --infodir=/junk \
-               --includedir=$(STAGING_DIR)/include \
-               --oldincludedir=$(STAGING_DIR)/usr/include \
+               --mandir=/usr/man \
+               --infodir=/usr/info \
                --disable-nls \
        );
        touch  $(GAWK_DIR)/.configured
@@ -51,7 +49,7 @@ gawk: uclibc $(TARGET_DIR)/$(GAWK_TARGET_BINARY)
 
 gawk-clean:
        $(MAKE) DESTDIR=$(TARGET_DIR) CC=$(TARGET_CC1) -C $(GAWK_DIR) uninstall
-       -make -C $(GAWK_DIR) clean
+       -$(MAKE) -C $(GAWK_DIR) clean
 
 gawk-dirclean:
        rm -rf $(GAWK_DIR)
index 04663e5111a4b2d95b07d6daa48217e2dad5f1c9..51eff8bc5414bfd79fc584cbcc2a3cbc07e59ab9 100644 (file)
@@ -16,19 +16,30 @@ $(GDB_DIR)/.unpacked: $(DL_DIR)/$(GDB_SOURCE)
        touch  $(GDB_DIR)/.unpacked
 
 $(GDB_DIR)/.configured: $(GDB_DIR)/.unpacked
-       (cd $(GDB_DIR); rm -rf config.cache; CC=$(TARGET_CC1) \
-       AR=$(TARGET_CROSS)ar NM=$(TARGET_CROSS)nm \
-       LD=$(TARGET_CROSS)ld AS=$(TARGET_CROSS)as \
-       ./configure --prefix=/usr \
-           --includedir=$(STAGING_DIR)/include \
-           --disable-nls --without-uiout --disable-gdbmi \
-           --disable-tui --disable-gdbtk --without-x \
-           --disable-sim --enable-gdbserver \
-           --without-included-gettext);
+       (cd $(GDB_DIR); rm -rf config.cache; \
+               PATH=$(STAGING_DIR)/bin:$$PATH CC=$(TARGET_CC1) \
+               ./configure \
+               --target=$(GNU_TARGET_NAME) \
+               --prefix=/usr \
+               --exec-prefix=/usr \
+               --bindir=/usr/bin \
+               --sbindir=/usr/sbin \
+               --libexecdir=/usr/lib \
+               --sysconfdir=/etc \
+               --datadir=/usr/share \
+               --localstatedir=/var \
+               --mandir=/usr/man \
+               --infodir=/usr/info \
+               --disable-nls \
+               --without-uiout --disable-gdbmi \
+               --disable-tui --disable-gdbtk --without-x \
+               --disable-sim --enable-gdbserver \
+               --without-included-gettext \
+       );
        touch  $(GDB_DIR)/.configured
 
 $(GDB_DIR)/gdb/gdb: $(GDB_DIR)/.configured
-       make CC=$(TARGET_CC1) -C $(GDB_DIR)
+       $(MAKE) CC=$(TARGET_CC1) -C $(GDB_DIR)
        $(STRIP) $(GDB_DIR)/gdb/gdb
 
 $(TARGET_DIR)/usr/bin/gdb: $(GDB_DIR)/gdb/gdb
@@ -37,7 +48,7 @@ $(TARGET_DIR)/usr/bin/gdb: $(GDB_DIR)/gdb/gdb
 gdb: $(TARGET_DIR)/usr/bin/gdb
 
 gdb-clean: 
-       make -C $(GDB_DIR) clean
+       $(MAKE) -C $(GDB_DIR) clean
 
 gdb-dirclean: 
        rm -rf $(GDB_DIR)
index b31496fb685d49a2db0918378bb19f4431f8dabe..cfc834a200a2de95547976e7ae7a6ed0bba7f99c 100644 (file)
@@ -11,18 +11,29 @@ GDB_WDIR:=$(BUILD_DIR)/gdbserver
 
 
 $(GDB_WDIR)/.configured: $(GDB_DIR)/.unpacked
-       (cd $(GDB_WDIR); rm -rf config.cache; CC=$(TARGET_CC1) \
-       AR=$(TARGET_CROSS)ar NM=$(TARGET_CROSS)nm \
-       LD=$(TARGET_CROSS)ld AS=$(TARGET_CROSS)as \
-       $(GDB_DIR)/gdb/gdbserver/configure --prefix=/usr \
-           --includedir=$(STAGING_DIR)/include \
-           --disable-nls --without-uiout --disable-gdbmi \
-           --disable-tui --disable-gdbtk --without-x \
-           --without-included-gettext);
+       (cd $(GDB_WDIR); rm -rf config.cache; \
+               PATH=$(STAGING_DIR)/bin:$$PATH CC=$(TARGET_CC1) \
+               ./configure \
+               --target=$(GNU_TARGET_NAME) \
+               --prefix=/usr \
+               --exec-prefix=/usr \
+               --bindir=/usr/bin \
+               --sbindir=/usr/sbin \
+               --libexecdir=/usr/lib \
+               --sysconfdir=/etc \
+               --datadir=/usr/share \
+               --localstatedir=/var \
+               --mandir=/usr/man \
+               --infodir=/usr/info \
+               --disable-nls \
+               --without-uiout --disable-gdbmi \
+               --disable-tui --disable-gdbtk --without-x \
+               --without-included-gettext \
+       );
        touch  $(GDB_WDIR)/.configured
 
 $(GDB_DIR)/gdb/gdbserver/gdbserver: $(GDB_WDIR)/.configured
-       make CC=$(TARGET_CC1) -C $(GDB_WDIR)
+       $(MAKE) CC=$(TARGET_CC1) -C $(GDB_WDIR)
        $(STRIP) $(GDB_WDIR)/gdbserver
 
 $(TARGET_DIR)/usr/bin/gdbserver: $(GDB_DIR)/gdb/gdbserver/gdbserver
@@ -31,7 +42,7 @@ $(TARGET_DIR)/usr/bin/gdbserver: $(GDB_DIR)/gdb/gdbserver/gdbserver
 gdbserver: $(TARGET_DIR)/usr/bin/gdbserver
 
 gdbserver-clean: 
-       make -C $(GDB_WDIR) clean
+       $(MAKE) -C $(GDB_WDIR) clean
 
 gdbserver-dirclean: 
        rm -rf $(GDB_WDIR)
index 2ddb03c03265c3485e7ea466b8eb1c2109b7cb83..d5227d36c3b47d46729b0e003372fbee826cd714 100644 (file)
@@ -19,9 +19,22 @@ $(LIBGLIB12_DIR)/.unpacked: $(DL_DIR)/$(LIBGLIB12_SOURCE)
        touch $(LIBGLIB12_DIR)/.unpacked
 
 $(LIBGLIB12_DIR)/.configured: $(LIBGLIB12_DIR)/.unpacked
-       (cd $(LIBGLIB12_DIR); rm -f config.cache; CC=$(TARGET_CC1) \
-           ./configure --prefix=$(STAGING_DIR) --enable-shared \
-           --host=$(ARCH)-pc-linux-gnu \
+       (cd $(LIBGLIB12_DIR); rm -rf config.cache; \
+               PATH=$(STAGING_DIR)/bin:$$PATH CC=$(TARGET_CC1) \
+               ./configure \
+               --target=$(GNU_TARGET_NAME) \
+               --prefix=/usr \
+               --exec-prefix=/usr \
+               --bindir=/usr/bin \
+               --sbindir=/usr/sbin \
+               --libexecdir=/usr/lib \
+               --sysconfdir=/etc \
+               --datadir=/usr/share \
+               --localstatedir=/var \
+               --mandir=/usr/man \
+               --infodir=/usr/info \
+               --disable-nls \
+               --enable-shared \
        );
        touch  $(LIBGLIB12_DIR)/.configured
 
@@ -29,7 +42,7 @@ $(LIBGLIB12_DIR)/.libs/$(LIBGLIB12_BINARY): $(LIBGLIB12_DIR)/.configured
        $(MAKE) CC=$(TARGET_CC1) -C $(LIBGLIB12_DIR)
 
 $(STAGING_DIR)/lib/$(LIBGLIB12_BINARY): $(LIBGLIB12_DIR)/.libs/$(LIBGLIB12_BINARY)
-       $(MAKE) CC=$(TARGET_CC1) -C $(LIBGLIB12_DIR) install
+       $(MAKE) CC=$(TARGET_CC1) prefix=$(STAGING_DIR) -C $(LIBGLIB12_DIR) install
 
 $(TARGET_DIR)/lib/$(LIBGLIB12_BINARY): $(STAGING_DIR)/lib/$(LIBGLIB12_BINARY)
        cp -a $(STAGING_DIR)/lib/$(LIBGLIB12_BINARY) $(TARGET_DIR)/lib/
@@ -41,7 +54,7 @@ libglib12: uclibc $(TARGET_DIR)/lib/$(LIBGLIB12_BINARY)
 
 libglib12-clean:
        rm -f $(TARGET_DIR)/lib/$(LIBGLIB12_BINARY)
-       -make -C $(LIBGLIB12_DIR) clean
+       -$(MAKE) -C $(LIBGLIB12_DIR) clean
 
 libglib12-dirclean:
        rm -rf $(LIBGLIB12_DIR)
index ca2702d867885b8a212c58389f172b7ab18de363..0d1ac56dde9f26c611455b952ac5948881241f0d 100644 (file)
@@ -20,11 +20,21 @@ $(LIBTOOL_DIR)/.unpacked: $(DL_DIR)/$(LIBTOOL_SOURCE)
        touch $(LIBTOOL_DIR)/.unpacked
 
 $(LIBTOOL_DIR)/.configured: $(LIBTOOL_DIR)/.unpacked
-       (cd $(LIBTOOL_DIR); rm -f config.cache; CC=$(TARGET_CC1) \
-           CFLAGS=-D_POSIX_SOURCE ./configure \
-               --target=i386-uclibc \
+       (cd $(LIBTOOL_DIR); rm -rf config.cache; \
+               PATH=$(STAGING_DIR)/bin:$$PATH CC=$(TARGET_CC1) \
+               ./configure \
+               --target=$(GNU_TARGET_NAME) \
                --prefix=/usr \
                --exec-prefix=/usr \
+               --bindir=/usr/bin \
+               --sbindir=/usr/sbin \
+               --libexecdir=/usr/lib \
+               --sysconfdir=/etc \
+               --datadir=/usr/share \
+               --localstatedir=/var \
+               --mandir=/usr/man \
+               --infodir=/usr/info \
+               --disable-nls \
        );
        touch  $(LIBTOOL_DIR)/.configured
 
@@ -54,7 +64,7 @@ libtool: uclibc $(TARGET_DIR)/$(LIBTOOL_TARGET_BINARY)
 
 libtool-clean:
        $(MAKE) DESTDIR=$(TARGET_DIR) CC=$(TARGET_CC1) -C $(LIBTOOL_DIR) uninstall
-       -make -C $(LIBTOOL_DIR) clean
+       -$(MAKE) -C $(LIBTOOL_DIR) clean
 
 libtool-dirclean:
        rm -rf $(LIBTOOL_DIR)
index 40c2aee7bec82ca3acd81dbbdc2302ed45b336c0..675aea94a9e3720ee447f3b54018ec7db27b2e7b 100644 (file)
@@ -17,22 +17,33 @@ $(LINKS_DIR)/.unpacked: $(DL_DIR)/$(LINKS_SOURCE)
        touch  $(LINKS_DIR)/.unpacked
 
 $(LINKS_DIR)/.configured: $(LINKS_DIR)/.unpacked
-       (cd $(LINKS_DIR); rm -rf config.cache; CC=$(TARGET_CC1) \
-       ./configure --prefix=/usr \
-           --libexecdir=/usr/lib --sysconfdir=/etc \
-           --localstatedir=/tmp --libdir=/etc \
-           --disable-nls);
+       (cd $(LINKS_DIR); rm -rf config.cache; \
+               PATH=$(STAGING_DIR)/bin:$$PATH CC=$(TARGET_CC1) \
+               ./configure \
+               --target=$(GNU_TARGET_NAME) \
+               --prefix=/usr \
+               --exec-prefix=/usr \
+               --bindir=/usr/bin \
+               --sbindir=/usr/sbin \
+               --libexecdir=/usr/lib \
+               --sysconfdir=/etc \
+               --datadir=/usr/share \
+               --localstatedir=/var \
+               --mandir=/usr/man \
+               --infodir=/usr/info \
+               --disable-nls \
+       );
        touch  $(LINKS_DIR)/.configured
 
 $(LINKS_DIR)/links: $(LINKS_DIR)/.configured
-       make CC=$(TARGET_CC1) -C $(LINKS_DIR)
+       $(MAKE) CC=$(TARGET_CC1) -C $(LINKS_DIR)
        $(STRIP) $(LINKS_DIR)/links
 
 $(TARGET_DIR)/usr/bin/links: $(LINKS_DIR)/links
        install -c $(LINKS_DIR)/links $(TARGET_DIR)/usr/bin/links
 
 links-clean: 
-       make -C $(LINKS_DIR) clean
+       $(MAKE) -C $(LINKS_DIR) clean
 
 links-dirclean: 
        rm -rf $(LINKS_DIR) 
index cc10e4a60926678a809b1d4e05aefacbef77d1fa..70ceb92ae922e6b16833c7e8005f2bb7b50a7616 100644 (file)
@@ -20,11 +20,21 @@ $(M4_DIR)/.unpacked: $(DL_DIR)/$(M4_SOURCE)
        touch $(M4_DIR)/.unpacked
 
 $(M4_DIR)/.configured: $(M4_DIR)/.unpacked
-       (cd $(M4_DIR); rm -f config.cache; CC=$(TARGET_CC1) \
-           CFLAGS=-D_POSIX_SOURCE ./configure \
+       (cd $(M4_DIR); rm -rf config.cache; \
+               PATH=$(STAGING_DIR)/bin:$$PATH CC=$(TARGET_CC1) \
+               ./configure \
                --target=$(GNU_TARGET_NAME) \
                --prefix=/usr \
                --exec-prefix=/usr \
+               --bindir=/usr/bin \
+               --sbindir=/usr/sbin \
+               --libexecdir=/usr/lib \
+               --sysconfdir=/etc \
+               --datadir=/usr/share \
+               --localstatedir=/var \
+               --mandir=/usr/man \
+               --infodir=/usr/info \
+               --disable-nls \
        );
        touch  $(M4_DIR)/.configured
 
@@ -53,7 +63,7 @@ m4: uclibc $(TARGET_DIR)/$(M4_TARGET_BINARY)
 
 m4-clean:
        $(MAKE) DESTDIR=$(TARGET_DIR) CC=$(TARGET_CC1) -C $(M4_DIR) uninstall
-       -make -C $(M4_DIR) clean
+       -$(MAKE) -C $(M4_DIR) clean
 
 m4-dirclean:
        rm -rf $(M4_DIR)
index 9fc8f7f5c51e1b7825706957d238bf607afe3618..cc12592b6897c334694d2ffeb8ecf7f213161b2f 100644 (file)
@@ -20,9 +20,21 @@ $(GNUMAKE_DIR)/.unpacked: $(DL_DIR)/$(GNUMAKE_SOURCE)
        touch $(GNUMAKE_DIR)/.unpacked
 
 $(GNUMAKE_DIR)/.configured: $(GNUMAKE_DIR)/.unpacked
-       (cd $(GNUMAKE_DIR); autoconf; rm -f config.cache; CC=$(TARGET_CC1) \
-           CFLAGS=-D_POSIX_SOURCE ./configure --prefix=/usr --disable-nls \
-           --mandir=/junk --infodir=/junk \
+       (cd $(GNUMAKE_DIR); rm -rf config.cache; \
+               PATH=$(STAGING_DIR)/bin:$$PATH CC=$(TARGET_CC1) \
+               ./configure \
+               --target=$(GNU_TARGET_NAME) \
+               --prefix=/usr \
+               --exec-prefix=/usr \
+               --bindir=/usr/bin \
+               --sbindir=/usr/sbin \
+               --libexecdir=/usr/lib \
+               --sysconfdir=/etc \
+               --datadir=/usr/share \
+               --localstatedir=/var \
+               --mandir=/usr/man \
+               --infodir=/usr/info \
+               --disable-nls \
        );
        touch  $(GNUMAKE_DIR)/.configured
 
@@ -37,7 +49,7 @@ make: uclibc $(TARGET_DIR)/$(GNUMAKE_TARGET_BINARY)
 
 make-clean:
        $(MAKE) DESTDIR=$(TARGET_DIR) CC=$(TARGET_CC1) -C $(GNUMAKE_DIR) uninstall
-       -make -C $(GNUMAKE_DIR) clean
+       -$(MAKE) -C $(GNUMAKE_DIR) clean
 
 make-dirclean:
        rm -rf $(GNUMAKE_DIR)
index 8ab30c2e76abb0f9826b8d780c5392ac485e6eb8..1f5f44866b2ff576b5e88c70a1c4db29e4cdb7d4 100644 (file)
@@ -5,7 +5,7 @@
 #
 #############################################################
 # Copyright (C) 2002 by Ken Restivo <ken@246gt.com>
-# $Id: ncurses.mk,v 1.15 2003/01/16 22:04:22 andersen Exp $
+# $Id: ncurses.mk,v 1.16 2003/01/17 08:03:59 andersen Exp $
 #
 # This program is free software; you can redistribute it and/or modify
 # it under the terms of the GNU Library General Public License as
@@ -55,8 +55,9 @@ $(NCURSES_DIR)/.configured: $(NCURSES_DIR)/.dist
                --with-default-terminfo-dir=/usr/share/terminfo \
                --libdir=$(STAGING_DIR)/lib \
                --includedir=$(STAGING_DIR)/include \
-               --with-shared --without-cxx --without-cxx-binding --without-ada \
-               --without-progs --disable-nls);
+               --with-shared --without-cxx --without-cxx-binding \
+               --without-ada --without-progs --disable-nls \
+       );
        touch  $(NCURSES_DIR)/.configured
 
 $(NCURSES_DIR)/lib/libncurses.so: $(NCURSES_DIR)/.configured
index 54db8eb947505642ba15a412b29cd943b4ddb987..56fba9ea056a0c41d0588d107857a4dca9a8c1cd 100644 (file)
@@ -23,10 +23,22 @@ $(NEWT_DIR)/.source: $(DL_DIR)/$(NEWT_SOURCE) $(NEWT_PATCH)
        touch $(NEWT_DIR)/.source;
 
 $(NEWT_DIR)/.configured: $(NEWT_DIR)/.source
-       (cd $(NEWT_DIR); rm -rf config.cache; CC=$(TARGET_CC1) \
-       ./configure --shared --prefix=/usr --exec_prefix=$(STAGING_DIR)/usr/bin \
-               --libdir=$(STAGING_DIR)/lib --includedir=$(STAGING_DIR)/include \
-               --host=$(ARCH)-pc-linux-gnu);
+       (cd $(NEWT_DIR); rm -rf config.cache; \
+               PATH=$(STAGING_DIR)/bin:$$PATH CC=$(TARGET_CC1) \
+               ./configure \
+               --target=$(GNU_TARGET_NAME) \
+               --prefix=/usr \
+               --exec-prefix=/usr \
+               --bindir=/usr/bin \
+               --sbindir=/usr/sbin \
+               --libexecdir=/usr/lib \
+               --sysconfdir=/etc \
+               --datadir=/usr/share \
+               --localstatedir=/var \
+               --mandir=/usr/man \
+               --infodir=/usr/info \
+               --disable-nls \
+       );
        touch $(NEWT_DIR)/.configured;
 
 $(NEWT_DIR)/libnewt.so.0.50.17: $(NEWT_DIR)/.configured
@@ -50,7 +62,7 @@ newt: uclibc slang $(TARGET_DIR)/lib/libnewt.so.0.50.17
 
 newt-clean:
        rm -f $(TARGET_DIR)/lib/libnewt.so*
-       -make -C $(NEWT_DIR) clean
+       -$(MAKE) -C $(NEWT_DIR) clean
 
 newt-dirclean: slang-dirclean
        rm -rf $(NEWT_DIR)
index 024c8b0731fb6a8fb14d8f66ec331a9697adc774..01fda928249f5391344b21ac3cfa848701c58cad 100644 (file)
@@ -21,37 +21,40 @@ $(OPENSSH_DIR)/.patched: $(OPENSSH_DIR)/.unpacked
        touch $(OPENSSH_DIR)/.patched
 
 $(OPENSSH_DIR)/.configured: $(OPENSSH_DIR)/.patched
-       (cd $(OPENSSH_DIR); rm -rf config.cache; CC=$(TARGET_CC1) \
-           ./configure \
-           --prefix=/usr \
-           --exec-prefix=/usr \
-           --bindir=/usr/bin \
-           --sbindir=/usr/sbin \
-           --sysconfdir=/etc \
-           --libexecdir=/usr/lib \
-           --datadir=/usr/share \
-           --includedir=/usr/include \
-           --libdir=/usr/lib \
-           --localstatedir=/var \
-           --mandir=/usr/man \
-           --infodir=/usr/info \
-           --includedir=$(STAGING_DIR)/include \
-           --disable-lastlog --disable-utmp --disable-utmpx --disable-wtmp --disable-wtmpx \
-           --disable-nls --without-x);
+       (cd $(OPENSSH_DIR); rm -rf config.cache; \
+               PATH=$(STAGING_DIR)/bin:$$PATH CC=$(TARGET_CC1) \
+               ./configure \
+               --target=$(GNU_TARGET_NAME) \
+               --prefix=/usr \
+               --exec-prefix=/usr \
+               --bindir=/usr/bin \
+               --sbindir=/usr/sbin \
+               --libexecdir=/usr/lib \
+               --sysconfdir=/etc \
+               --datadir=/usr/share \
+               --localstatedir=/var \
+               --mandir=/usr/man \
+               --infodir=/usr/info \
+               --disable-nls \
+               --includedir=$(STAGING_DIR)/include \
+               --disable-lastlog --disable-utmp \
+               --disable-utmpx --disable-wtmp --disable-wtmpx \
+               --disable-nls --without-x \
+       );
        touch  $(OPENSSH_DIR)/.configured
 
 $(OPENSSH_DIR)/ssh: $(OPENSSH_DIR)/.configured
-       make CC=$(TARGET_CC1) -C $(OPENSSH_DIR)
+       $(MAKE) CC=$(TARGET_CC1) -C $(OPENSSH_DIR)
        -$(STRIP) --strip-unneeded $(OPENSSH_DIR)/*.so*
 
 $(TARGET_DIR)/usr/bin/ssh: $(OPENSSH_DIR)/ssh
-       make CC=$(TARGET_CC1) DESTDIR=$(TARGET_DIR) -C $(OPENSSH_DIR) install
+       $(MAKE) CC=$(TARGET_CC1) DESTDIR=$(TARGET_DIR) -C $(OPENSSH_DIR) install
        rm -rf $(TARGET_DIR)/usr/info $(TARGET_DIR)/usr/man $(TARGET_DIR)/usr/share/doc
 
 openssh: $(TARGET_DIR)/usr/bin/ssh
 
 openssh-clean: 
-       make -C $(OPENSSH_DIR) clean
+       $(MAKE) -C $(OPENSSH_DIR) clean
 
 openssh-dirclean: 
        rm -rf $(OPENSSH_DIR)
index 183781ee5ee46935d4d6219674d99bd5e94a6b05..f43a75bff119d78820c88a16ff02f772265fd41b 100644 (file)
@@ -21,15 +21,15 @@ $(OPENSSL_DIR)/.unpacked: $(DL_DIR)/$(OPENSSL_SOURCE) $(OPENSSL_PATCH)
 $(OPENSSL_DIR)/Makefile: $(OPENSSL_DIR)/.unpacked
        (cd $(OPENSSL_DIR); \
        PATH=$(TARGET_PATH) ./Configure linux-$(ARCH) --prefix=$(STAGING_DIR) \
-               --openssldir=$(STAGING_DIR) -L$(STAGING_DIR)/lib -ldl \
+               --openssldir=$(STAGING_DIR)/usr/lib/ssl -L$(STAGING_DIR)/lib -ldl \
                -I$(STAGING_DIR)/include $(OPENSSL_OPTS) no-threads \
                shared no-idea no-mdc2 no-rc5)
 
 $(OPENSSL_DIR)/apps/openssl: $(OPENSSL_DIR)/Makefile
-       make CC=$(TARGET_CC1) -C $(OPENSSL_DIR) all build-shared
+       $(MAKE) CC=$(TARGET_CC1) -C $(OPENSSL_DIR) all build-shared
 
 $(STAGING_DIR)/lib/libcrypto.so.0: $(OPENSSL_DIR)/apps/openssl
-       make CC=$(TARGET_CC1) -C $(OPENSSL_DIR) install
+       $(MAKE) CC=$(TARGET_CC1) -C $(OPENSSL_DIR) install
        cp -fa $(OPENSSL_DIR)/libcrypto.so* $(STAGING_DIR)/lib/
        (cd $(STAGING_DIR)/lib; ln -fs libcrypto.so.0.9.6 libcrypto.so)
        (cd $(STAGING_DIR)/lib; ln -fs libcrypto.so.0.9.6 libcrypto.so.0)
index f62d70d06207ffc2dafd4ad051eb2d75bf26f572..a6af02e4aace942b4b613c9e75e7ec160c555ca2 100644 (file)
@@ -20,9 +20,21 @@ $(SED_DIR)/.unpacked: $(DL_DIR)/$(SED_SOURCE)
        touch $(SED_DIR)/.unpacked
 
 $(SED_DIR)/.configured: $(SED_DIR)/.unpacked
-       (cd $(SED_DIR); autoconf; rm -f config.cache; CC=$(TARGET_CC1) \
-           CFLAGS=-D_POSIX_SOURCE ./configure --prefix=/usr --disable-nls \
-           --mandir=/junk --infodir=/junk \
+       (cd $(SED_DIR); rm -rf config.cache; \
+               PATH=$(STAGING_DIR)/bin:$$PATH CC=$(TARGET_CC1) \
+               ./configure \
+               --target=$(GNU_TARGET_NAME) \
+               --prefix=/usr \
+               --exec-prefix=/usr \
+               --bindir=/usr/bin \
+               --sbindir=/usr/sbin \
+               --libexecdir=/usr/lib \
+               --sysconfdir=/etc \
+               --datadir=/usr/share \
+               --localstatedir=/var \
+               --mandir=/usr/man \
+               --infodir=/usr/info \
+               --disable-nls \
        );
        touch  $(SED_DIR)/.configured
 
index 56d545d9288f7d52460aaa6a64187c6be3270b14..9a9fc6019daf80791cd39458579e614e74984987 100644 (file)
@@ -26,8 +26,22 @@ $(SOCAT_DIR)/.unpacked:      $(DL_DIR)/$(SOCAT_SOURCE)
 $(SOCAT_WORKDIR)/Makefile: $(TARGET_CC) $(SOCAT_DIR)/.unpacked
        rm -f $(SOCAT_WORKDIR)/Makefile
        mkdir -p $(SOCAT_WORKDIR)
-       (cd $(SOCAT_WORKDIR) && CONFIG_SITE=$(SOURCE_DIR)/socat-config.site-$(ARCH) \
-               CC=$(TARGET_CC) $(SOCAT_DIR)/configure --prefix=/usr)
+       (cd $(SOCAT_WORKDIR); rm -rf config.cache; \
+               PATH=$(STAGING_DIR)/bin:$$PATH CC=$(TARGET_CC1) \
+               $(SOCAT_DIR)/configure \
+               --target=$(GNU_TARGET_NAME) \
+               --prefix=/usr \
+               --exec-prefix=/usr \
+               --bindir=/usr/bin \
+               --sbindir=/usr/sbin \
+               --libexecdir=/usr/lib \
+               --sysconfdir=/etc \
+               --datadir=/usr/share \
+               --localstatedir=/var \
+               --mandir=/usr/man \
+               --infodir=/usr/info \
+               --disable-nls \
+       );
         
 $(SOCAT_WORKDIR)/socat:        $(SOCAT_WORKDIR)/Makefile
        rm -f $@
index 84b055e01b9f9f86a687ac89e8bfc3f02ca70222..cab7383d8818a55500ed67df190cb0e64c2903b4 100644 (file)
@@ -2,48 +2,53 @@
 #
 # strace
 #
-# Maintainer: Ken Restivo <ken@246gt.com>
-#
 #############################################################
-#$Id: strace.mk,v 1.3 2002/11/20 23:16:09 andersen Exp $
-
-# TARGETS
+STRACE_SOURCE:=strace_4.4-1.tar.gz
 STRACE_SITE:=http://telia.dl.sourceforge.net/sourceforge/strace
-STRACE_SOURCE:=strace_4.4-1.tar.gz 
+STRACE_CAT:=zcat
 STRACE_DIR:=$(BUILD_DIR)/strace-4.4
 
+
 $(DL_DIR)/$(STRACE_SOURCE):
-       $(WGET) -P $(DL_DIR) $(STRACE_SITE)/$(STRACE_SOURCE)
+        $(WGET) -P $(DL_DIR) $(STRACE_SITE)/$(STRACE_SOURCE)
 
 strace-source: $(DL_DIR)/$(STRACE_SOURCE)
 
-$(STRACE_DIR)/.dist: $(DL_DIR)/$(STRACE_SOURCE)
-       zcat $(DL_DIR)/$(STRACE_SOURCE) | tar -C $(BUILD_DIR) -xvf -
-       touch  $(STRACE_DIR)/.dist
-
-$(STRACE_DIR)/Makefile: $(STRACE_DIR)/.dist
-       (cd ${STRACE_DIR}; \
-       export PATH="${TARGET_PATH}"; \
-       ./configure --with-shared --prefix=$(STAGING_DIR)/usr \
-               --target=$(ARCH)-linux --host=$(ARCH)-linux )
+$(STRACE_DIR)/.unpacked: $(DL_DIR)/$(STRACE_SOURCE)
+       $(STRACE_CAT) $(DL_DIR)/$(STRACE_SOURCE) | tar -C $(BUILD_DIR) -xvf -
+       touch $(STRACE_DIR)/.unpacked
+
+$(STRACE_DIR)/.configured: $(STRACE_DIR)/.unpacked
+       (cd $(STRACE_DIR); rm -rf config.cache; \
+               PATH=$(STAGING_DIR)/bin:$$PATH CC=$(TARGET_CC1) \
+               ./configure \
+               --target=$(GNU_TARGET_NAME) \
+               --prefix=/usr \
+               --exec-prefix=/usr \
+               --bindir=/usr/bin \
+               --sbindir=/usr/sbin \
+               --libexecdir=/usr/lib \
+               --sysconfdir=/etc \
+               --datadir=/usr/share \
+               --localstatedir=/var \
+               --mandir=/usr/man \
+               --infodir=/usr/info \
+               --disable-nls \
+       );
+       touch  $(STRACE_DIR)/.configured
+
+$(STRACE_DIR)/strace: $(STRACE_DIR)/.configured
+       $(MAKE) CC=$(TARGET_CC1) -C $(STRACE_DIR)
+
+$(TARGET_DIR)/usr/bin/strace: $(STRACE_DIR)/strace
+       install -c $(STRACE_DIR)/strace $(TARGET_DIR)/usr/bin/strace
 
-$(STRACE_DIR)/strace: $(STRACE_DIR)/Makefile
-       make CC="${TARGET_CC}" LD="${TARGET_LD}" \
-               AS="${TARGET_AS}" -C $(STRACE_DIR)
-
-$(STAGING_DIR)/usr/bin/strace: $(STRACE_DIR)/strace
-       -mkdir -p $(STAGING_DIR)/usr/man/man1
-       make -C $(STRACE_DIR) install
-       rm -rf $(STAGING_DIR)/usr/man/man1
-
-$(TARGET_DIR)/usr/bin/strace: $(STAGING_DIR)/usr/bin/strace
-       install -c $(STAGING_DIR)/usr/bin/strace $(TARGET_DIR)/usr/bin/strace
+strace: uclibc $(TARGET_DIR)/usr/bin/strace 
 
 strace-clean: 
-       make -C $(STRACE_DIR) clean
+       $(MAKE) -C $(STRACE_DIR) clean
 
 strace-dirclean: 
        rm -rf $(STRACE_DIR) 
 
-strace: uclibc $(TARGET_DIR)/usr/bin/strace 
 
index a55adf06ccfc291f41f9b2e77e6624f4a09c1b19..becfaa64e869917f333d944378729181e252a6a3 100644 (file)
@@ -24,9 +24,7 @@ ifeq ($(USE_UCLIBC_TOOLCHAIN),true)
 # hacking on the toolchain...
 #
 #############################################################
-GNU_TARGET_NAME:=$(ARCH)-linux
 TARGET_LANGUAGES:=c,c++
-MAKE=make
 
 # If you want multilib enabled, enable this...
 #MULTILIB:=--enable-multilib
@@ -229,7 +227,7 @@ $(GCC_BUILD_DIR1)/.configured: $(GCC_DIR)/.gcc_build_hacks
                --oldincludedir=$(STAGING_DIR)/include $(MULTILIB) \
                --enable-target-optspace --disable-nls --with-gnu-ld \
                --disable-shared --enable-languages=c --disable-__cxa_atexit \
-               --program-prefix=$(ARCH)-uclibc-);
+               $(EXTRA_GCC_CONFIG_OPTIONS) --program-prefix=$(ARCH)-uclibc-);
        touch $(GCC_BUILD_DIR1)/.configured
 
 $(GCC_BUILD_DIR1)/.compiled: $(GCC_BUILD_DIR1)/.configured
@@ -361,25 +359,38 @@ $(GCC_DIR)/.g++_build_hacks: $(GCC_DIR)/.patched
 
 $(GCC_BUILD_DIR2)/.configured: $(GCC_DIR)/.g++_build_hacks
        mkdir -p $(GCC_BUILD_DIR2)
-       (cd $(GCC_BUILD_DIR2); PATH=$(STAGING_DIR)/bin:$$PATH AR=$(ARCH)-uclibc-ar \
-               RANLIB=$(ARCH)-uclibc-ranlib CC=$(HOSTCC) $(GCC_DIR)/configure \
-               --target=$(GNU_TARGET_NAME) --prefix=$(STAGING_DIR) \
-               --exec-prefix=$(STAGING_DIR) --bindir=$(STAGING_DIR)/bin \
-               --sbindir=$(STAGING_DIR)/sbin --sysconfdir=$(STAGING_DIR)/etc \
-               --datadir=$(STAGING_DIR)/share --includedir=$(STAGING_DIR)/include \
-               --libdir=$(STAGING_DIR)/lib --localstatedir=$(STAGING_DIR)/var \
-               --mandir=$(STAGING_DIR)/man --infodir=$(STAGING_DIR)/info \
+       (cd $(GCC_BUILD_DIR2); PATH=$(STAGING_DIR)/bin:$$PATH AR=$(TARGET_CROSS)ar \
+               RANLIB=$(TARGET_CROSS)ranlib LD=$(TARGET_CROSS)ld NM=$(TARGET_CROSS)nm \
+               CC=$(HOSTCC) $(GCC_DIR)/configure \
+               --target=$(GNU_TARGET_NAME) \
+               --prefix=$(STAGING_DIR) \
+               --exec-prefix=$(STAGING_DIR) \
+               --bindir=$(STAGING_DIR)/bin \
+               --sbindir=$(STAGING_DIR)/sbin \
+               --sysconfdir=$(STAGING_DIR)/etc \
+               --datadir=$(STAGING_DIR)/share \
+               --localstatedir=$(STAGING_DIR)/var \
+               --mandir=$(STAGING_DIR)/man \
+               --infodir=$(STAGING_DIR)/info \
                --with-local-prefix=$(STAGING_DIR)/usr/local \
-               --oldincludedir=$(STAGING_DIR)/include $(MULTILIB) \
-               --enable-target-optspace --disable-nls --with-gnu-ld \
-               --enable-shared --enable-languages=$(TARGET_LANGUAGES) --disable-__cxa_atexit \
-               --program-prefix=$(ARCH)-uclibc-);
+               --libdir=$(STAGING_DIR)/lib \
+               --includedir=$(STAGING_DIR)/include \
+               --with-gxx-include-dir=$(STAGING_DIR)/include/c++ \
+               --oldincludedir=$(STAGING_DIR)/include \
+               --enable-shared $(MULTILIB) \
+               --enable-target-optspace --disable-nls \
+               --with-gnu-ld --disable-__cxa_atexit \
+               --enable-languages=$(TARGET_LANGUAGES) \
+               $(EXTRA_GCC_CONFIG_OPTIONS) \
+               --program-prefix=$(ARCH)-uclibc- \
+       );
        touch $(GCC_BUILD_DIR2)/.configured
 
 $(GCC_BUILD_DIR2)/.compiled: $(GCC_BUILD_DIR2)/.configured
-       PATH=$(STAGING_DIR)/bin:$$PATH $(MAKE) -C $(GCC_BUILD_DIR2) \
-           AR_FOR_TARGET=$(STAGING_DIR)/bin/$(ARCH)-uclibc-ar \
-           RANLIB_FOR_TARGET=$(STAGING_DIR)/bin/$(ARCH)-uclibc-ranlib
+       PATH=$(STAGING_DIR)/bin:$$PATH CC=$(HOSTCC) \
+           AR_FOR_TARGET=$(TARGET_CROSS)ar RANLIB_FOR_TARGET=$(TARGET_CROSS)ranlib \
+           LD_FOR_TARGET=$(TARGET_CROSS)ld NM_FOR_TARGET=$(TARGET_CROSS)nm \
+           CC_FOR_TARGET=$(TARGET_CROSS)gcc $(MAKE) -C $(GCC_BUILD_DIR2)
        touch $(GCC_BUILD_DIR2)/.compiled
 
 $(GCC_BUILD_DIR2)/.installed: $(GCC_BUILD_DIR2)/.compiled
@@ -397,6 +408,7 @@ $(GCC_BUILD_DIR2)/.fixedup: $(GCC_BUILD_DIR2)/.installed
        -mv $(STAGING_DIR)/bin/$(GNU_TARGET_NAME)-g++ $(STAGING_DIR)/bin/$(ARCH)-uclibc-g++
        -mv $(STAGING_DIR)/bin/$(GNU_TARGET_NAME)-c++filt $(STAGING_DIR)/bin/$(ARCH)-uclibc-c++filt
        rm -f $(STAGING_DIR)/bin/cpp $(STAGING_DIR)/bin/gcov $(STAGING_DIR)/bin/*gccbug
+       rm -f $(STAGING_DIR)/lib/libgcc_s.so*
        rm -rf $(STAGING_DIR)/info $(STAGING_DIR)/man $(STAGING_DIR)/share/doc \
                $(STAGING_DIR)/share/locale
        touch $(GCC_BUILD_DIR2)/.fixedup
index 3a0da79148cf23ea5330e3a20ef50de593a37deb..566fe2eb9105144e74d28c88a2ed049764373348 100644 (file)
@@ -21,18 +21,29 @@ $(VALGRIND_DIR)/.patched: $(VALGRIND_DIR)/.unpacked
        touch $(VALGRIND_DIR)/.patched
 
 $(VALGRIND_DIR)/.configured: $(VALGRIND_DIR)/.patched
-       (cd $(VALGRIND_DIR); rm -rf config.cache; CC=$(TARGET_CC1) \
-       AR=$(TARGET_CROSS)ar NM=$(TARGET_CROSS)nm \
-       LD=$(TARGET_CROSS)ld AS=$(TARGET_CROSS)as \
-       ./configure --prefix=/usr \
-           --includedir=/usr/include \
-           --disable-nls --without-uiout --disable-valgrindmi \
-           --disable-tui --disable-valgrindtk --without-x \
-           --without-included-gettext);
+       (cd $(VALGRIND_DIR); rm -rf config.cache; \
+               PATH=$(STAGING_DIR)/bin:$$PATH CC=$(TARGET_CC1) \
+               ./configure \
+               --target=$(GNU_TARGET_NAME) \
+               --prefix=/usr \
+               --exec-prefix=/usr \
+               --bindir=/usr/bin \
+               --sbindir=/usr/sbin \
+               --libexecdir=/usr/lib \
+               --sysconfdir=/etc \
+               --datadir=/usr/share \
+               --localstatedir=/var \
+               --mandir=/usr/man \
+               --infodir=/usr/info \
+               --disable-nls \
+               --without-uiout --disable-valgrindmi \
+               --disable-tui --disable-valgrindtk \
+               --without-x --without-included-gettext \
+       );
        touch  $(VALGRIND_DIR)/.configured
 
 $(VALGRIND_DIR)/valgrind.so: $(VALGRIND_DIR)/.configured
-       make CC=$(TARGET_CC1) -C $(VALGRIND_DIR)
+       $(MAKE) CC=$(TARGET_CC1) -C $(VALGRIND_DIR)
        -$(STRIP) --strip-unneeded $(VALGRIND_DIR)/*.so*
        touch -c $(VALGRIND_DIR)/valgrind.so
 
@@ -63,7 +74,7 @@ $(TARGET_DIR)/usr/bin/valgrind: $(VALGRIND_DIR)/valgrind.so
 valgrind: $(TARGET_DIR)/usr/bin/valgrind
 
 valgrind-clean: 
-       make -C $(VALGRIND_DIR) clean
+       $(MAKE) -C $(VALGRIND_DIR) clean
 
 valgrind-dirclean: 
        rm -rf $(VALGRIND_DIR)
index 11ea17cb1b78cdadee18ab414230b4de4ea3452c..8de9b5b4c8b5335c445ac3333076abac60966ba6 100644 (file)
@@ -20,12 +20,20 @@ $(ZLIB_DIR)/.source: $(DL_DIR)/$(ZLIB_SOURCE)
        touch $(ZLIB_DIR)/.source
 
 $(ZLIB_DIR)/.configured: $(ZLIB_DIR)/.source
-       (cd $(ZLIB_DIR); ./configure --shared --prefix=/usr --exec_prefix=$(STAGING_DIR)/usr/bin \
-               --libdir=$(STAGING_DIR)/lib --includedir=$(STAGING_DIR)/include);
+       (cd $(ZLIB_DIR); \
+               PATH=$(STAGING_DIR)/bin:$$PATH CC=$(TARGET_CC1) \
+               ./configure \
+               --shared \
+               --prefix=/usr \
+               --exec-prefix=$(STAGING_DIR)/usr/bin \
+               --libdir=$(STAGING_DIR)/lib \
+               --includedir=$(STAGING_DIR)/include \
+       );
        touch $(ZLIB_DIR)/.configured;
 
 $(ZLIB_DIR)/libz.so.1.1.4: $(ZLIB_DIR)/.configured
-       $(MAKE) LDSHARED="$(TARGET_CROSS)gcc --shared" CFLAGS=$(ZLIB_CFLAGS) CC=$(TARGET_CC1) -C $(ZLIB_DIR) all libz.a;
+       $(MAKE) LDSHARED="$(TARGET_CROSS)gcc --shared" CFLAGS=$(ZLIB_CFLAGS) \
+               CC=$(TARGET_CC1) -C $(ZLIB_DIR) all libz.a;
        touch -c $(ZLIB_DIR)/libz.so.1.1.4
 
 $(STAGING_DIR)/lib/libz.so.1.1.4: $(ZLIB_DIR)/libz.so.1.1.4
@@ -54,7 +62,7 @@ zlib: uclibc $(TARGET_DIR)/lib/libz.so.1.1.4
 
 zlib-clean:
        rm -f $(TARGET_DIR)/lib/libz.so*
-       -make -C $(ZLIB_DIR) clean
+       -$(MAKE) -C $(ZLIB_DIR) clean
 
 zlib-dirclean:
        rm -rf $(ZLIB_DIR)