summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorSebastien Fabbro <bicatali@gentoo.org>2008-03-16 13:34:27 +0000
committerSebastien Fabbro <bicatali@gentoo.org>2008-03-16 13:34:27 +0000
commitfcfd0434276a5b6009457aa36a96f759edcdfc8a (patch)
tree31bf851e223c8bfe47be64e17e7672f09a33008c
parentAdd case for shell scripts for file output #213565 by Matthias B. (diff)
downloadgentoo-2-fcfd0434276a5b6009457aa36a96f759edcdfc8a.tar.gz
gentoo-2-fcfd0434276a5b6009457aa36a96f759edcdfc8a.tar.bz2
gentoo-2-fcfd0434276a5b6009457aa36a96f759edcdfc8a.zip
Fixes for g77 to work, bug #213358
(Portage version: 2.1.4.4)
-rw-r--r--sci-physics/cernlib/ChangeLog6
-rw-r--r--sci-physics/cernlib/cernlib-2006-r1.ebuild12
-rw-r--r--sci-physics/cernlib/files/cernlib-2006-nogfortran.patch56
3 files changed, 65 insertions, 9 deletions
diff --git a/sci-physics/cernlib/ChangeLog b/sci-physics/cernlib/ChangeLog
index 92db5bca5907..5c948d0636bb 100644
--- a/sci-physics/cernlib/ChangeLog
+++ b/sci-physics/cernlib/ChangeLog
@@ -1,6 +1,10 @@
# ChangeLog for sci-physics/cernlib
# Copyright 1999-2008 Gentoo Foundation; Distributed under the GPL v2
-# $Header: /var/cvsroot/gentoo-x86/sci-physics/cernlib/ChangeLog,v 1.7 2008/03/11 12:09:06 bicatali Exp $
+# $Header: /var/cvsroot/gentoo-x86/sci-physics/cernlib/ChangeLog,v 1.8 2008/03/16 13:34:27 bicatali Exp $
+
+ 16 Mar 2008; Sébastien Fabbro <bicatali@gentoo.org>
+ +files/cernlib-2006-nogfortran.patch, cernlib-2006-r1.ebuild:
+ Fixes for g77 to work, bug #213358
*cernlib-2006-r1 (11 Mar 2008)
diff --git a/sci-physics/cernlib/cernlib-2006-r1.ebuild b/sci-physics/cernlib/cernlib-2006-r1.ebuild
index 346203b40f85..f456e903eaaa 100644
--- a/sci-physics/cernlib/cernlib-2006-r1.ebuild
+++ b/sci-physics/cernlib/cernlib-2006-r1.ebuild
@@ -1,6 +1,6 @@
# Copyright 1999-2008 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
-# $Header: /var/cvsroot/gentoo-x86/sci-physics/cernlib/cernlib-2006-r1.ebuild,v 1.1 2008/03/11 12:09:06 bicatali Exp $
+# $Header: /var/cvsroot/gentoo-x86/sci-physics/cernlib/cernlib-2006-r1.ebuild,v 1.2 2008/03/16 13:34:27 bicatali Exp $
inherit eutils multilib fortran
@@ -42,6 +42,7 @@ src_unpack() {
unpack ${A}
epatch "${DEB_P}-${DEB_PR}".diff
cd "${S}"
+ epatch "${FILESDIR}"/${P}-nogfortran.patch
# set some default paths
sed -i \
@@ -56,7 +57,7 @@ src_unpack() {
-e "s:\$DEPS -lm:$(pkg-config --libs blas):" \
-e "s:\$DEPS -llapack -lm:$(pkg-config --libs lapack):" \
-e 's:`depend $d $a blas`::' \
- -e "s:X11R6:X11:g" \
+ -e 's:X11R6:X11:g' \
debian/add-ons/bin/cernlib.in || die "sed failed"
cp debian/add-ons/Makefile .
@@ -66,12 +67,7 @@ src_unpack() {
emake -j1 patch || die "debian patch failed"
# since we depend on cfortran, do not use the one from cernlib
- rm -f src/include/cfortran/cfortran.h \
-
- # fix an ifort problem
- sed -i \
- -e 's/= $(CLIBS) -nofor_main/:= $(CLIBS) -nofor_main/' \
- src/packlib/kuip/programs/kxterm/Imakefile || die "sed ifc failed"
+ rm -f src/include/cfortran/cfortran.h
# respect users flags
sed -i \
diff --git a/sci-physics/cernlib/files/cernlib-2006-nogfortran.patch b/sci-physics/cernlib/files/cernlib-2006-nogfortran.patch
new file mode 100644
index 000000000000..63883274403f
--- /dev/null
+++ b/sci-physics/cernlib/files/cernlib-2006-nogfortran.patch
@@ -0,0 +1,56 @@
+--- debian/add-ons/Makefile.orig 2008-03-15 16:46:46.000000000 +0000
++++ debian/add-ons/Makefile 2008-03-15 16:47:51.000000000 +0000
+@@ -28,6 +28,9 @@
+ ifneq (,$(findstring ifort,$(DEB_BUILD_OPTIONS)))
+ sed -i -e 's/-lgfortran/-limf/' $(CERN_BINDIR)/cernlib
+ endif
++ifneq (,$(findstring g77,$(DEB_BUILD_OPTIONS)))
++ sed -i -e 's/-lgfortran/-lg2c/' $(CERN_BINDIR)/cernlib
++endif
+ chmod a+x $(CERN_BINDIR)/cernlib
+
+ # target to install include files for development packages
+--- debian/add-ons/cernlib.mk.orig 2008-03-15 16:48:05.000000000 +0000
++++ debian/add-ons/cernlib.mk 2008-03-15 17:09:14.000000000 +0000
+@@ -35,6 +35,10 @@
+ export TOOL_SONAME = _gfortran
+ export TOOL_NAME = _gfortran
+ endif
++ifeq (,$(findstring g77,$(DEB_BUILD_OPTIONS)))
++ export TOOL_SONAME = _gfortran
++ export TOOL_NAME = _gfortran
++endif
+ export PATH := $(CERN_BINDIR):$(ADDONDIR)/bin:$(datadir)/cernlib:${PATH}
+ export INSTALL_OPTS ?= -s
+ export CC ?= gcc
+@@ -118,6 +122,8 @@
+ endif
+ ifneq (,$(findstring ifort,$(DEB_BUILD_OPTIONS)))
+ echo '#define HasIntelifc YES' >> $(CVSCOSRC)/config/host.def
++else ifneq (,$(findstring g77,$(DEB_BUILD_OPTIONS)))
++ echo >> $(CVSCOSRC)/config/host.def
+ else
+ echo '#define Hasgfortran YES' >> $(CVSCOSRC)/config/host.def
+ endif
+--- debian/patches/320-support-ifort.dpatch.orig 2008-03-15 17:31:34.000000000 +0000
++++ debian/patches/320-support-ifort.dpatch 2008-03-15 17:31:56.000000000 +0000
+@@ -27,7 +27,7 @@
+ #if defined(CERNLIB_UNIX)
+ CLIBS= -G Motif kernlib
+ +# if defined(CERNLIB_INTELIFC)
+-+CLIBS= $(CLIBS) -nofor_main
+++CLIBS:= $(CLIBS) -nofor_main
+ +# endif
+ #endif
+
+--- debian/patches/803-link-binaries-dynamically.dpatch.orig 2008-03-15 17:48:38.000000000 +0000
++++ debian/patches/803-link-binaries-dynamically.dpatch 2008-03-15 17:49:17.000000000 +0000
+@@ -64,7 +64,7 @@
+ -CLIBS= -G Motif kernlib
+ +CLIBS= -G Motif -u Xm
+ # if defined(CERNLIB_INTELIFC)
+- CLIBS= $(CLIBS) -nofor_main
++ CLIBS:= $(CLIBS) -nofor_main
+ # endif
+ #endif
+