From 2290a76e7a4bdc5290ff0b489ac84b494f3580f3 Mon Sep 17 00:00:00 2001 From: John Marino Date: Sat, 29 Sep 2012 19:57:07 +0200 Subject: [PATCH] Relocate libgmp and libmpfr world makefiles This action prepares for the import of GCC 4.7 into base. GCC 4.4, unlike GCC 4.1, requires gmp and mpfr, and these libraries were part of the GCC 4.4 world makefile set. GCC 4.7 also needs these libraries, so rather than build them twice, they are moved out to a common area where both compilers can use them. --- Makefile.inc1 | 2 +- gnu/usr.bin/Makefile | 4 ++-- gnu/usr.bin/cc44/Makefile.inc | 9 +++++---- gnu/usr.bin/{cc44 => }/gmp/Makefile | 2 +- gnu/usr.bin/{cc44 => }/gmp/Makefile.i386 | 0 gnu/usr.bin/{cc44 => }/gmp/Makefile.x86_64 | 0 gnu/usr.bin/{cc44 => }/gmp/config.h | 0 gnu/usr.bin/{cc44 => }/gmp/gmp.h | 0 gnu/usr.bin/{cc44 => }/mpfr/Makefile | 3 ++- gnu/usr.bin/{cc44 => }/mpfr/mparam.h | 0 10 files changed, 11 insertions(+), 9 deletions(-) rename gnu/usr.bin/{cc44 => }/gmp/Makefile (99%) rename gnu/usr.bin/{cc44 => }/gmp/Makefile.i386 (100%) rename gnu/usr.bin/{cc44 => }/gmp/Makefile.x86_64 (100%) rename gnu/usr.bin/{cc44 => }/gmp/config.h (100%) rename gnu/usr.bin/{cc44 => }/gmp/gmp.h (100%) rename gnu/usr.bin/{cc44 => }/mpfr/Makefile (97%) rename gnu/usr.bin/{cc44 => }/mpfr/mparam.h (100%) diff --git a/Makefile.inc1 b/Makefile.inc1 index 77610f2828..da2a3c86b4 100644 --- a/Makefile.inc1 +++ b/Makefile.inc1 @@ -809,7 +809,7 @@ _share= share/syscons/scrnmaps _gcc41_cross= gnu/usr.bin/cc41 _gcc41_tools= gnu/usr.bin/cc41/cc_prep gnu/usr.bin/cc41/cc_tools .endif -_gcc44_cross= gnu/usr.bin/cc44 +_gcc44_cross= gnu/usr.bin/gmp gnu/usr.bin/mpfr gnu/usr.bin/cc44 _gcc44_tools= gnu/usr.bin/cc44/cc_prep gnu/usr.bin/cc44/cc_tools _custom_cross= libexec/customcc _binutils= gnu/usr.bin/${WORLD_BINUTILSVER} diff --git a/gnu/usr.bin/Makefile b/gnu/usr.bin/Makefile index e2b976edeb..0152d1977d 100644 --- a/gnu/usr.bin/Makefile +++ b/gnu/usr.bin/Makefile @@ -18,8 +18,8 @@ SUBDIR+= ${BU_BACKUP} .endif .if !defined(NO_GCC41) -SUBDIR+= cc41 -.ORDER: ${BU_PRIMARY} cc41 +SUBDIR+= gmp mpfr cc41 +.ORDER: ${BU_PRIMARY} gmp mpfr cc41 .endif SUBDIR+= cc44 diff --git a/gnu/usr.bin/cc44/Makefile.inc b/gnu/usr.bin/cc44/Makefile.inc index c6f46850ac..b1f622bc6b 100644 --- a/gnu/usr.bin/cc44/Makefile.inc +++ b/gnu/usr.bin/cc44/Makefile.inc @@ -31,8 +31,9 @@ CFLAGS+= -I${GCCDIR}/gcc -I${GCCDIR}/gcc/config -I${GCCDIR}/include CFLAGS+= -I${GCCDIR}/libcpp/include CFLAGS+= -I${GCCDIR}/libdecnumber -I${GCCDIR}/libdecnumber/dpd CFLAGS+= -I${OTOPDIR}/libdecnumber -CFLAGS+= -I${STOPDIR}/gmp -CFLAGS+= -I${.CURDIR}/${TOP_PREFIX}/../../../../contrib/mpfr/src -I${STOPDIR}/mpfr +CFLAGS+= -I${STOPDIR}/../gmp +CFLAGS+= -I${.CURDIR}/${TOP_PREFIX}/../../../../contrib/mpfr/src +CFLAGS+= -I${STOPDIR}/../mpfr CFLAGS+= -I${GCCDIR}/gcc/config/${GCC_CPU} -I${TOOLDIR} CFLAGS+= -DIN_GCC -DHAVE_CONFIG_H @@ -59,8 +60,8 @@ LIBBACKEND= ${OTOPDIR}/libbackend/libbackend.a LIBCPP= ${OTOPDIR}/libcpp/libcpp.a LIBDECNUMBER= ${OTOPDIR}/libdecnumber/libdecnumber.a -LIBGMP= ${OTOPDIR}/gmp/libgmp.a -LIBMPFR= ${OTOPDIR}/mpfr/libmpfr.a +LIBGMP= ${OTOPDIR}/../gmp/libgmp.a +LIBMPFR= ${OTOPDIR}/../mpfr/libmpfr.a GMPLIBS= ${LIBMPFR} ${LIBGMP} STDLIBS= ${LIBCPP} ${LIBIBERTY} ${LIBDECNUMBER} diff --git a/gnu/usr.bin/cc44/gmp/Makefile b/gnu/usr.bin/gmp/Makefile similarity index 99% rename from gnu/usr.bin/cc44/gmp/Makefile rename to gnu/usr.bin/gmp/Makefile index ac5c7c9abb..fb6789f6b1 100644 --- a/gnu/usr.bin/cc44/gmp/Makefile +++ b/gnu/usr.bin/gmp/Makefile @@ -1,7 +1,7 @@ LIB= gmp INTERNALLIB= # yes -CONTRIBDIR= ${.CURDIR}/../../../../contrib/gmp +CONTRIBDIR= ${.CURDIR}/../../../contrib/gmp .PATH: ${CONTRIBDIR} .include "${.CURDIR}/Makefile.${MACHINE_ARCH}" diff --git a/gnu/usr.bin/cc44/gmp/Makefile.i386 b/gnu/usr.bin/gmp/Makefile.i386 similarity index 100% rename from gnu/usr.bin/cc44/gmp/Makefile.i386 rename to gnu/usr.bin/gmp/Makefile.i386 diff --git a/gnu/usr.bin/cc44/gmp/Makefile.x86_64 b/gnu/usr.bin/gmp/Makefile.x86_64 similarity index 100% rename from gnu/usr.bin/cc44/gmp/Makefile.x86_64 rename to gnu/usr.bin/gmp/Makefile.x86_64 diff --git a/gnu/usr.bin/cc44/gmp/config.h b/gnu/usr.bin/gmp/config.h similarity index 100% rename from gnu/usr.bin/cc44/gmp/config.h rename to gnu/usr.bin/gmp/config.h diff --git a/gnu/usr.bin/cc44/gmp/gmp.h b/gnu/usr.bin/gmp/gmp.h similarity index 100% rename from gnu/usr.bin/cc44/gmp/gmp.h rename to gnu/usr.bin/gmp/gmp.h diff --git a/gnu/usr.bin/cc44/mpfr/Makefile b/gnu/usr.bin/mpfr/Makefile similarity index 97% rename from gnu/usr.bin/cc44/mpfr/Makefile rename to gnu/usr.bin/mpfr/Makefile index ff347884d0..f2fa7b4994 100644 --- a/gnu/usr.bin/cc44/mpfr/Makefile +++ b/gnu/usr.bin/mpfr/Makefile @@ -1,4 +1,4 @@ -CONTRIBDIR= ${.CURDIR}/../../../../contrib/mpfr/src +CONTRIBDIR= ${.CURDIR}/../../../contrib/mpfr/src .PATH: ${CONTRIBDIR} LIB= mpfr @@ -6,6 +6,7 @@ INTERNALLIB= # yes CFLAGS+= -I${CONTRIBDIR} CFLAGS+= -I${.OBJDIR} +CFLAGS+= -I${.CURDIR} CFLAGS+= -I${.CURDIR}/../gmp CFLAGS+=-DHAVE_INTTYPES_H=1 -DHAVE_STDINT_H=1 -DTIME_WITH_SYS_TIME=1 \ -DHAVE_LOCALE_H=1 -DHAVE_WCHAR_H=1 -DHAVE_STDARG=1 \ diff --git a/gnu/usr.bin/cc44/mpfr/mparam.h b/gnu/usr.bin/mpfr/mparam.h similarity index 100% rename from gnu/usr.bin/cc44/mpfr/mparam.h rename to gnu/usr.bin/mpfr/mparam.h -- 2.41.0