Browse Source

Clifford Wolf:


			
			
				rocklinux
			
			
		
Clifford Wolf 20 years ago
parent
commit
f6806b3f7b
3 changed files with 31 additions and 1 deletions
  1. +4
    -0
      package/base/gcc/config-300.hlp
  2. +2
    -0
      package/base/gcc/config-300.in
  3. +25
    -1
      package/base/gcc/gcc.conf

+ 4
- 0
package/base/gcc/config-300.hlp

@ -52,3 +52,7 @@ ROCKCFG_PKG_GCC33_NO_JAVA
ROCKCFG_PKG_GCC34_NO_JAVA ROCKCFG_PKG_GCC34_NO_JAVA
Please check here if you don't want to build the gcc34 JAVA compiler. Please check here if you don't want to build the gcc34 JAVA compiler.
ROCKCFG_PKG_GCC34_PROFILED
Enables profiling during GCC bootstrap and so yields an optimised
compiler. Build speedup might be 5-10%.

+ 2
- 0
package/base/gcc/config-300.in

@ -103,6 +103,8 @@ then
comment '--- GCC 3.4.x options' comment '--- GCC 3.4.x options'
bool 'Do not build JAVA compiler' \ bool 'Do not build JAVA compiler' \
ROCKCFG_PKG_GCC34_NO_JAVA 0 ROCKCFG_PKG_GCC34_NO_JAVA 0
bool 'Do profiled bootstrap' \
ROCKCFG_PKG_GCC34_PROFILED 1
%include package/*/*/subconfig-gcc34.in %include package/*/*/subconfig-gcc34.in
fi fi

+ 25
- 1
package/base/gcc/gcc.conf

@ -204,7 +204,11 @@ custmain() {
--with-gnu-ld --enable-threads=posix --with-gnu-ld --enable-threads=posix
hook_eval premake hook_eval premake
eval "$MAKE GCJFLAGS=\"$CXXFLAGS\" all"
if [ $xpkg = gcc34 -a "$ROCKCFG_PKG_GCC34_PROFILED" != 0 ]; then
eval "$MAKE GCJFLAGS=\"$CXXFLAGS\" profiledbootstrap"
else
eval "$MAKE GCJFLAGS=\"$CXXFLAGS\" all"
fi
hook_eval inmake hook_eval inmake
eval "$MAKE $makeinstopt install" eval "$MAKE $makeinstopt install"
@ -292,6 +296,25 @@ custmain() {
fi fi
fi fi
# Inject our default optimisation options so when the user calls
# gcc/g++ they match the ones used to precompile the headers ...
#
# Save the options affectioning optimization only - for injection into the specs
# file. They should be the gcc default options since they match the ones used
# to generate the PCHs. -ReneR
#
# Ideas for simplifications welcome ...
#
echo "Adapting gcc specs file..."
cd $root/$prefix/lib/${gcc_lib_dir}
mv specs specs.orig
tr '\n' '@' < specs.orig | sed -e "s|@\\*cc1_options:@|@*cc1_options:@$(
eval echo \$GCC_WRAPPER_INSERT \$GCC_WRAPPER_APPEND \
\$GCC${ver:0:1}_WRAPPER_INSERT \$GCC${ver:0:1}_WRAPPER_APPEND | \
tr ' ' '\n' | sed -e '/-O./ { p; d; }' -e '/-mcpu=.*/ { p; d; }' \
-e '/-march=.*/ { p; d; }' -e '/-mtune=.*/ { p; d; }' -e 'd' | tr '\n' ' '
) |" | tr '@' '\n' > specs
# Create symlinks for runtime libraries so they can be found by # Create symlinks for runtime libraries so they can be found by
# the dynamic loader and force rebuilding of the wrapper links # the dynamic loader and force rebuilding of the wrapper links
# #
@ -395,4 +418,5 @@ else
fi fi
gcc_lib_dir="gcc-lib/${pkg_gcc_target}/${ver%%-*}" gcc_lib_dir="gcc-lib/${pkg_gcc_target}/${ver%%-*}"
[ $pkg_gcc_version = 34 ] && gcc_lib_dir="gcc/${pkg_gcc_target}/${ver%%-*}"

Loading…
Cancel
Save