SPECS: kernel-vanilla.spec - gcc4 bcond

glen glen at pld-linux.org
Thu Feb 7 13:39:58 CET 2008


Author: glen                         Date: Thu Feb  7 12:39:58 2008 GMT
Module: SPECS                         Tag: HEAD
---- Log message:
- gcc4 bcond

---- Files affected:
SPECS:
   kernel-vanilla.spec (1.106 -> 1.107) 

---- Diffs:

================================================================
Index: SPECS/kernel-vanilla.spec
diff -u SPECS/kernel-vanilla.spec:1.106 SPECS/kernel-vanilla.spec:1.107
--- SPECS/kernel-vanilla.spec:1.106	Wed Feb  6 01:58:50 2008
+++ SPECS/kernel-vanilla.spec	Thu Feb  7 13:39:53 2008
@@ -6,6 +6,7 @@
 %bcond_with	verbose		# verbose build (V=1)
 %bcond_with	pae		# build PAE (HIGHMEM64G) support on uniprocessor
 %bcond_with	preempt-nort	# build preemptable no realtime kernel
+%bcond_with	gcc4		# use gcc4 package for compiling
 
 %{?debug:%define with_verbose 1}
 
@@ -78,7 +79,11 @@
 %ifarch sparc sparc64
 BuildRequires:	elftoaout
 %endif
+%if %{with gcc4}
+BuildRequires:	gcc >= 5:4.1
+%else
 BuildRequires:	gcc >= 5:3.2
+%endif
 BuildRequires:	module-init-tools
 # for hostname command
 BuildRequires:	net-tools
@@ -106,6 +111,13 @@
 ExclusiveOS:	Linux
 BuildRoot:	%{tmpdir}/%{name}-%{version}-root-%(id -u -n)
 
+%if %{with gcc4}
+# add suffix, but allow ccache, etc in ~/.rpmmacros
+%{expand:%%define	__cc	%(echo '%__cc' | sed -e 's,-gcc,-gcc4,')}
+%{expand:%%define	__cxx	%(echo '%__cxx' | sed -e 's,-g++,-g++4,')}
+%{expand:%%define	__cpp	%(echo '%__cpp' | sed -e 's,-gcc,-gcc4,')}
+%endif
+
 %ifarch %{ix86} %{x8664}
 %define		target_arch_dir	x86
 %else
@@ -779,6 +791,9 @@
 All persons listed below can be reached at <cvs_login>@pld-linux.org
 
 $Log$
+Revision 1.107  2008-02-07 12:39:53  glen
+- gcc4 bcond
+
 Revision 1.106  2008-02-06 00:58:50  glen
 - sparc files fix
 
================================================================

---- CVS-web:
    http://cvs.pld-linux.org/cgi-bin/cvsweb.cgi/SPECS/kernel-vanilla.spec?r1=1.106&r2=1.107&f=u



More information about the pld-cvs-commit mailing list