[pcc/el6/master] Update to 2010119. x86_64 seems to be working now more or less.
Jussi Lehtola
jussilehtola at fedoraproject.org
Fri Nov 19 15:30:46 UTC 2010
commit b5bddbd060a8a7e9ba9e84ba3a593f53bb3ef57c
Author: Jussi Lehtola <jussilehtola at fedoraproject.org>
Date: Fri Nov 19 17:30:32 2010 +0200
Update to 2010119. x86_64 seems to be working now more or less.
pcc.spec | 60 +++++++++++++++++++++++++++++++++++++++++++++++++++---------
sources | 4 ++--
2 files changed, 53 insertions(+), 11 deletions(-)
---
diff --git a/pcc.spec b/pcc.spec
index df719a7..2c1d96d 100644
--- a/pcc.spec
+++ b/pcc.spec
@@ -1,16 +1,33 @@
-# Use our own configure in order to prevent --target
+# Use our own configure in order to prevent --target, which makes autotools believe we are cross compiling
%global pccconfigure \
- export CFLAGS="%{optflags}"; \
- export CXXFLAGS="%{optflags}"; \
- export FFLAGS="%{optflags} -I%{_fmoddir}"; \
+ export CFLAGS="${FLAGS}"; \
+ export CXXFLAGS="${FLAGS}"; \
+ export FFLAGS="${FLAGS} -I%{_fmoddir}"; \
./configure --program-prefix= --prefix=%{_prefix} --exec-prefix=%{_prefix} --bindir=%{_bindir} --sbindir=%{_sbindir} --sysconfdir=%{_sysconfdir} --datadir=%{_datadir} --includedir=%{_includedir} --libdir=%{_libdir} --libexecdir=%{_libexecdir} --localstatedir=%{_localstatedir} --sharedstatedir=%{_sharedstatedir} --mandir=%{_mandir} --infodir=%{_infodir}
# Used CVS snapshot
-%global snapshot 100413
+%global snapshot 101119
+
+# Use pcc to build? (This option is for sanity testing the compiler)
+%global usepcc 0
+
+# RPM does not play well with pcc compiled package
+%if %{usepcc}
+%define debug_package %{nil}
+%endif
+
+# Release tag
+%define rel 0.4.%{snapshot}cvs
Name: pcc
Version: 0.9.9
-Release: 0.4.%{snapshot}cvs%{?dist}
+
+%if %{usepcc}
+Release: %{rel}_pcc%{?dist}
+%else
+Release: %{rel}%{?dist}
+%endif
+
Summary: The Portable C Compiler
Group: Development/Languages
License: BSD with advertising and BSD and ISC
@@ -26,6 +43,11 @@ ExclusiveArch: %{ix86} x86_64
BuildRequires: bison flex
Requires: glibc-devel
+%if %{usepcc}
+BuildRequires: pcc
+%endif
+
+
%description
The compiler is based on the original Portable C Compiler by Stephen C.
Johnson, written in the late 70's. Even though much of the compiler has been
@@ -41,6 +63,8 @@ analysis part and the SSA conversion code which is written by Peter A Jonsson,
and the Mips port that were written as part of a project by undergraduate
students at Luleå University of Technology (LTU).
+Caution: the compiler is still undergoing heavy development.
+
%prep
%setup -q -n pcc-%{snapshot} -a1
# Get rid of the default optimization flag
@@ -52,7 +76,6 @@ mv pcc-libs-%{snapshot} pcc-libs
%build
-export CFLAGS_NODEBUG=`echo %{optflags}|sed "s|-g||g"`
# Set architecture directory needed for include flag
%ifarch x86_64
export archdir=amd64
@@ -61,10 +84,24 @@ export archdir=amd64
export archdir=i386
%endif
+# Use pcc to build?
+%if %{usepcc}
+export FLAGS="-g"
+export CC="pcc"
+export CPP="pcc -E"
+%else
+export FLAGS="%{optflags}"
+export CC="gcc"
+export CPP="gcc -E"
+%endif
+
+# Flags for files that can't be built as debug
+export CFLAGS_NODEBUG=`echo ${FLAGS}|sed "s|-g||g"`
+
# First, build the library.
cd pcc-libs
%pccconfigure
-make CFLAGS="-I${archdir} -Ilinux -I. %{optflags}" CFLAGS_NODEBUG="-I${archdir} -Ilinux -I. $CFLAGS_NODEBUG"
+make CFLAGS="-I${archdir} -Ilinux -I. ${FLAGS}" CFLAGS_NODEBUG="-I${archdir} -Ilinux -I. $CFLAGS_NODEBUG"
#%{?_smp_mflags}
cd ..
# Then, build the compiler
@@ -104,6 +141,10 @@ rm -rf %{buildroot}
%{_mandir}/man1/pcc.1.*
%changelog
+* Fri Nov 19 2010 Jussi Lehtola <jussilehtola at fedoraproject.org> - 0.9.9-0.4.101119cvs
+- Update to 20101119. x86_64 works now.
+- Added possibility in the spec file to build pcc with itself.
+
* Wed Apr 14 2010 Jussi Lehtola <jussilehtola at fedoraproject.org> - 0.9.9-0.4.100413cvs
- Update to 20100413.
@@ -120,7 +161,8 @@ rm -rf %{buildroot}
- Update to 20090811.
* Sun Aug 09 2009 Jussi Lehtola <jussilehtola at fedoraproject.org> - 0.9.9-0.2.090809cvs
-- Changed --with-libdir to %%{_libdir} to make pcc use the glibc version of crt0.o by suggestion of upstream.
+- Changed --with-libdir to %%{_libdir} to make pcc use the glibc version of
+ crt0.o by suggestion of upstream.
- Update to 20090809.
* Sat Aug 08 2009 Jussi Lehtola <jussilehtola at fedoraproject.org> - 0.9.9-0.1.090808cvs
diff --git a/sources b/sources
index df37ff5..a08c0e7 100644
--- a/sources
+++ b/sources
@@ -1,2 +1,2 @@
-425f66e03462ab6e7516a538d698c952 pcc-100413.tgz
-51f56ffdb2fada1d6bf48bcef60d33b8 pcc-libs-100413.tgz
+451935476e28d141e4c553d67dd6315b pcc-101119.tgz
+36b247ad342907f0196cc5e9704cb8e9 pcc-libs-101119.tgz
More information about the scm-commits
mailing list