OpenPKG CVS Repository
http://cvs.openpkg.org/
____________________________________________________________________________
Server: cvs.openpkg.org Name: Ralf S. Engelschall
Root: /v/openpkg/cvs Email: [EMAIL PROTECTED]
Module: openpkg-src Date: 12-Mar-2008 17:45:08
Branch: HEAD Handle: 2008031216450500
Modified files:
openpkg-src/gcc43 gcc43.spec
Log:
sync with gcc package
Summary:
Revision Changes Path
1.69 +37 -30 openpkg-src/gcc43/gcc43.spec
____________________________________________________________________________
patch -p0 <<'@@ .'
Index: openpkg-src/gcc43/gcc43.spec
============================================================================
$ cvs diff -u -r1.68 -r1.69 gcc43.spec
--- openpkg-src/gcc43/gcc43.spec 11 Mar 2008 20:58:54 -0000 1.68
+++ openpkg-src/gcc43/gcc43.spec 12 Mar 2008 16:45:05 -0000 1.69
@@ -23,7 +23,7 @@
# FIXME: rse: GCC since 4.3 now officially and unconditionally requires
gmp/mpfr!
# FIXME: rse: This requires blessing "gmp" and "mpfr" to CORE or include
copies into "gcc"
-# FIXME: rse: with_cxx=yes fails because of iconv problems
+# FIXME: rse: with_cxx=yes still broken because tries to partly
unconditionally include <iconv.h>
# package version
%define V_full 4.3.0
@@ -40,16 +40,16 @@
Group: Compiler
License: GPL
Version: %{V_full}
-Release: 20080311
+Release: 20080312
# package options
+%option with_binutils yes
%option with_cxx no
%option with_objc no
%option with_java no
%option with_fortran no
%option with_optimize yes
%option with_profile no
-%option with_binutils yes
%option with_threads yes
%option with_multilib no
%option with_gcc no
@@ -90,7 +90,7 @@
version = %{V_full}
url = ftp://gcc.gnu.org/pub/gcc/releases/
regex = gcc-(4\.3\.\d+)
- url = ftp://gcc.gnu.org/pub/gcc/releases/__NEWVER__/
+ url = ftp://gcc.gnu.org/pub/gcc/releases/gcc-__NEWVER__/
regex = gcc-(\d+\.\d+-\d{8})\.tar\.bz2
}
@@ -116,21 +116,19 @@
%build
# create build sub-directory
- mkdir obj
+ %{l_shtool} mkdir -p obj
cd obj
# determine ld(1) and as(1) usage
l_with_gnu_ld_as=""
-%if "%{with_binutils}" == "yes"
- l_with_gnu_ld_as="${l_with_gnu_ld_as} --with-gnu-ld
--with-ld=%{l_prefix}/bin/ld"
- l_with_gnu_ld_as="${l_with_gnu_ld_as} --with-gnu-as
--with-as=%{l_prefix}/bin/as"
-%else
- case "%{l_platform -t}" in
- *-linux* | *-freebsd* )
- l_with_gnu_ld_as="${l_with_gnu_ld_as} --with-gnu-as --with-gnu-ld"
- ;;
- esac
-%endif
+ LD=%{l_tool_locate ld ld}
+ AS=%{l_tool_locate as as}
+ echo $LD | grep '^/' >/dev/null && l_with_gnu_ld_as="${l_with_gnu_ld_as}
--with-ld=$LD"
+ echo $AS | grep '^/' >/dev/null && l_with_gnu_ld_as="${l_with_gnu_ld_as}
--with-as=$AS"
+ $LD --version </dev/null 2>/dev/null | grep "^GNU ld " >/dev/null
&& l_with_gnu_ld_as="${l_with_gnu_ld_as} --with-gnu-ld"
+ $AS --version </dev/null 2>/dev/null | grep "^GNU assembler " >/dev/null
&& l_with_gnu_ld_as="${l_with_gnu_ld_as} --with-gnu-as"
+ unset LD
+ unset AS
# determine threads usage
%if "%{with_threads}" == "yes"
@@ -139,11 +137,6 @@
l_enable_threads="single"
%endif
- # override threads setting for platforms with known limitations
- case "%{l_platform -t}" in
- *-netbsd1.6* ) l_enable_threads="single" ;;
- esac
-
# determine language usage
l_enable_languages="c"
%if "%{with_cxx}" == "yes"
@@ -206,17 +199,16 @@
l_ccisgcc=yes
fi
l_cflags=""
+ l_cxxflags=""
l_boot_cflags=""
l_libcflags="-g"
l_libcxxflags="-g"
- case "%{l_platform -t}" in
- alpha*-tru64* ) if [ ".$l_ccisgcc" = .no ]; then
l_libcflags="$l_libcflags -ieee"; fi ;;
- esac
-%if "%{with_binutils}" == "yes"
# at least GNU as from GNU binutils supports -pipe always
- l_boot_cflags="$l_boot_cflags -pipe"
- l_libcxxflags="$l_libcxxflags -pipe"
-%endif
+ AS="%{l_tool_locate as as}"
+ "$AS" --version </dev/null 2>/dev/null | grep "^GNU assembler "
>/dev/null && {
+ l_boot_cflags="$l_boot_cflags -pipe"
+ l_libcxxflags="$l_libcxxflags -pipe"
+ }
%if "%{with_optimize}" == "yes"
# conservatively optimize the generated program code
# (also _tune_ for particular CPUs, but _without_ requiring these
CPUs!)
@@ -243,12 +235,18 @@
maketarget="profiledbootstrap"
fi
%endif
+ case "%{l_platform -t}" in
+ amd64-* ) l_cflags="$l_cflags -fPIC";
l_cxxflags="$l_cxxflags -fPIC" ;;
+ ia64-* ) l_cflags="$l_cflags -fPIC";
l_cxxflags="$l_cxxflags -fPIC" ;;
+ sparc64-freebsd* ) l_cflags="$l_cflags -fPIC";
l_cxxflags="$l_cxxflags -fPIC" ;;
+ esac
# build the package
%{l_make} %{l_mflags} \
MAKE="%{l_make} %{l_mflags}" \
BOOT_CFLAGS="${l_boot_cflags}" \
CFLAGS="${l_cflags}" \
+ CXXFLAGS="${l_cxxflags}" \
LIBCFLAGS="${l_libcflags}" \
LIBCXXFLAGS="${l_libcxxflags}" \
$maketarget
@@ -266,17 +264,25 @@
# cleanup installation tree
mv $RPM_BUILD_ROOT%{l_prefix}/lib/lib*.a \
- $RPM_BUILD_ROOT%{l_prefix}/lib/gcc%{V_comp}/${triple}/[0-9]*/
+ $RPM_BUILD_ROOT%{l_prefix}/lib/gcc%{V_comp}/${triple}/[0-9]*/ \
+ >/dev/null 2>&1 || true
+ mv $RPM_BUILD_ROOT%{l_prefix}/lib64/{lib*.a,*.spec} \
+ $RPM_BUILD_ROOT%{l_prefix}/lib/gcc%{V_comp}/${triple}/[0-9]*/ \
+ >/dev/null 2>&1 || true
dirs=""
for multilib in `$RPM_BUILD_ROOT%{l_prefix}/bin/gcc --print-multi-lib`;
do
subdir=`echo "$multilib" | sed -e 's/;.*$//'`
[ ".$subdir" = .. ] && continue
mv $RPM_BUILD_ROOT%{l_prefix}/lib/$subdir/lib*.a \
-
$RPM_BUILD_ROOT%{l_prefix}/lib/gcc%{V_comp}/${triple}/[0-9]*/$subdir/
+
$RPM_BUILD_ROOT%{l_prefix}/lib/gcc%{V_comp}/${triple}/[0-9]*/$subdir/ \
+ >/dev/null 2>&1 || true
+ mv $RPM_BUILD_ROOT%{l_prefix}/lib64/$subdir/lib*.a \
+
$RPM_BUILD_ROOT%{l_prefix}/lib/gcc%{V_comp}/${triple}/[0-9]*/$subdir/ \
+ >/dev/null 2>&1 || true
dirs="$dirs $subdir"
done
for subdir in $dirs; do
- rm -rf $RPM_BUILD_ROOT%{l_prefix}/lib/$subdir
+ rm -rf $RPM_BUILD_ROOT%{l_prefix}/lib/$subdir >/dev/null 2>&1 || true
done
mv $RPM_BUILD_ROOT%{l_prefix}/${triple}/include/* \
$RPM_BUILD_ROOT%{l_prefix}/lib/gcc%{V_comp}/${triple}/[0-9]*/include/
\
@@ -288,6 +294,7 @@
rm -rf $RPM_BUILD_ROOT%{l_prefix}/man/man7 >/dev/null 2>&1 || true
rm -f $RPM_BUILD_ROOT%{l_prefix}/lib/*.la >/dev/null 2>&1 || true
rm -f $RPM_BUILD_ROOT%{l_prefix}/lib/libgomp.spec >/dev/null 2>&1 ||
true
+ rm -f $RPM_BUILD_ROOT%{l_prefix}/lib64/*.la >/dev/null 2>&1 || true
rm -f $RPM_BUILD_ROOT%{l_prefix}/bin/*-gcc* >/dev/null 2>&1 || true
%if "%{with_cxx}" == "yes"
rm -f $RPM_BUILD_ROOT%{l_prefix}/bin/*-c++ >/dev/null 2>&1 || true
@@ .
______________________________________________________________________
OpenPKG http://openpkg.org
CVS Repository Commit List [email protected]