Skip to content
This repository

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse code

Promote GCC 4.7 to be the default compiler

This commit causes world and kernel to be built by GCC 4.7 if the compiler
is not specified.  As a side effect, the make variable "NO_GCC47" no longer
functions.  GCC 4.7 will always be built.  In addition to changing the
default of WORLD_CCVER, the CCVER variable also defaults to "gcc47" now.

The variable "NO_GCC44" has been resurrected to prevent GCC 4.4 from
being built.  As noted in the UPDATING file, using this option is highly
discouraged.  GCC 4.4 is very useful in building some packages in pkgsrc
that fail to build with GCC 4.7's stricter standards.  The new DPorts
system is designed to use GCC 4.4 by default, regardless of the base's
default compiler setting.  If at all possible, build *both* compilers
for the maximum flexibility to build packages.
  • Loading branch information...
commit 6100d1de78f204e56aabe46c57a31d6a686e8f55 1 parent 75e35d3
John Marino authored
10 Makefile.inc1
@@ -119,7 +119,7 @@ DESTDIRBASE?= ${OBJTREE}${.CURDIR}
119 119 .MAKEFLAGS:= ${.MAKEFLAGS:NDESTDIR=*}
120 120
121 121 # This section sets the tools used to build the world/kernel
122   -WORLD_CCVER?= gcc44
  122 +WORLD_CCVER?= gcc47
123 123 WORLD_LDVER?= ld.bfd
124 124 WORLD_BINUTILSVER?= binutils222
125 125
@@ -840,12 +840,12 @@ _share= share/syscons/scrnmaps
840 840 .endif
841 841
842 842 _gcc_common_cross= gnu/usr.bin/gmp gnu/usr.bin/mpfr
  843 +.if !defined(NO_GCC44)
843 844 _gcc44_cross= gnu/usr.bin/cc44
844 845 _gcc44_tools= gnu/usr.bin/cc44/cc_prep gnu/usr.bin/cc44/cc_tools
845   -.if !defined(NO_GCC47)
  846 +.endif
846 847 _gcc47_cross= lib/libz gnu/usr.bin/mpc gnu/usr.bin/cc47
847 848 _gcc47_tools= gnu/usr.bin/cc47/cc_prep gnu/usr.bin/cc47/cc_tools
848   -.endif
849 849 _custom_cross= libexec/customcc
850 850 _binutils= gnu/usr.bin/${WORLD_BINUTILSVER}
851 851
@@ -911,14 +911,14 @@ hierarchy:
911 911 # to specify the correct CCVER or 'cc' will not exec the correct compiler.
912 912 #
913 913 libraries:
914   -.if !defined(NO_GCC47)
915 914 cd ${.CURDIR}; \
916 915 HOST_CCVER=${HOST_CCVER} CCVER=gcc47 \
917 916 make -f Makefile.inc1 _startup_libs47;
918   -.endif
  917 +.if !defined(NO_GCC44)
919 918 cd ${.CURDIR}; \
920 919 HOST_CCVER=${HOST_CCVER} CCVER=gcc44 \
921 920 make -f Makefile.inc1 _startup_libs44;
  921 +.endif
922 922 cd ${.CURDIR}; \
923 923 make -f Makefile.inc1 _startup_libs; \
924 924 make -f Makefile.inc1 _prebuild_libs; \
13 UPDATING
@@ -8,6 +8,19 @@
8 8 # If you discover any problem, please contact the bugs@lists.dragonflybsd.org
9 9 # mailing list with the details.
10 10
  11 +GCC 4.7
  12 +-------
  13 +
  14 +DragonFly has switched base compilers. GCC 4.7 is now the default
  15 +compiler and GCC 4.4 is the alternative compiler. The "NO_GCC47" make
  16 +variable ceases to work now.
  17 +
  18 +Users who wish to build only GCC 4.7 have to use NO_GCC44 in the
  19 +/etc/make.conf to prohibit GCC 4.4 from building. However, using it is
  20 +highly discouraged. There are a few packages in pkgsrc that do not build
  21 +with GCC 4.7 and the new "DPorts" system uses GCC 4.4 by default. At
  22 +this time, it is recommended to keep both compilers on the base system.
  23 +
11 24 +-----------------------------------------------------------------------+
12 25 + UPGRADING DRAGONFLY FROM 3.2 to later versions +
13 26 +-----------------------------------------------------------------------+
14 gnu/usr.bin/Makefile
@@ -19,18 +19,14 @@ SUBDIR+= ${BU_BACKUP}
19 19
20 20 SUBDIR+= gmp
21 21 SUBDIR+= mpfr
22   -
23   -.if !defined(NO_GCC47)
24 22 SUBDIR+= mpc
25   -.endif
26   -
27   -SUBDIR+= cc44
28   -
29   -.if !defined(NO_GCC47)
30 23 SUBDIR+= cc47
31   -.ORDER: ${BU_PRIMARY} gmp mpfr mpc cc44 cc47
  24 +
  25 +.if defined(NO_GCC44)
  26 +.ORDER: ${BU_PRIMARY} gmp mpfr mpc cc47
32 27 .else
33   -.ORDER: ${BU_PRIMARY} gmp mpfr cc44
  28 +SUBDIR+= cc44
  29 +.ORDER: ${BU_PRIMARY} gmp mpfr mpc cc47 cc44
34 30 .endif
35 31
36 32 # maximum parallelism
2  usr.bin/objformat/objformat.c
@@ -37,7 +37,7 @@
37 37 #include <unistd.h>
38 38
39 39 #ifndef CCVER_DEFAULT
40   -#define CCVER_DEFAULT "gcc44"
  40 +#define CCVER_DEFAULT "gcc47"
41 41 #endif
42 42
43 43 #ifndef BINUTILSVER_DEFAULT

0 comments on commit 6100d1d

Please sign in to comment.
Something went wrong with that request. Please try again.