summaryrefslogtreecommitdiffstats
path: root/Makefile.32
diff options
context:
space:
mode:
authorKoenig, Joerg <Joerg.Koenig@techsat.com>2020-04-20 06:29:33 (GMT)
committerKoenig, Joerg <Joerg.Koenig@techsat.com>2020-04-20 06:29:33 (GMT)
commitf2a88906067979a52c5a6dd95adfea8f096f6c79 (patch)
tree2a1eec18ffc8636442764818ebf7097dad78d30c /Makefile.32
parent117f3357df54a334ebc135b3d6156e237673313e (diff)
downloadgcc-compiler-suite-f2a88906067979a52c5a6dd95adfea8f096f6c79.zip
gcc-compiler-suite-f2a88906067979a52c5a6dd95adfea8f096f6c79.tar.gz
gcc-compiler-suite-f2a88906067979a52c5a6dd95adfea8f096f6c79.tar.bz2
Added rule to ditribute gcc suite (use SUITEDIR)refs/changes/02/10902/1
Change-Id: I10eacd7deb7e848fdc456d69f584d35328c3ee6a
Diffstat (limited to 'Makefile.32')
-rwxr-xr-xMakefile.32876
1 files changed, 0 insertions, 876 deletions
diff --git a/Makefile.32 b/Makefile.32
deleted file mode 100755
index f6fedd9..0000000
--- a/Makefile.32
+++ /dev/null
@@ -1,876 +0,0 @@
-###################################################################
-# Makefile to generate a GNU GCC compiler (32-Bit) collection
-#
-# - linux based mingw cross compiler
-# - windows gcc native compiler
-# - linux gcc native compiler
-#
-# all compiler including GDB
-#
-# Languages: C, C++, Fortran, Obj-C
-#
-# host
-#
-# The system that is going to run the software once it is built. Once the software
-# has been built, it will execute on this particular system.
-#
-# build
-#
-# The system where the build process is being executed. For most uses this
-# would be the same as the host system, but in case of cross-compilation
-# the two obviously differ.
-#
-# target
-#
-# The system against which the software being built will run on. This only exists, or rather
-# has a meaning, when the software being built may interact specifically with a
-# system that differs from the one it's being executed on (our host). This is the case
-# for compilers, debuggers, profilers and analyzers and other tools in general.
-#
-# Build order:
-#
-# linux hosted nativ compiler -> linux hosted mingw cross compiler -> windows hosted nativ compiler
-#
-#
-
-include versions.mk.inc
-
-ifeq ($(BUILD_NUMBER),)
-VERSION_SUITE = $(SUITE)-unofficial
-else
-VERSION_SUITE = $(SUITE)-$(BUILD_NUMBER)
-endif
-
-TOP = $(shell readlink -f .)
-PLATFORM32 = x86-linux
-PLATFORM64 = x86-linux64
-PLATFORM = $(PLATFORM32)
-ARCH32 = i686-linux-gnu
-ARCH64 = x86_64-linux-gnu
-
-GCC_PKGVERSION = "TechSAT GCC-Suite v$(VERSION_SUITE)"
-
-XGCC_TARGET32 = i686-w64-mingw32
-
-SOURCE_DIR = $(shell readlink -f $(PWD)/SOURCES)
-PATCHES_DIR = $(shell readlink -f $(PWD)/PATCHES)
-UNPACK_DIR = $(PWD)/unpack.$(PLATFORM)
-BUILD_DIR = $(PWD)/build.$(PLATFORM)
-
-INST_BASE_LINUX32 = $(PWD)/inst.$(PLATFORM32)
-INST_BASE_LINUX64 = $(PWD)/inst.$(PLATFORM64)
-INST_BASE = $(INST_BASE_LINUX32)
-
-XGCC_INST_DIR = $(INST_BASE_LINUX32)/mingw32
-XGCC_PREFIX = $(XGCC_TARGET32)-
-XGCC_BINPATH = $(XGCC_INST_DIR)/bin
-XGCC32 = "$(XGCC_BINPATH)/$(XGCC_PREFIX)gcc -m32 -march=i686 -static-libgcc"
-XGPP32 = "$(XGCC_BINPATH)/$(XGCC_PREFIX)g++ -m32 -march=i686 -static-libgcc -static-libstdc++"
-NXGCC32 = "$(XGCC_BINPATH)/$(XGCC_PREFIX)gcc -m32 -march=i686 "
-NXGPP32 = "$(XGCC_BINPATH)/$(XGCC_PREFIX)g++ -m32 -march=i686 "
-
-GCC32_BINPATH = $(INST_BASE_LINUX32)/gcc-$(VERSION_GCC)/bin
-GCC64_BINPATH = $(INST_BASE_LINUX64)/gcc-$(VERSION_GCC)/bin
-GCC_BINPATH = $(GCC32_BINPATH)
-GCC32 = "$(GCC_BINPATH)/gcc -m32 -static-libgcc"
-GXX32 = "$(GCC_BINPATH)/g++ -m32 -static-libgcc -static-libstdc++"
-GCC = "$(GCC_BINPATH)/gcc -m32 -static-libgcc"
-GXX = "$(GCC_BINPATH)/g++ -m32 -static-libgcc -static-libstdc++"
-
-
-WINGCC_ROOTNAME = gcc-$(VERSION_GCC)
-WINGCC_INST_DIR = $(PWD)/inst.x86-mingw32/$(WINGCC_ROOTNAME)
-WINGCC_SYSROOT = $(WINGCC_INST_DIR)
-
-LANGUAGES = c,c++,fortran,objc
-
-SOURCE_PACKAGES = \
- $(SOURCE_DIR)/binutils-$(VERSION_BINUTILS).tar.bz2 \
- $(SOURCE_DIR)/gcc-$(VERSION_GCC).tar.gz \
- $(SOURCE_DIR)/gdb-$(VERSION_GDB).tar.bz2 \
- $(SOURCE_DIR)/gmp-$(VERSION_GMP).tar.lz \
- $(SOURCE_DIR)/isl-$(VERSION_ISL).tar.bz2 \
- $(SOURCE_DIR)/mingw-w64-v$(VERSION_MINGW).tar.bz2 \
- $(SOURCE_DIR)/mpc-$(VERSION_MPC).tar.gz \
- $(SOURCE_DIR)/mpfr-$(VERSION_MPFR).tar.bz2 \
- $(SOURCE_DIR)/zlib-$(VERSION_ZLIB).tar.gz \
- $(SOURCE_DIR)/bzip2-$(VERSION_BZ2).tar.gz
-
-JOBS =
-
-$(SOURCE_DIR)/binutils-$(VERSION_BINUTILS).tar.bz2: _download_prepare
- wget -c https://ftp.gnu.org/gnu/binutils/binutils-$(VERSION_BINUTILS).tar.bz2 -O \
- $(SOURCE_DIR)/binutils-$(VERSION_BINUTILS).tar.bz2 2>&1
-$(SOURCE_DIR)/gcc-$(VERSION_GCC).tar.gz:
- wget -c https://ftp.gnu.org/gnu/gcc/gcc-$(VERSION_GCC)/gcc-$(VERSION_GCC).tar.gz -O \
- $(SOURCE_DIR)/gcc-$(VERSION_GCC).tar.gz
-$(SOURCE_DIR)/gmp-$(VERSION_GMP).tar.lz:
- wget -c https://gmplib.org/download/gmp/gmp-$(VERSION_GMP).tar.lz -O \
- $(SOURCE_DIR)/gmp-$(VERSION_GMP).tar.lz
-$(SOURCE_DIR)/mingw-w64-v$(VERSION_MINGW).tar.bz2:
- wget -c https://datapacket.dl.sourceforge.net/project/mingw-w64/mingw-w64/mingw-w64-release/mingw-w64-v$(VERSION_MINGW).tar.bz2 -O \
- $(SOURCE_DIR)/mingw-w64-v$(VERSION_MINGW).tar.bz2
-$(SOURCE_DIR)/mpc-$(VERSION_MPC).tar.gz:
- wget -c ftp://ftp.gnu.org/gnu/mpc/mpc-$(VERSION_MPC).tar.gz -O \
- $(SOURCE_DIR)/mpc-$(VERSION_MPC).tar.gz
-$(SOURCE_DIR)/mpfr-$(VERSION_MPFR).tar.bz2:
- wget -c http://www.mpfr.org/mpfr-current/mpfr-$(VERSION_MPFR).tar.bz2 -O \
- $(SOURCE_DIR)/mpfr-$(VERSION_MPFR).tar.bz2
-$(SOURCE_DIR)/zlib-$(VERSION_ZLIB).tar.gz:
- wget -c https://www.zlib.net/zlib-$(VERSION_ZLIB).tar.gz -O \
- $(SOURCE_DIR)/zlib-$(VERSION_ZLIB).tar.gz
-$(SOURCE_DIR)/bzip2-$(VERSION_BZ2).tar.gz:
- wget -c https://netcologne.dl.sourceforge.net/project/bzip2/bzip2-$(VERSION_BZ2).tar.gz -O \
- $(SOURCE_DIR)/bzip2-$(VERSION_BZ2).tar.gz
-$(SOURCE_DIR)/gdb-$(VERSION_GDB).tar.gz:
- wget -c ftp://sourceware.org/pub/gdb/releases/gdb-$(VERSION_GDB).tar.gz -O \
- $(SOURCE_DIR)/gdb-$(VERSION_GDB).tar.gz
-$(SOURCE_DIR)/isl-$(VERSION_ISL).tar.bz2:
- wger -c "ftp://gcc.gnu.org/pub/gcc/infrastructure/isl-$(VERSION_ISL).tar.bz2" -O \
- $(SOURCE_DIR)/isl-$(VERSION_ISL).tar.bz2
-
-download: $(SOURCE_PACKAGES)
-
-_download_prepare:
- mkdir -p $(SOURCE_DIR)
-
-all: \
- lingcc-all \
- xgcc-all \
- wingcc-all \
- fullclean
-ifneq ($(LOCAL_INST_PATH),)
- mkdir -p $(LOCAL_INST_PATH)
- mkdir -p $(LOCAL_INST_PATH)/../x86-mingw32
- cd $(LOCAL_INST_PATH); \
- tar -zxf $(PWD)/gcc-suite-$(VERSION_SUITE)-gcc-$(VERSION_GCC)-x86-linux.tgz
- cd $(LOCAL_INST_PATH); \
- tar -zxf $(PWD)/gcc-suite-$(VERSION_SUITE)-xgcc-$(VERSION_GCC)-$(VERSION_MINGW)-x86-linux.tgz
- cd $(LOCAL_INST_PATH)/../x86-mingw32; \
- unzip -o $(PWD)/gcc-suite-$(VERSION_SUITE)-gcc-$(VERSION_GCC)-$(VERSION_MINGW)-x86-mingw32.zip
-endif
-
-prepare:
- rm -Rf $(UNPACK_DIR)
- mkdir -p $(UNPACK_DIR)
- tar -zxf $(SOURCE_DIR)/gcc-$(VERSION_GCC).tar.gz -C $(UNPACK_DIR)/
- # Patches from https://gcc-mcf.lhmouse.com/ ...
- cd $(UNPACK_DIR)/gcc-$(VERSION_GCC) && \
- patch -p1 < $(PATCHES_DIR)/0002-Relocate-libintl.patch && \
- patch -p1 < $(PATCHES_DIR)/0004-Windows-Use-not-in-progpath-and-leave-case-as-is.patch && \
- patch -p1 < $(PATCHES_DIR)/0006-Windows-New-feature-to-allow-overriding.patch && \
- patch -p1 < $(PATCHES_DIR)/0008-Prettify-linking-no-undefined.patch && \
- patch -p1 < $(PATCHES_DIR)/0010-Fix-using-large-PCH.patch
- tar -zxf $(SOURCE_DIR)/gdb-$(VERSION_GDB).tar.gz -C $(UNPACK_DIR)/
- cd $(UNPACK_DIR)/gdb-$(VERSION_GDB) && \
- patch -p1 < $(PATCHES_DIR)/0004-Windows-Use-not-in-progpath-and-leave-case-as-is.patch
- tar -jxf $(SOURCE_DIR)/binutils-$(VERSION_BINUTILS).tar.bz2 -C $(UNPACK_DIR)/
- cd $(UNPACK_DIR)/binutils-$(VERSION_BINUTILS) && \
- patch -p1 < $(PATCHES_DIR)/0004-Windows-Use-not-in-progpath-and-leave-case-as-is.patch
- tar -jxf $(SOURCE_DIR)/mingw-w64-v$(VERSION_MINGW).tar.bz2 -C $(UNPACK_DIR)/
- cd $(UNPACK_DIR)/mingw-w64-v$(VERSION_MINGW)/mingw-w64-tools/widl && \
- patch -p0 < $(PATCHES_DIR)/mingw-tools-widl-realloc.patch
- tar -jxf $(SOURCE_DIR)/mpfr-$(VERSION_MPFR).tar.bz2 -C $(UNPACK_DIR)/
- tar -jxf $(SOURCE_DIR)/isl-$(VERSION_ISL).tar.bz2 -C $(UNPACK_DIR)/
- tar -zxf $(SOURCE_DIR)/mpc-$(VERSION_MPC).tar.gz -C $(UNPACK_DIR)/
- tar --lzip -xf $(SOURCE_DIR)/gmp-$(VERSION_GMP).tar.lz -C $(UNPACK_DIR)/
- tar -zxf $(SOURCE_DIR)/zlib-$(VERSION_ZLIB).tar.gz -C $(UNPACK_DIR)/
- tar -zxf $(SOURCE_DIR)/bzip2-$(VERSION_BZ2).tar.gz -C $(UNPACK_DIR)/
- #
- rm -Rf $(UNPACK_DIR)/gcc-$(VERSION_GCC)/gmp
- mv $(UNPACK_DIR)/gmp-$(VERSION_GMP) $(UNPACK_DIR)/gcc-$(VERSION_GCC)/gmp
- rm -Rf $(UNPACK_DIR)/gcc-$(VERSION_GCC)/mpc
- mv $(UNPACK_DIR)/mpc-$(VERSION_MPC) $(UNPACK_DIR)/gcc-$(VERSION_GCC)/mpc
- rm -Rf $(UNPACK_DIR)/gcc-$(VERSION_GCC)/mpfr
- mv $(UNPACK_DIR)/mpfr-$(VERSION_MPFR) $(UNPACK_DIR)/gcc-$(VERSION_GCC)/mpfr
- rm -Rf $(UNPACK_DIR)/gcc-$(VERSION_GCC)/isl
- mv $(UNPACK_DIR)/isl-$(VERSION_ISL) $(UNPACK_DIR)/gcc-$(VERSION_GCC)/isl
-
-
-build-common:
- mkdir -p $(BUILD_DIR)
-
-##############################################################################
-# Nativ Linux Compiler (32 -Bit)
-##############################################################################
-lingcc-all:
- make -f Makefile.32 ARCH=x86-linux clean
- make -f Makefile.32 ARCH=x86-linux prepare
- #
- make -f Makefile.32 ARCH=x86-linux lingcc-binutils
- make -f Makefile.32 ARCH=x86-linux lingcc-gcc
- make -f Makefile.32 ARCH=x86-linux lingcc-finish
- make -f Makefile.32 ARCH=x86-linux lingcc-gdb
- make -f Makefile.32 ARCH=x86-linux lingcc-pack
-
-lingcc-binutils:
- rm -Rf $(BUILD_DIR)/binutils
- mkdir -p $(BUILD_DIR)/binutils
- mkdir -p $(INST_BASE_LINUX32)/gcc-$(VERSION_GCC)/bin
- cd $(BUILD_DIR)/binutils ;\
- export PATH=$(INST_BASE_LINUX64)/gcc-$(VERSION_GCC)/bin:$(PATH):$(INST_BASE_LINUX32)/gcc-$(VERSION_GCC)/bin && \
- $(UNPACK_DIR)/binutils-$(VERSION_BINUTILS)/configure \
- CFLAGS="-m32" \
- CXXLAGS="-m32" \
- --with-pkgversion=$(GCC_PKGVERSION) \
- --prefix=$(INST_BASE)/gcc-$(VERSION_GCC) \
- --disable-nls \
- --enable-deterministic-archives \
- --with-gcc \
- --with-gnu-ld \
- --with-gnu-as \
- --disable-werror \
- --host=$(ARCH32) \
- --build=$(ARCH32) \
- --enable-targets=$(ARCH32) ; \
- make $(JOBS) && make $(JOBS) install-strip
- cd $(INST_BASE)/gcc-$(VERSION_GCC)/bin && \
- for f in addr2line ar as c++filt elfedit gprof ld ld.bfd nm objcopy objdump ranlib readelf size strings strip ; do \
- if [ -f $$f ]; then \
- if [ -e $(ARCH32)-$$f ]; then \
- rm -f $(ARCH32)-$$f ; \
- fi; \
- ln -s $$f $(ARCH32)-$$f ; \
- fi; \
- done;
-
-lingcc-gcc:
- rm -Rf $(BUILD_DIR)/gcc
- mkdir -p $(BUILD_DIR)/gcc
- cd $(BUILD_DIR)/gcc && \
- export PATH=$(INST_BASE_LINUX64)/gcc-$(VERSION_GCC)/bin:$(PATH):$(INST_BASE_LINUX32)/gcc-$(VERSION_GCC)/bin && \
- gcc --version && \
- CC="gcc -m32" CXX="g++ -m32" CFLAGS="-O2 -march=i686" CXXFLAGS="-O2 -march=i686" $(UNPACK_DIR)/gcc-$(VERSION_GCC)/configure \
- --host=$(ARCH32) \
- --build=$(ARCH32) \
- --target=$(ARCH32) \
- --with-sysroot=/ \
- --with-pkgversion=$(GCC_PKGVERSION) \
- --prefix=$(INST_BASE)/gcc-$(VERSION_GCC) \
- --disable-nls \
- --disable-assembly \
- --disable-multilib \
- --with-arch-32=i686 \
- --with-tune=generic\
- --enable-checking=release \
- --enable-languages=$(LANGUAGES) \
- --without-included-gettext \
- --enable-threads=posix \
- --disable-sjlj-exceptions \
- --with-dwarf2 \
- --enable-shared \
- --enable-static \
- --disable-werror \
- --disable--long-long \
- --disable-symvers \
- --enable-libstdcxx-time=yes \
- --enable-libstdcxx-debug \
- --enable-linker-build-id \
- --enable-nls \
- --disable-plugin \
- --enable-gnu-unique-object \
- --disable-vtable-verify \
- --enable-clocale=gnu \
- --disable-default-pie \
- && \
- make $(JOBS) all && \
- make $(JOBS) install-strip
-
-lingcc-finish:
- for f in `find $(INST_BASE)/gcc-$(VERSION_GCC) -type f -executable -exec file -i '{}' \; | grep 'x-executable; charset=binary' | cut -d: -f1`; do \
- strip $$f ;\
- done;
- rm -Rf $(INST_BASE)/gcc-$(VERSION_GCC)/share
- find $(INST_BASE)/gcc-$(VERSION_GCC) -type f -name "*.py" | xargs rm -f
-
-lingcc-gdb:
- rm -Rf $(BUILD_DIR)/lingdb
- mkdir -p $(BUILD_DIR)/lingdb
- cd $(BUILD_DIR)/lingdb && \
- export PATH=$(INST_BASE)/gcc-$(VERSION_GCC)/bin:$(PATH) && \
- CC="gcc -m32" \
- CXX="g++ -m32" \
- CFLAGS="-g -O2" \
- LDLAGS="-static-libgcc -static-libstdc++" \
- CXXFLAGS="-g -O2 -fpermissive" \
- $(UNPACK_DIR)/gdb-$(VERSION_GDB)/configure \
- --prefix=$(INST_BASE)/gcc-$(VERSION_GCC) \
- --target=$(ARCH32) \
- --host=$(ARCH32) \
- --build=$(ARCH64) && \
- make $(JOBS) && make $(JOBS) install
-
-lingcc-pack:
- rm -Rf $(INST_BASE)/gcc$(VERSION_GCC)/share
- cd $(INST_BASE) && \
- tar -zcf $(PWD)/gcc-suite-$(VERSION_SUITE)-gcc-$(VERSION_GCC)-x86-linux.tgz ./gcc-$(VERSION_GCC)
-
-
-##############################################################################
-# Linux based MinGW multilib cross compiler
-##############################################################################
-xgcc-all:
- make -f Makefile.32 clean
- make -f Makefile.32 prepare
- make -f Makefile.32 build-common
- make -f Makefile.32 xgcc-build-binutils
- make -f Makefile.32 xgcc-mingw-pass1
- make -f Makefile.32 xgcc-gcc-pass1
- make -f Makefile.32 xgcc-mingw-pass2
- make -f Makefile.32 xgcc-pthread
- make -f Makefile.32 xgcc-gcc-pass2
- make -f Makefile.32 xgcc-finish
- make -f Makefile.32 xgcc-gdb
- make -f Makefile.32 xgcc-zlib
- make -f Makefile.32 xgcc-bzip2
- make -f Makefile.32 xgcc-reimp
- make -f Makefile.32 xgcc-genpeimg
- make -f Makefile.32 xgcc-gendef
- make -f Makefile.32 xgcc-pack
-
-xgcc-build-binutils:
- mkdir -p $(BUILD_DIR)/binutils
- cd $(BUILD_DIR)/binutils ;\
- $(UNPACK_DIR)/binutils-$(VERSION_BINUTILS)/configure \
- LDLAGS="-static-libgcc -static-libstdc++" \
- CC="gcc -m32" \
- CXX="g++ -m32" \
- CFLAGS="-O2 -pipe" \
- CXXFLAGS="-O2 -pipe" \
- --with-pkgversion=$(GCC_PKGVERSION) \
- --prefix=$(XGCC_INST_DIR) \
- --disable-nls \
- --enable-deterministic-archives \
- --with-gcc \
- --with-gnu-ld \
- --with-gnu-as \
- --disable-werror \
- --enable-targets=$(XGCC_TARGET32) \
- --host=$(ARCH32) \
- --build=$(ARCH32) \
- --target=$(XGCC_TARGET32) ;\
- make $(JOBS) ;\
- make $(JOBS) install-strip
-
-xgcc-mingw-pass1:
- mkdir -p $(BUILD_DIR)/mingw
- cd $(BUILD_DIR)/mingw ;\
- $(UNPACK_DIR)/mingw-w64-v$(VERSION_MINGW)/mingw-w64-headers/configure \
- CC="gcc -m32" \
- CXX="g++ -m32" \
- LDLAGS="-static-libgcc -static-libstdc++" \
- CFLAGS="-O2 -pipe" \
- CXXFLAGS="-O2 -pipe" \
- --prefix=$(XGCC_INST_DIR)/$(XGCC_TARGET32) \
- --host=$(XGCC_TARGET32) ;\
- make $(JOBS) install
- cd $(XGCC_INST_DIR) && rm -f mingw && ln -s $(XGCC_TARGET32) mingw
-
-xgcc-gcc-pass1:
- mkdir -p $(BUILD_DIR)/gcc
- cd $(BUILD_DIR)/gcc && \
- $(UNPACK_DIR)/gcc-$(VERSION_GCC)/configure \
- CC="gcc -m32" \
- CXX="g++ -m32" \
- LDLAGS="-static-libgcc -static-libstdc++" \
- CFLAGS="-O2 -pipe" \
- CXXFLAGS="-O2 -pipe" \
- --with-pkgversion=$(GCC_PKGVERSION) \
- --prefix=$(XGCC_INST_DIR) \
- --with-sysroot=$(XGCC_INST_DIR) \
- --disable-nls \
- --host=$(ARCH32) \
- --build=$(ARCH32) \
- --target=$(XGCC_TARGET32) \
- --enable-languages=$(LANGUAGES) \
- --disable-win32-registry \
- --with-gcc \
- --with-gnu-ld \
- --with-gnu-as \
- --without-x \
- --enable-shared \
- --enable-static \
- --disable-werror \
- --with-tune-64=core2 \
- --disable-multilib \
- --enable-threads=posix \
- --disable-sjlj-exceptions \
- --with-dwarf2 \
- --enable-clocale=gnu \
- --enable-version-specific-runtime-libs \
- --enable-fully-dynamic-string && \
- make $(JOBS) all-gcc && \
- make $(JOBS) install-gcc
-
-xgcc-mingw-pass2:
- cd $(BUILD_DIR)/mingw && \
- export PATH=$(XGCC_INST_DIR)/bin:$(PATH) && \
- $(UNPACK_DIR)/mingw-w64-v$(VERSION_MINGW)/configure \
- LDLAGS="-static-libgcc -static-libstdc++" \
- CFLAGS="-m32 -O2 -pipe" \
- CXXFLAGS="-m32 -O2 -pipe" \
- --prefix=$(XGCC_INST_DIR)/$(XGCC_TARGET32) \
- --host=$(XGCC_TARGET32) \
- --build=$(ARCH32) \
- --disable-nls \
- --enable-sdk=all \
- --enable-idl \
- --enable-secure-api \
- --disable-lib64 \
- --enable-lib32 && \
- make $(JOBS) && \
- make $(JOBS) install
-
-xgcc-pthread:
- mkdir -p $(BUILD_DIR)/winpthreads
- cd $(BUILD_DIR)/winpthreads && \
- export PATH=$(XGCC_INST_DIR)/bin:$(PATH) && \
- LDLAGS="-static-libgcc -static-libstdc++" \
- CFLAGS="-m32 -O2 -pipe" \
- CXXFLAGS="-m32 -O2 -pipe" \
- $(UNPACK_DIR)/mingw-w64-v$(VERSION_MINGW)/mingw-w64-libraries/winpthreads/configure \
- --prefix=$(XGCC_INST_DIR)/$(XGCC_TARGET32) \
- --host=$(XGCC_TARGET32) && \
- make $(JOBS) clean && \
- make $(JOBS) && \
- make $(JOBS) install
- mv -f $(XGCC_INST_DIR)/$(XGCC_TARGET32)/bin/libwinpthread-1.dll \
- $(XGCC_INST_DIR)/$(XGCC_TARGET32)/lib
-
-xgcc-gcc-pass2:
- cd $(BUILD_DIR)/gcc && \
- make $(JOBS) && \
- make $(JOBS) install
-
-
-xgcc-finish:
- rm -f $(XGCC_INST_DIR)/i686-w64-mingw32/lib/libgcc_s.a
- cd $(XGCC_INST_DIR)/i686-w64-mingw32/lib && ln -s ../../lib/gcc/i686-w64-mingw32/lib/libgcc_s.a
- cd $(XGCC_INST_DIR) && rm -f mingw
- for f in `find $(XGCC_INST_DIR) -type f -executable -exec file -i '{}' \; | grep 'x-executable; charset=binary' | cut -d: -f1`; do \
- $(XGCC_INST_DIR)/bin/$(XGCC_TARGET32)-strip $$f ;\
- done;
- rm -Rf $(XGCC_INST_DIR)/share
- find $(XGCC_INST_DIR) -type f -name "*.py" | xargs rm -f
- cp -f $(SOURCE_DIR)/mingw.gcc.specs \
- $(XGCC_INST_DIR)/lib/gcc/$(XGCC_TARGET32)/$(VERSION_GCC)/specs
- cp -f $(SOURCE_DIR)/dll2a \
- $(XGCC_INST_DIR)/bin/$(XGCC_TARGET32)-dll2a
- chmod a+x $(XGCC_INST_DIR)/bin/$(XGCC_TARGET32)-dll2a
- #sed -i -e 's/__LIB64__/lib\/gcc\/$(XGCC_TARGET32)\/lib/g' \
- # $(XGCC_INST_DIR)/lib/gcc/$(XGCC_TARGET32)/$(VERSION_GCC)/specs
- cat $(XGCC_INST_DIR)/lib/gcc/$(XGCC_TARGET32)/$(VERSION_GCC)/specs \
- $(SOURCE_DIR)/gcc.msvcr90.spec > \
- $(XGCC_INST_DIR)/lib/gcc/$(XGCC_TARGET32)/$(VERSION_GCC)/msvcr90
- cat $(XGCC_INST_DIR)/lib/gcc/$(XGCC_TARGET32)/$(VERSION_GCC)/specs \
- $(SOURCE_DIR)/gcc.msvcr100.spec > \
- $(XGCC_INST_DIR)/lib/gcc/$(XGCC_TARGET32)/$(VERSION_GCC)/msvcr100
- cat $(XGCC_INST_DIR)/lib/gcc/$(XGCC_TARGET32)/$(VERSION_GCC)/specs \
- $(SOURCE_DIR)/gcc.msvcr110.spec > \
- $(XGCC_INST_DIR)/lib/gcc/$(XGCC_TARGET32)/$(VERSION_GCC)/msvcr110
-
-xgcc-gdb:
- rm -rf $(BUILD_DIR)/gdb && mkdir -p $(BUILD_DIR)/gdb
- cd $(BUILD_DIR)/gdb && \
- export PATH=$(XGCC_BINPATH):$(INST_BASE)/gcc-$(VERSION_GCC)/bin:$(PATH) && \
- $(UNPACK_DIR)/gdb-$(VERSION_GDB)/configure \
- LDLAGS="-m32 -static-libgcc -static-libstdc++" \
- CFLAGS="-m32 -O2 -pipe" \
- CXXFLAGS="-O2 -pipe -fpermissive" \
- --prefix=$(XGCC_INST_DIR) \
- --target=$(XGCC_TARGET32) \
- --build=$(ARCH32) \
- --host=$(ARCH32) && \
- make $(JOBS) && make $(JOBS) install
-
-
-
-xgcc-reimp:
- rm -Rf $(BUILD_DIR)/reimp
- cd $(BUILD_DIR)/ && \
- tar -zxf $(SOURCE_DIR)/reimp.tar.gz
- cd $(BUILD_DIR)/reimp/src && \
- make X=""
- cp -f $(BUILD_DIR)/reimp/src/reimp $(XGCC_INST_DIR)/bin/$(XGCC_TARGET32)-reimp
-
-
-xgcc-genpeimg:
- rm -Rf $(BUILD_DIR)/genpeimg
- mkdir -p $(BUILD_DIR)/genpeimg
- cd $(BUILD_DIR)/ && \
- export PATH=$(GCC_BINPATH):$(PATH) && \
- cd $(BUILD_DIR)/genpeimg && \
- CC=$(GCC) CXX=$(GXX) \
- LDLAGS="-static-libgcc" \
- CFLAGS="-m32 -pipe -Werror=implicit-fallthrough=0" \
- $(UNPACK_DIR)/mingw-w64-v$(VERSION_MINGW)/mingw-w64-tools/genpeimg/configure \
- --prefix=$(XGCC_INST_DIR) \
- --target=$(XGCC_TARGET32) \
- --build=$(ARCH32) \
- --host=$(ARCH32) && \
- make && \
- make install
- cp -f $(BUILD_DIR)/genpeimg/genpeimg $(XGCC_INST_DIR)/bin/$(XGCC_TARGET32)-genpeimg
-
-xgcc-gendef:
- rm -Rf $(BUILD_DIR)/gendef
- mkdir -p $(BUILD_DIR)/gendef
- export PATH=$(GCC_BINPATH):$(PATH) && \
- CC=$(GCC) CXX=$(GXX) \
- cd $(BUILD_DIR)/gendef && \
- CFLAGS="-m32 -pipe -Werror=implicit-fallthrough=0" \
- LDLAGS="-static-libgcc" \
- $(UNPACK_DIR)/mingw-w64-v$(VERSION_MINGW)/mingw-w64-tools/gendef/configure \
- --prefix=$(XGCC_INST_DIR) \
- --target=$(XGCC_TARGET32) \
- --build=$(ARCH32) \
- --host=$(ARCH32) && \
- make && \
- make install
- cp -f $(BUILD_DIR)/gendef/gendef $(XGCC_INST_DIR)/bin/$(XGCC_TARGET32)-gendef
-
-xgcc-zlib:
- mkdir -p $(BUILD_DIR)
- cd $(BUILD_DIR) && rm -Rf zlib-$(VERSION_ZLIB)
- cd $(BUILD_DIR) && tar -zxf $(SOURCE_DIR)/zlib-$(VERSION_ZLIB).tar.gz
- cd $(BUILD_DIR)/zlib-$(VERSION_ZLIB) && patch -p1 < $(PATCHES_DIR)/zlib_ranlib.patch
- cd $(BUILD_DIR)/zlib-$(VERSION_ZLIB) && \
- export PATH=$(XGCC_INST_DIR)/bin:$(PATH) && \
- CC=$(XGCC32) \
- AR=$(XGCC_BINPATH)/$(XGCC_PREFIX)ar \
- RANLIB=$(XGCC_BINPATH)/$(XGCC_PREFIX)ranlib \
- ./configure \
- --prefix=$(XGCC_INST_DIR)/$(XGCC_TARGET32) --static && \
- make clean && make
- #
- cd $(BUILD_DIR)/zlib-$(VERSION_ZLIB) && \
- export PATH=$(XGCC_INST_DIR)/bin:$(PATH) && \
- CC=$(XGCC32) \
- AR=$(XGCC_BINPATH)/$(XGCC_PREFIX)ar \
- RANLIB=$(XGCC_BINPATH)/$(XGCC_PREFIX)ranlib \
- ./configure \
- --prefix=$(XGCC_INST_DIR)/$(XGCC_TARGET32) --static && \
- make clean && make
- cd $(BUILD_DIR)/zlib-$(VERSION_ZLIB) && \
- cp -f libz.a $(XGCC_INST_DIR)/$(XGCC_TARGET32)/lib && \
- chmod 644 $(XGCC_INST_DIR)/$(XGCC_TARGET32)/lib/libz.a
-
-xgcc-bzip2:
- mkdir -p $(BUILD_DIR)
- cd $(UNPACK_DIR)/bzip2-$(VERSION_BZ2) && \
- export PATH=$(XGCC_BINPATH)/bin:$(PATH) && \
- make \
- CC=$(XGCC32) \
- PREFIX=$(XGCC_INST_DIR)/$(XGCC_TARGET32) clean libbz2.a
- cd $(UNPACK_DIR)/bzip2-$(VERSION_BZ2) && \
- cp -f bzlib.h $(XGCC_INST_DIR)/$(XGCC_TARGET32)/include && \
- cp -f libbz2.a $(XGCC_INST_DIR)/$(XGCC_TARGET32)/lib
- chmod 644 $(XGCC_INST_DIR)/$(XGCC_TARGET32)/lib/libbz2.a
-
-xgcc-pack:
- rm -Rf $(XGCC_INST_DIR)/share
- cd $(XGCC_INST_DIR)/.. && \
- tar -zcf $(PWD)/gcc-suite-$(VERSION_SUITE)-xgcc-$(VERSION_GCC)-$(VERSION_MINGW)-$(PLATFORM).tgz ./mingw32
-
-##############################################################################
-# Nativ Windows Compiler (32 -Bit)
-##############################################################################
-wingcc-all:
- make PLATFORM=x86-mingw32 -f Makefile.32 clean
- make PLATFORM=x86-mingw32 -f Makefile.32 prepare
- #
- make PLATFORM=x86-mingw32 -f Makefile.32 wingcc-binutils
- make PLATFORM=x86-mingw32 -f Makefile.32 wingcc-mingw
- make PLATFORM=x86-mingw32 -f Makefile.32 wingcc-pthread
- make PLATFORM=x86-mingw32 -f Makefile.32 wingcc-gcc
- make PLATFORM=x86-mingw32 -f Makefile.32 wingcc-finish
- make PLATFORM=x86-mingw32 -f Makefile.32 wingcc-zlib
- make PLATFORM=x86-mingw32 -f Makefile.32 wingcc-bzip2
- make PLATFORM=x86-mingw32 -f Makefile.32 wingcc-reimp
- make PLATFORM=x86-mingw32 -f Makefile.32 wingcc-gendef
- make PLATFORM=x86-mingw32 -f Makefile.32 wingcc-genpeimg
- make PLATFORM=x86-mingw32 -f Makefile.32 wingcc-genidl
- make PLATFORM=x86-mingw32 -f Makefile.32 wingcc-genlib
- make PLATFORM=x86-mingw32 -f Makefile.32 wingcc-widl
- make PLATFORM=x86-mingw32 -f Makefile.32 wingcc-gdb
- make PLATFORM=x86-mingw32 -f Makefile.32 wingcc-pack
-
-wingcc-binutils:
- mkdir -p $(BUILD_DIR)/binutils
- cd $(BUILD_DIR)/binutils ;\
- export PATH=$(XGCC_BINPATH):$(PATH) && \
- CC=$(XGCC32) CXX=$(XGPP32) \
- $(UNPACK_DIR)/binutils-$(VERSION_BINUTILS)/configure \
- --with-pkgversion=$(GCC_PKGVERSION) \
- --prefix=$(WINGCC_INST_DIR) \
- --disable-nls \
- --enable-deterministic-archives \
- --with-gcc \
- --with-gnu-ld \
- --with-gnu-as \
- --enable-static \
- --disable-werror \
- --disable-rpath \
- --enable-targets=$(XGCC_TARGET32) \
- --build=$(ARCH32) \
- --host=$(XGCC_TARGET32) \
- --target=$(XGCC_TARGET32) &&\
- make $(JOBS) && make $(JOBS) install-strip
- cd $(WINGCC_INST_DIR)/bin && \
- for f in addr2line.exe as.exe dlltool.exe elfedit.exe ld.bfd.exe nm.exe objdump.exe readelf.exe strings.exe windmc.exe ar.exe c++filt.exe dllwrap.exe gprof.exe ld.exe objcopy.exe ranlib.exe size.exe strip.exe windres.exe ; do \
- if [ -f $$f ]; then \
- if [ -e $(XGCC_TARGET32)-$$f ]; then \
- rm -f $(XGCC_TARGET32)-$$f ; \
- fi; \
- cp -f $$f $(XGCC_TARGET32)-$$f ; \
- fi; \
- done;
-
-wingcc-mingw:
- rm -Rf $(BUILD_DIR)/mingw && mkdir -p $(BUILD_DIR)/mingw
- cd $(BUILD_DIR)/mingw && \
- export PATH=$(XGCC_BINPATH):$(PATH) && \
- CC=$(XGCC32) CXX=$(XGPP32) \
- $(UNPACK_DIR)/mingw-w64-v$(VERSION_MINGW)/configure \
- --prefix=$(WINGCC_INST_DIR)/$(XGCC_TARGET32) \
- --host=$(XGCC_TARGET32) \
- --target=$(XGCC_TARGET32) \
- --build=$(ARCH32) \
- --disable-nls \
- --enable-sdk=all \
- --enable-idl \
- --enable-secure-api \
- --disable-lib64 \
- --enable-lib32 && \
- make $(JOBS) && \
- make $(JOBS) install
- cd $(WINGCC_INST_DIR) && rm -f mingw && ln -s $(XGCC_TARGET32) mingw
-
-wingcc-pthread:
- rm -Rf $(BUILD_DIR)/winpthreads && mkdir -p $(BUILD_DIR)/winpthreads
- cd $(BUILD_DIR)/winpthreads && \
- export PATH=$(XGCC_BINPATH):$(PATH) && \
- CC=$(XGCC32) CXX=$(XGPP32) \
- $(UNPACK_DIR)/mingw-w64-v$(VERSION_MINGW)/mingw-w64-libraries/winpthreads/configure \
- --prefix=$(WINGCC_INST_DIR)/$(XGCC_TARGET32) \
- --host=$(XGCC_TARGET32) && \
- make $(JOBS) && \
- make $(JOBS) install
- cp -f $(WINGCC_INST_DIR)/$(XGCC_TARGET32)/bin/libwinpthread-1.dll \
- $(WINGCC_INST_DIR)/$(XGCC_TARGET32)/lib
-
-wingcc-gcc:
- rm -Rf $(BUILD_DIR)/gcc && mkdir -p $(BUILD_DIR)/gcc
- cd $(BUILD_DIR)/gcc && \
- export PATH=$(XGCC_BINPATH):$(PATH) && \
- gcc -v && \
- $(UNPACK_DIR)/gcc-$(VERSION_GCC)/configure \
- --with-pkgversion=$(GCC_PKGVERSION) \
- --prefix=$(WINGCC_INST_DIR) \
- --with-sysroot=$(WINGCC_INST_DIR) \
- --disable-nls \
- --build=$(ARCH64) \
- --host=$(XGCC_TARGET32) \
- --target=$(XGCC_TARGET32) \
- --enable-languages=$(LANGUAGES) \
- --enable-threads=posix \
- --disable-sjlj-exceptions \
- --with-dwarf2 \
- --with-gcc \
- --with-gnu-ld \
- --with-gnu-as \
- --without-x \
- --disable-werror \
- --disable-win32-registry \
- --disable-symvers \
- --disable-multilib \
- --enable-clocale=gnu \
- --enable-version-specific-runtime-libs \
- --enable-fully-dynamic-string && \
- make CFLAGS="-O2 -Wshadow -Wexpansion-to-defined" $(JOBS) all && \
- make $(JOBS) install-strip
-
-wingcc-finish:
- cd $(WINGCC_INST_DIR)/bin && \
- mkdir -p ../tmp; \
- mv $(XGCC_TARGET32)-*.exe ../tmp ; \
- for f in *.exe; do \
- cp -f $$f $(XGCC_TARGET32)-`basename $$f` > /dev/null 2>&1 ;\
- done; \
- mv ../tmp/* . ;\
- rm -Rf ../tmp ;
- find $(WINGCC_INST_DIR) -type f -name "*.py" | xargs rm -f
- cd $(WINGCC_INST_DIR) && rm -Rf share
- cd $(WINGCC_INST_DIR) && rm -f mingw
- cd $(WINGCC_INST_DIR) ;\
- find . -type f -name "*.exe" | xargs $(XGCC_BINPATH)/$(XGCC_PREFIX)strip
- #
- cp -f $(SOURCE_DIR)/mingw.gcc.specs \
- $(WINGCC_INST_DIR)/lib/gcc/$(XGCC_TARGET32)/$(VERSION_GCC)/specs
- #sed -i -e 's/__LIB64__/lib\/gcc\/$(XGCC_TARGET32)\/lib/g' \
- # $(WINGCC_INST_DIR)/lib/gcc/$(XGCC_TARGET32)/$(VERSION_GCC)/specs
- cat $(WINGCC_INST_DIR)/lib/gcc/$(XGCC_TARGET32)/$(VERSION_GCC)/specs \
- $(SOURCE_DIR)/gcc.msvcr90.spec > \
- $(WINGCC_INST_DIR)/lib/gcc/$(XGCC_TARGET32)/$(VERSION_GCC)/msvcr90
- cat $(WINGCC_INST_DIR)/lib/gcc/$(XGCC_TARGET32)/$(VERSION_GCC)/specs \
- $(SOURCE_DIR)/gcc.msvcr100.spec > \
- $(WINGCC_INST_DIR)/lib/gcc/$(XGCC_TARGET32)/$(VERSION_GCC)/msvcr100
- cat $(WINGCC_INST_DIR)/lib/gcc/$(XGCC_TARGET32)/$(VERSION_GCC)/specs \
- $(SOURCE_DIR)/gcc.msvcr110.spec > \
- $(WINGCC_INST_DIR)/lib/gcc/$(XGCC_TARGET32)/$(VERSION_GCC)/msvcr110
- cd $(WINGCC_INST_DIR)/lib/gcc/$(XGCC_TARGET32)/$(VERSION_GCC)/ && \
- ln -s ../../lib/libgcc_s.a
-
-
-wingcc-reimp:
- rm -Rf $(BUILD_DIR)/reimp
- cd $(BUILD_DIR)/ && \
- tar -zxf $(SOURCE_DIR)/reimp.tar.gz
- export PATH=$(PWD)/inst.x86-linux/gcc-$(VERSION_GCC)/bin:$(XGCC_BINPATH):$(PATH) && \
- cd $(BUILD_DIR)/reimp/src && \
- make CC="$(XGCC_TARGET32)-gcc -m32"
- cp -f $(BUILD_DIR)/reimp/src/reimp.exe $(WINGCC_INST_DIR)/bin/reimp.exe
- cp -f $(BUILD_DIR)/reimp/src/reimp.exe $(WINGCC_INST_DIR)/bin/$(XGCC_TARGET32)-reimp.exe
-
-wingcc-gmake:
- rm -Rf $(BUILD_DIR)/make-4.2
- cd $(BUILD_DIR)/ && \
- tar -jxf $(SOURCE_DIR)/make-4.2.tar.bz2
- cd $(BUILD_DIR)/make-4.2 && \
- export PATH=$(PWD)/inst.x86-linux/gcc-$(VERSION_GCC)/bin:$(XGCC_BINPATH):$(PATH) && \
- CC=$(XGCC32) CXX=$(XGPP32) \
- ./configure \
- CFLAGS="-I../glob" \
- --host=$(XGCC_TARGET32) \
- --prefix=$(WINGCC_INST_DIR) \
- --host=$(XGCC_TARGET32) && \
- make && make install
- cp -f $(WINGCC_INST_DIR)/bin/make.exe $(WINGCC_INST_DIR)/bin/$(XGCC_TARGET32)-make.exe
-
-wingcc-genpeimg:
- rm -Rf $(BUILD_DIR)/genpeimg
- mkdir -p $(BUILD_DIR)/genpeimg
- cd $(BUILD_DIR)/genpeimg && \
- export PATH=$(XGCC_BINPATH):$(PATH) && \
- CC=$(XGCC32) CXX=$(XGPP32) genpeimg_CFLAGS="" CFLAGS="-O3 -g -Werror=implicit-fallthrough=0"\
- $(UNPACK_DIR)/mingw-w64-v$(VERSION_MINGW)/mingw-w64-tools/genpeimg/configure \
- --host=$(XGCC_TARGET32) && \
- make
- cp -f $(BUILD_DIR)/genpeimg/genpeimg.exe \
- $(WINGCC_INST_DIR)/bin/$(XGCC_TARGET32)-genpeimg.exe
-
-wingcc-gendef:
- rm -Rf $(BUILD_DIR)/gendef
- mkdir -p $(BUILD_DIR)/gendef && \
- cd $(BUILD_DIR)/gendef && \
- export PATH=$(XGCC_BINPATH):$(PATH) && \
- CC=$(XGCC32) CXX=$(XGPP32) genpeimg_CFLAGS="" CFLAGS="-O3 -g -Wno-error=cast-function-type -Werror=implicit-fallthrough=0"\
- $(UNPACK_DIR)/mingw-w64-v$(VERSION_MINGW)/mingw-w64-tools/gendef/configure \
- --host=$(XGCC_TARGET32) && \
- make
- cp -f $(BUILD_DIR)/gendef/gendef.exe $(WINGCC_INST_DIR)/bin/$(XGCC_TARGET32)-gendef.exe
-
-wingcc-genidl:
- rm -Rf $(BUILD_DIR)/genidl
- mkdir -p $(BUILD_DIR)/genidl
- cd $(BUILD_DIR)/genidl && \
- export PATH=$(XGCC_BINPATH):$(PATH) && \
- CC=$(XGCC32) CXX=$(XGPP32) CFLAGS="-O3 -g -Wno-error=cast-function-type -Werror=implicit-fallthrough=0"\
- $(UNPACK_DIR)/mingw-w64-v$(VERSION_MINGW)/mingw-w64-tools/genidl/configure \
- --prefix=$(WINGCC_INST_DIR) \
- --host=$(XGCC_TARGET32) && \
- make && \
- make install
-
-wingcc-genlib:
- rm -Rf $(BUILD_DIR)/genlib
- mkdir -p $(BUILD_DIR)/genlib
- cd $(BUILD_DIR)/genlib && \
- export PATH=$(XGCC_BINPATH):$(PATH) && \
- CC=$(XGCC32) CXX=$(XGPP32) CFLAGS="-O3 -g -Wno-error=cast-function-type -Werror=implicit-fallthrough=0"\
- $(UNPACK_DIR)/mingw-w64-v$(VERSION_MINGW)/mingw-w64-tools/genlib/configure \
- --prefix=$(WINGCC_INST_DIR) \
- --host=$(XGCC_TARGET32) && \
- make && \
- make install
-
-wingcc-widl:
- cd $(UNPACK_DIR)/mingw-w64-v$(VERSION_MINGW)/mingw-w64-tools/widl && \
- autoconf
- rm -Rf $(BUILD_DIR)/widl
- mkdir -p $(BUILD_DIR)/widl
- cd $(BUILD_DIR)/widl && \
- export PATH=$(XGCC_BINPATH):$(PATH) && \
- ac_cv_func_malloc_0_nonnull=yes CC=$(XGCC32) CXX=$(XGPP32) CFLAGS="-O3 -g -Wno-error=cast-function-type -Werror=implicit-fallthrough=0"\
- $(UNPACK_DIR)/mingw-w64-v$(VERSION_MINGW)/mingw-w64-tools/widl/configure \
- --prefix=$(WINGCC_INST_DIR) \
- --host=$(XGCC_TARGET32) && \
- make && \
- make install
-
-
-wingcc-zlib:
- mkdir -p $(BUILD_DIR)
- cd $(BUILD_DIR) && rm -Rf zlib-$(VERSION_ZLIB)
- cd $(BUILD_DIR) && tar -zxf $(SOURCE_DIR)/zlib-$(VERSION_ZLIB).tar.gz
- cd $(BUILD_DIR)/zlib-$(VERSION_ZLIB) && patch -p1 < $(PATCHES_DIR)/zlib_ranlib.patch
- cd $(BUILD_DIR)/zlib-$(VERSION_ZLIB) && \
- export PATH=$(PWD)/inst.x86-linux/gcc-$(VERSION_GCC)/bin:$(XGCC_BINPATH):$(PATH) && \
- CC=$(XGCC32) \
- AR=$(XGCC_BINPATH)/$(XGCC_PREFIX)ar \
- RANLIB=$(XGCC_BINPATH)/$(XGCC_PREFIX)ranlib \
- ./configure \
- --prefix=$(WINGCC_INST_DIR) --static && \
- make clean && make
- #
- cd $(BUILD_DIR)/zlib-$(VERSION_ZLIB) && \
- cp -f libz.a $(WINGCC_INST_DIR)/lib && \
- cp -f zlib.h zconf.h $(WINGCC_INST_DIR)/include
- #
- chmod 644 $(WINGCC_INST_DIR)/lib/libz.a
- chmod 644 $(WINGCC_INST_DIR)/include/zlib.h
- chmod 644 $(WINGCC_INST_DIR)/include/zconf.h
-
-wingcc-bzip2:
- cd $(UNPACK_DIR)/bzip2-$(VERSION_BZ2) && \
- export PATH=$(PWD)/inst.x86-linux/gcc-$(VERSION_GCC)/bin:$(XGCC_BINPATH):$(PATH) && \
- make \
- CC=$(XGCC32) \
- PREFIX=$(WINGCC_INST_DIR) libbz2.a
- cd $(UNPACK_DIR)/bzip2-$(VERSION_BZ2) && \
- cp -f bzlib.h $(WINGCC_INST_DIR)/include && \
- cp -f libbz2.a $(WINGCC_INST_DIR)/lib
- chmod 644 $(WINGCC_INST_DIR)/lib/libbz2.a
-
-wingcc-gdb:
- rm -Rf $(BUILD_DIR)/gdb && mkdir -p $(BUILD_DIR)/gdb
- cd $(BUILD_DIR)/gdb && \
- export PATH=$(PWD)/inst.x86-linux/gcc-$(VERSION_GCC)/bin:$(XGCC_BINPATH):$(PATH) && \
- CXXFLAGS="-m32 -g -O2 -fpermissive" \
- CFLAGS="-m32 -g -O2" \
- CC=$(XGCC32) CXX=$(XGPP32) \
- $(UNPACK_DIR)/gdb-$(VERSION_GDB)/configure \
- --prefix=$(WINGCC_INST_DIR) \
- --target=$(XGCC_TARGET32) \
- --host=$(XGCC_TARGET32) \
- --build=$(ARCH32) && \
- make $(JOBS) && make $(JOBS) install
- cp -f $(WINGCC_INST_DIR)/bin/gdb.exe \
- $(WINGCC_INST_DIR)/bin/$(XGCC_TARGET32)-gdb.exe
- cp -f $(WINGCC_INST_DIR)/bin/gdbserver.exe \
- $(WINGCC_INST_DIR)/bin/$(XGCC_TARGET32)-gdbserver.exe
-wingcc-pack:
- rm -Rf $(WINGCC_INST_DIR)/share
- cd $(WINGCC_INST_DIR)/.. && \
- zip -qr $(PWD)/gcc-suite-$(VERSION_SUITE)-gcc-$(VERSION_GCC)-$(VERSION_MINGW)-x86-mingw32.zip ./$(WINGCC_ROOTNAME)
-# ----------------------------------------------------------------------------
-
-clean:
- rm -Rf $(UNPACK_DIR)
- rm -Rf $(BUILD_DIR)
-
-fullclean: clean
- rm -Rf inst.*
- rm -Rf build.*
- rm -Rf unpack.*
-