public inbox for gentoo-commits@lists.gentoo.org
 help / color / mirror / Atom feed
* [gentoo-commits] gentoo-x86 commit in sci-libs/acml: ChangeLog acml-4.1.0-r1.ebuild
@ 2008-05-06 17:57 Sebastien Fabbro (bicatali)
  0 siblings, 0 replies; 2+ messages in thread
From: Sebastien Fabbro (bicatali) @ 2008-05-06 17:57 UTC (permalink / raw
  To: gentoo-commits

bicatali    08/05/06 17:57:50

  Modified:             ChangeLog
  Added:                acml-4.1.0-r1.ebuild
  Log:
  Various fixes for x86 (bug #220321), re-added a default environment file according to use flags, pkgconfig recreated with proper libraries instead of always acml_mv
  (Portage version: 2.1.5_rc6)

Revision  Changes    Path
1.35                 sci-libs/acml/ChangeLog

file : http://sources.gentoo.org/viewcvs.py/gentoo-x86/sci-libs/acml/ChangeLog?rev=1.35&view=markup
plain: http://sources.gentoo.org/viewcvs.py/gentoo-x86/sci-libs/acml/ChangeLog?rev=1.35&content-type=text/plain
diff : http://sources.gentoo.org/viewcvs.py/gentoo-x86/sci-libs/acml/ChangeLog?r1=1.34&r2=1.35

Index: ChangeLog
===================================================================
RCS file: /var/cvsroot/gentoo-x86/sci-libs/acml/ChangeLog,v
retrieving revision 1.34
retrieving revision 1.35
diff -u -r1.34 -r1.35
--- ChangeLog	30 Apr 2008 12:03:34 -0000	1.34
+++ ChangeLog	6 May 2008 17:57:49 -0000	1.35
@@ -1,6 +1,14 @@
 # ChangeLog for sci-libs/acml
 # Copyright 1999-2008 Gentoo Foundation; Distributed under the GPL v2
-# $Header: /var/cvsroot/gentoo-x86/sci-libs/acml/ChangeLog,v 1.34 2008/04/30 12:03:34 bicatali Exp $
+# $Header: /var/cvsroot/gentoo-x86/sci-libs/acml/ChangeLog,v 1.35 2008/05/06 17:57:49 bicatali Exp $
+
+*acml-4.1.0-r1 (06 May 2008)
+
+  06 May 2008; Sébastien Fabbro <bicatali@gentoo.org>
+  +acml-4.1.0-r1.ebuild:
+  Various fixes for x86 (bug #220321), re-added a default environment file
+  according to use flags, pkgconfig recreated with proper libraries instead
+  of always acml_mv
 
 *acml-4.1.0 (30 Apr 2008)
 



1.1                  sci-libs/acml/acml-4.1.0-r1.ebuild

file : http://sources.gentoo.org/viewcvs.py/gentoo-x86/sci-libs/acml/acml-4.1.0-r1.ebuild?rev=1.1&view=markup
plain: http://sources.gentoo.org/viewcvs.py/gentoo-x86/sci-libs/acml/acml-4.1.0-r1.ebuild?rev=1.1&content-type=text/plain

Index: acml-4.1.0-r1.ebuild
===================================================================
# Copyright 1999-2008 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
# $Header: /var/cvsroot/gentoo-x86/sci-libs/acml/acml-4.1.0-r1.ebuild,v 1.1 2008/05/06 17:57:49 bicatali Exp $

EAPI="1"

inherit eutils toolchain-funcs fortran versionator

MY_P=${PN}-$(replace_all_version_separators -)

DESCRIPTION="AMD Core Math Library for x86 and amd64 CPUs"
HOMEPAGE="http://developer.amd.com/acml.jsp"
SRC_URI="
	amd64? (
		ifc? ( ${MY_P}-ifort-64bit.tgz
			int64? ( ${MY_P}-ifort-64bit-int64.tgz ) )
		gfortran? (	 ${MY_P}-gfortran-64bit.tgz
			int64? ( ${MY_P}-gfortran-64bit-int64.tgz ) )
		!ifc? (
			!gfortran? ( ${MY_P}-gfortran-64bit.tgz
				int64? ( ${MY_P}-gfortran-64bit-int64.tgz ) ) ) )
	x86? ( ${MY_P}-ifort-32bit.tgz )"

# Once gfortran builds appear, replace x86?
# and remove the hack_x86 in the ebuild
#	x86? (
#		ifc? ( ${MY_P}-ifort-32bit.tgz )
#		gfortran? ( ${MY_P}-gfortran-32bit.tgz )
#		!ifc? ( !gfortran (	${MY_P}-gfortran-32bit.tgz ) ) )"

IUSE="doc examples gfortran ifc int64 openmp test"
KEYWORDS="~amd64 ~x86"

RESTRICT="strip fetch"
LICENSE="ACML"
SLOT="0"

#	gfortran? ( sys-devel/gcc:4.2 )
#	!gfortran? ( !ifc? ( sys-devel/gcc:4.2 ) ) )
# hack_x86
CDEPEND="ifc? ( dev-lang/ifc )
	amd64? ( gfortran? ( sys-devel/gcc:4.2 )
			!gfortran? ( !ifc? ( amd64? ( sys-devel/gcc:4.2 ) ) ) )
	x86? ( dev-lang/ifc )"

DEPEND="test? (	${CDEPEND} )
	app-admin/eselect-blas
	app-admin/eselect-lapack"

RDEPEND="${CDEPEND}
	app-admin/eselect-blas
	app-admin/eselect-lapack
	doc? ( app-doc/blas-docs app-doc/lapack-docs )"

S="${WORKDIR}"

pkg_nofetch() {
	einfo "Please download the ACML from:"
	einfo "${HOMEPAGE}"
	einfo "and place it in ${DISTDIR}."
	einfo "The previous versions could be found at"
	einfo "http://developer.amd.com/acmlarchive.jsp"
	einfo "SRC=${A} $SRC_URI"
}

pkg_setup() {
	# hack_x86
	if use x86 && ! use ifc; then
		ewarn "On x86 architectures, acml is only available with ifc."
		ewarn "Make sure you have proper licenses to use ifc"
	fi
	FORTRAN=""
	if use test; then
		use gfortran &&	FORTRAN="${FORTRAN} gfortran"
		use ifc && FORTRAN="${FORTRAN} ifc"
		use gfortran || use ifc || FORTRAN="gfortran"
		# hack_x86
		use x86 && FORTRAN="ifc"
		fortran_pkg_setup
		# work around incomplete fortran eclass
		if  use gfortran &&
			[[ ${FORTRANC} == gfortran ]] &&
			[[ $(gcc-version) != 4.2 ]]
		then
			eerror "You need gfortran-4.2 to test acml"
			eerror "Please use gcc-config to switch gcc version 4.2"
			die "gfortran check failed"
		fi
	fi
	# construct default profile dprof from default ddir
	local ddir=gfortran
	use ifc && ddir=ifort
	# hack_x86
	use x86 && ddir=ifort32 || ddir=ifort64
	#use x86 && ddir=${ddir}32 || ddir=${ddir}64
	use openmp && ddir=${ddir}_mp
	use int64 && ddir=${ddir}_int64
	ACML_DEFAULT_DIR=${ddir}
}

src_unpack() {
	unpack ${A}
	unpack ./contents-acml-*.tgz
	use openmp || rm -rf *_mp*
}

src_test() {
	# only testing with current chosen compiler
	for fdir in ${ACML_DEFAULT_DIR/_mp}*; do
		einfo "Testing acml in ${fdir}"
		for d in . acml_mv; do
			cd "${S}"/${fdir}/examples/${d}
			emake \
				ACMLDIR="${S}"/${fdir} \
				F77=${FORTRANC} \
				CC="$(tc-getCC)" \
				CPLUSPLUS="$(tc-getCXX)" \
				|| die "emake test in ${fdir}/examples/${d} failed"
			emake clean
		done
	done
}

make_acml_profile_name() {
	local fort=${1%%[[:digit:]]*}
	local opt=${1#*[0-9][0-9]}
	echo ${PN}-${fort}${opt/mp/openmp} | tr '_' '-'
}

src_install() {
	# respect acml default install dir (and FHS)
	local instdir=/opt/${PN}${PV}
	dodir ${instdir}

	for lib in */lib; do
		local fdir=${lib%/*}
		# install acml
		use examples || rm -rf "${S}"/${fdir}/examples
		cp -pPR "${S}"/${fdir} "${D}"${instdir} || die "copy ${fdir} failed"

		# install profiles
		local prof=$(make_acml_profile_name ${fdir})
		local acmldir=${instdir}/${fdir}
		local acmllibs="-lacml"
		local libname=${acmldir}/lib/libacml
		local extlibs
		local extflags
		[[ ${fdir} =~ int64 ]] && extflags="${extflags} -fdefault-integer-8"
		[[ ${fdir} =~ gfortran ]] && extlibs="${extlibs} -lgfortran"
		if [[ ${fdir} =~ _mp ]]; then
			[[ ${fdir} =~ ifort ]] && extlibs="${extlibs} -lguide"
			extlibs="${extlibs} -lpthread"
			extflags="${extflags} -fopenmp"
			acmllibs="-lacml_mp"
			libname=${libname}_mp
		fi
		use amd64 && acmllibs="${acmllibs} -lacml_mv"
		for x in blas lapack; do
			# pkgconfig files
			sed -e "s:@LIBDIR@:$(get_libdir):" \
				-e "s:@PV@:${PV}:" \
				-e "s:@ACMLDIR@:${acmldir}:g" \
				-e "s:@ACMLLIBS@:${acmllibs}:g" \
				-e "s:@EXTLIBS@:${extlibs}:g" \
				-e "s:@EXTFLAGS@:${extflags}:g" \
				"${FILESDIR}"/${x}.pc.in > ${x}.pc \
				|| die "sed ${x}.pc failed"
			insinto ${acmldir}/lib
			doins ${x}.pc || die "doins ${x}.pc failed"

			# eselect files
			cat > eselect.${prof}.${x} <<-EOF
				${libname}.so /usr/@LIBDIR@/lib${l}.so.0
				${libname}.so /usr/@LIBDIR@/lib${l}.so
				${libname}.a /usr/@LIBDIR@/lib${l}.a
				${acmldir}/lib/${x}.pc /usr/@LIBDIR@/pkgconfig/${x}.pc
			EOF
			eselect ${x} add $(get_libdir) eselect.${prof}.${x} ${prof}
		done
	done

	echo "LDPATH=${instdir}/${ACML_DEFAULT_DIR}/lib" > 35acml
	doenvd "${S}"/35acml || die "doenvd failed"
	use doc || rm -rf "${S}"/Doc/acml.pdf "${S}"/Doc/html
	cp -pPR "${S}"/Doc "${D}"${instdir} || die "copy doc failed"
}

pkg_postinst() {
	local dprof="$(make_acml_profile_name ${ACML_DEFAULT_DIR})"
	for x in blas lapack; do
		local cprof=$(eselect ${x} show | cut -d' ' -f2)
		if [[ ${cprof} == ${dprof} || -z ${cprof} ]]; then
		# work around eselect bug #189942
			local configfile="${ROOT}"/etc/env.d/${x}/$(get_libdir)/config
			[[ -e ${configfile} ]] && rm -f ${configfile}
			eselect ${x} set ${dprof}
			elog "${x} has been eselected to ${dprof}"
		else
			elog "Current eselected ${x} implementation is ${cprof}"
			elog "To use you have one of ${PN}, issue (as root):"
			elog "\t eselect ${x} set <profile>"
		fi
	done
}



-- 
gentoo-commits@lists.gentoo.org mailing list



^ permalink raw reply	[flat|nested] 2+ messages in thread
* [gentoo-commits] gentoo-x86 commit in sci-libs/acml: ChangeLog acml-4.1.0-r1.ebuild
@ 2008-06-23 14:43 Sebastien Fabbro (bicatali)
  0 siblings, 0 replies; 2+ messages in thread
From: Sebastien Fabbro (bicatali) @ 2008-06-23 14:43 UTC (permalink / raw
  To: gentoo-commits

bicatali    08/06/23 14:43:38

  Modified:             ChangeLog acml-4.1.0-r1.ebuild
  Log:
  Added gfortran fetch for x86, now available on amd website
  (Portage version: 2.1.4.4)

Revision  Changes    Path
1.37                 sci-libs/acml/ChangeLog

file : http://sources.gentoo.org/viewcvs.py/gentoo-x86/sci-libs/acml/ChangeLog?rev=1.37&view=markup
plain: http://sources.gentoo.org/viewcvs.py/gentoo-x86/sci-libs/acml/ChangeLog?rev=1.37&content-type=text/plain
diff : http://sources.gentoo.org/viewcvs.py/gentoo-x86/sci-libs/acml/ChangeLog?r1=1.36&r2=1.37

Index: ChangeLog
===================================================================
RCS file: /var/cvsroot/gentoo-x86/sci-libs/acml/ChangeLog,v
retrieving revision 1.36
retrieving revision 1.37
diff -u -r1.36 -r1.37
--- ChangeLog	27 May 2008 10:16:17 -0000	1.36
+++ ChangeLog	23 Jun 2008 14:43:38 -0000	1.37
@@ -1,6 +1,9 @@
 # ChangeLog for sci-libs/acml
 # Copyright 1999-2008 Gentoo Foundation; Distributed under the GPL v2
-# $Header: /var/cvsroot/gentoo-x86/sci-libs/acml/ChangeLog,v 1.36 2008/05/27 10:16:17 bicatali Exp $
+# $Header: /var/cvsroot/gentoo-x86/sci-libs/acml/ChangeLog,v 1.37 2008/06/23 14:43:38 bicatali Exp $
+
+  23 Jun 2008; Sébastien Fabbro <bicatali@gentoo.org> acml-4.1.0-r1.ebuild:
+  Added gfortran fetch for x86, now available on amd website
 
   27 May 2008; Sébastien Fabbro <bicatali@gentoo.org> -acml-4.1.0.ebuild,
   acml-4.1.0-r1.ebuild:



1.3                  sci-libs/acml/acml-4.1.0-r1.ebuild

file : http://sources.gentoo.org/viewcvs.py/gentoo-x86/sci-libs/acml/acml-4.1.0-r1.ebuild?rev=1.3&view=markup
plain: http://sources.gentoo.org/viewcvs.py/gentoo-x86/sci-libs/acml/acml-4.1.0-r1.ebuild?rev=1.3&content-type=text/plain
diff : http://sources.gentoo.org/viewcvs.py/gentoo-x86/sci-libs/acml/acml-4.1.0-r1.ebuild?r1=1.2&r2=1.3

Index: acml-4.1.0-r1.ebuild
===================================================================
RCS file: /var/cvsroot/gentoo-x86/sci-libs/acml/acml-4.1.0-r1.ebuild,v
retrieving revision 1.2
retrieving revision 1.3
diff -u -r1.2 -r1.3
--- acml-4.1.0-r1.ebuild	27 May 2008 10:16:17 -0000	1.2
+++ acml-4.1.0-r1.ebuild	23 Jun 2008 14:43:38 -0000	1.3
@@ -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-libs/acml/acml-4.1.0-r1.ebuild,v 1.2 2008/05/27 10:16:17 bicatali Exp $
+# $Header: /var/cvsroot/gentoo-x86/sci-libs/acml/acml-4.1.0-r1.ebuild,v 1.3 2008/06/23 14:43:38 bicatali Exp $
 
 EAPI="1"
 
@@ -19,14 +19,10 @@
 		!ifc? (
 			!gfortran? ( ${MY_P}-gfortran-64bit.tgz
 				int64? ( ${MY_P}-gfortran-64bit-int64.tgz ) ) ) )
-	x86? ( ${MY_P}-ifort-32bit.tgz )"
-
-# Once gfortran builds appear, replace x86?
-# and remove the hack_x86 in the ebuild
-#	x86? (
-#		ifc? ( ${MY_P}-ifort-32bit.tgz )
-#		gfortran? ( ${MY_P}-gfortran-32bit.tgz )
-#		!ifc? ( !gfortran (	${MY_P}-gfortran-32bit.tgz ) ) )"
+	x86? (
+		ifc? ( ${MY_P}-ifort-32bit.tgz )
+		gfortran? ( ${MY_P}-gfortran-32bit.tgz )
+		!ifc? ( !gfortran? ( ${MY_P}-gfortran-32bit.tgz ) ) )"
 
 IUSE="doc examples gfortran ifc int64 openmp test"
 KEYWORDS="~amd64 ~x86"
@@ -35,13 +31,9 @@
 LICENSE="ACML"
 SLOT="0"
 
-#	gfortran? ( sys-devel/gcc:4.2 )
-#	!gfortran? ( !ifc? ( sys-devel/gcc:4.2 ) ) )
-# hack_x86
 CDEPEND="ifc? ( dev-lang/ifc )
-	amd64? ( gfortran? ( sys-devel/gcc:4.2 )
-			!gfortran? ( !ifc? ( amd64? ( sys-devel/gcc:4.2 ) ) ) )
-	x86? ( dev-lang/ifc )"
+	gfortran? ( sys-devel/gcc:4.2 )
+	!gfortran? ( !ifc? ( sys-devel/gcc:4.2 ) )"
 
 DEPEND="test? (	${CDEPEND} )
 	app-admin/eselect-blas
@@ -64,18 +56,11 @@
 }
 
 pkg_setup() {
-	# hack_x86
-	if use x86 && ! use ifc; then
-		ewarn "On x86 architectures, acml is only available with ifc."
-		ewarn "Make sure you have proper licenses to use ifc"
-	fi
 	FORTRAN=""
 	if use test; then
 		use gfortran &&	FORTRAN="${FORTRAN} gfortran"
 		use ifc && FORTRAN="${FORTRAN} ifc"
 		use gfortran || use ifc || FORTRAN="gfortran"
-		# hack_x86
-		use x86 && FORTRAN="ifc"
 		fortran_pkg_setup
 		# work around incomplete fortran eclass
 		if  use gfortran &&
@@ -90,9 +75,7 @@
 	# construct default profile dprof from default ddir
 	local ddir=gfortran
 	use ifc && ddir=ifort
-	# hack_x86
-	use x86 && ddir=ifort32 || ddir=ifort64
-	#use x86 && ddir=${ddir}32 || ddir=${ddir}64
+	use x86 && ddir=${ddir}32 || ddir=${ddir}64
 	use openmp && ddir=${ddir}_mp
 	use int64 && ddir=${ddir}_int64
 	ACML_DEFAULT_DIR=${ddir}



-- 
gentoo-commits@lists.gentoo.org mailing list



^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2008-06-23 14:43 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2008-05-06 17:57 [gentoo-commits] gentoo-x86 commit in sci-libs/acml: ChangeLog acml-4.1.0-r1.ebuild Sebastien Fabbro (bicatali)
  -- strict thread matches above, loose matches on Subject: below --
2008-06-23 14:43 Sebastien Fabbro (bicatali)

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox