public inbox for gentoo-commits@lists.gentoo.org
 help / color / mirror / Atom feed
* [gentoo-commits] proj/sci:master commit in: sci-physics/cernlib/
@ 2024-04-09 13:06 Alexander Puck Neuwirth
  0 siblings, 0 replies; 4+ messages in thread
From: Alexander Puck Neuwirth @ 2024-04-09 13:06 UTC (permalink / raw
  To: gentoo-commits

commit:     d92a65a7066fd6bc6467e88a26c33e9e5a152a8e
Author:     Alexander Puck Neuwirth <alexander <AT> neuwirth-informatik <DOT> de>
AuthorDate: Mon Apr  8 11:32:34 2024 +0000
Commit:     Alexander Puck Neuwirth <alexander <AT> neuwirth-informatik <DOT> de>
CommitDate: Tue Apr  9 13:05:35 2024 +0000
URL:        https://gitweb.gentoo.org/proj/sci.git/commit/?id=d92a65a7

sci-physics/cernlib: split free and non-free

Closes: https://github.com/gentoo/sci/pull/1265
Co-authored-by: Andrew Nowa Ammerlaan <andrewammerlaan <AT> gentoo.org>
Signed-off-by: Alexander Puck Neuwirth <alexander <AT> neuwirth-informatik.de>

 ....31.0.ebuild => cernlib-2023.10.31.0-r1.ebuild} | 28 +++++++++++++++++-----
 sci-physics/cernlib/metadata.xml                   |  3 +++
 2 files changed, 25 insertions(+), 6 deletions(-)

diff --git a/sci-physics/cernlib/cernlib-2023.10.31.0.ebuild b/sci-physics/cernlib/cernlib-2023.10.31.0-r1.ebuild
similarity index 70%
rename from sci-physics/cernlib/cernlib-2023.10.31.0.ebuild
rename to sci-physics/cernlib/cernlib-2023.10.31.0-r1.ebuild
index 697a25ef0..326fadde3 100644
--- a/sci-physics/cernlib/cernlib-2023.10.31.0.ebuild
+++ b/sci-physics/cernlib/cernlib-2023.10.31.0-r1.ebuild
@@ -3,14 +3,22 @@ EAPI=8
 CMAKE_MAKEFILE_GENERATOR="emake"
 inherit cmake fortran-2
 
+MY_P="${P}"
 DESCRIPTION="CERN program library for High Energy Physics"
 HOMEPAGE="https://cernlib.web.cern.ch/cernlib/"
-SRC_URI="https://cernlib.web.cern.ch/download/2023_source/tar/${P}-free.tar.gz"
-S="${WORKDIR}/${P}-free"
+SRC_URI="
+	free? ( https://cernlib.web.cern.ch/download/2023_source/tar/${P}-free.tar.gz )
+	!free? ( https://cernlib.web.cern.ch/download/2023_source/tar/${P}.tar.gz )
+"
 
-LICENSE="GPL-3"
+LICENSE="
+	free? ( BSD LGPL-2+ GPL-1+ )
+	!free? ( all-rights-reserved )
+"
 SLOT="0"
 KEYWORDS="~amd64"
+IUSE="+free"
+RESTRICT="mirror"
 
 RDEPEND="
 	x11-libs/motif:0
@@ -28,10 +36,18 @@ BDEPEND="
 "
 
 PATCHES=(
-	"${FILESDIR}"/$P-cfortran.patch
-	"${FILESDIR}"/$P-ctest.patch
-	"${FILESDIR}"/$P-man.patch
+	"${FILESDIR}"/${P}-cfortran.patch
+	"${FILESDIR}"/${P}-ctest.patch
+	"${FILESDIR}"/${P}-man.patch
 )
+
+src_unpack() {
+	default
+	if use free; then
+		mv ${P}-free ${P} || die
+	fi
+}
+
 src_prepare() {
 	cmake_src_prepare
 	# cfortran.patch

diff --git a/sci-physics/cernlib/metadata.xml b/sci-physics/cernlib/metadata.xml
index 887c950bc..dcbfb9b47 100644
--- a/sci-physics/cernlib/metadata.xml
+++ b/sci-physics/cernlib/metadata.xml
@@ -18,4 +18,7 @@
   mathematics, data analysis, detectors simulation, data-handling
   etc... applicable to a wide range of problems.
   </longdescription>
+  <use>
+    <flag name="free"> Use free sources </flag>
+  </use>
 </pkgmetadata>


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

* [gentoo-commits] proj/sci:master commit in: sci-physics/cernlib/
@ 2024-04-23 14:17 Alexander Puck Neuwirth
  0 siblings, 0 replies; 4+ messages in thread
From: Alexander Puck Neuwirth @ 2024-04-23 14:17 UTC (permalink / raw
  To: gentoo-commits

commit:     76470804a085b752ebcae40c612f16fc32699379
Author:     Alexander Puck Neuwirth <alexander <AT> neuwirth-informatik <DOT> de>
AuthorDate: Tue Apr 23 13:15:14 2024 +0000
Commit:     Alexander Puck Neuwirth <alexander <AT> neuwirth-informatik <DOT> de>
CommitDate: Tue Apr 23 13:15:14 2024 +0000
URL:        https://gitweb.gentoo.org/proj/sci.git/commit/?id=76470804

sci-physics/cernlib: Drop var MY_P

Signed-off-by: Alexander Puck Neuwirth <alexander <AT> neuwirth-informatik.de>

 sci-physics/cernlib/cernlib-2023.10.31.0-r1.ebuild | 1 -
 1 file changed, 1 deletion(-)

diff --git a/sci-physics/cernlib/cernlib-2023.10.31.0-r1.ebuild b/sci-physics/cernlib/cernlib-2023.10.31.0-r1.ebuild
index 326fadde3..c5c919678 100644
--- a/sci-physics/cernlib/cernlib-2023.10.31.0-r1.ebuild
+++ b/sci-physics/cernlib/cernlib-2023.10.31.0-r1.ebuild
@@ -3,7 +3,6 @@ EAPI=8
 CMAKE_MAKEFILE_GENERATOR="emake"
 inherit cmake fortran-2
 
-MY_P="${P}"
 DESCRIPTION="CERN program library for High Energy Physics"
 HOMEPAGE="https://cernlib.web.cern.ch/cernlib/"
 SRC_URI="


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

* [gentoo-commits] proj/sci:master commit in: sci-physics/cernlib/
@ 2024-04-24 14:13 Alexander Puck Neuwirth
  0 siblings, 0 replies; 4+ messages in thread
From: Alexander Puck Neuwirth @ 2024-04-24 14:13 UTC (permalink / raw
  To: gentoo-commits

commit:     55da92a78fb0bf296acf20a2b09ae8290c53426d
Author:     Alexander Puck Neuwirth <alexander <AT> neuwirth-informatik <DOT> de>
AuthorDate: Tue Apr 23 14:50:25 2024 +0000
Commit:     Alexander Puck Neuwirth <alexander <AT> neuwirth-informatik <DOT> de>
CommitDate: Wed Apr 24 14:12:19 2024 +0000
URL:        https://gitweb.gentoo.org/proj/sci.git/commit/?id=55da92a7

sci-physics/cernlib: Fix test failures

Closes: https://github.com/gentoo/sci/pull/1268
Signed-off-by: Alexander Puck Neuwirth <alexander <AT> neuwirth-informatik.de>

 ...-2023.10.31.0-r1.ebuild => cernlib-2023.10.31.0-r2.ebuild} | 11 +++++++++--
 1 file changed, 9 insertions(+), 2 deletions(-)

diff --git a/sci-physics/cernlib/cernlib-2023.10.31.0-r1.ebuild b/sci-physics/cernlib/cernlib-2023.10.31.0-r2.ebuild
similarity index 82%
rename from sci-physics/cernlib/cernlib-2023.10.31.0-r1.ebuild
rename to sci-physics/cernlib/cernlib-2023.10.31.0-r2.ebuild
index c5c919678..93220dffb 100644
--- a/sci-physics/cernlib/cernlib-2023.10.31.0-r1.ebuild
+++ b/sci-physics/cernlib/cernlib-2023.10.31.0-r2.ebuild
@@ -1,7 +1,7 @@
 EAPI=8
 
 CMAKE_MAKEFILE_GENERATOR="emake"
-inherit cmake fortran-2
+inherit cmake fortran-2 flag-o-matic
 
 DESCRIPTION="CERN program library for High Energy Physics"
 HOMEPAGE="https://cernlib.web.cern.ch/cernlib/"
@@ -16,7 +16,8 @@ LICENSE="
 "
 SLOT="0"
 KEYWORDS="~amd64"
-IUSE="+free"
+# static-libs as default since otherwise test fail...
+IUSE="+free +static-libs"
 RESTRICT="mirror"
 
 RDEPEND="
@@ -59,6 +60,12 @@ src_configure() {
 	# docs follow rpm like spliting into packages cernlib, cernlib-devel, etc.
 	# we move them into a folder that agrees with gentoo doc structure.
 	sed -i "s#/doc/#/doc/${PF}/#g" CMakeLists.txt || die
+	# with -O2 some tests fail
+	# let upstream decide on optimization (-O0) since code is fragile
+	filter-flags -O1 -O2 -O3 -Os -Oz -Og -Ofast
+	local mycmakeargs=(
+		-DBUILD_SHARED_LIBS=$(usex static-libs OFF ON)
+	)
 	cmake_src_configure
 }
 


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

* [gentoo-commits] proj/sci:master commit in: sci-physics/cernlib/
@ 2024-10-22 22:04 Alexander Puck Neuwirth
  0 siblings, 0 replies; 4+ messages in thread
From: Alexander Puck Neuwirth @ 2024-10-22 22:04 UTC (permalink / raw
  To: gentoo-commits

commit:     dd532d98a9305b7920ed08db6670c8e28ab16bd5
Author:     Alexander Puck Neuwirth <alexander <AT> neuwirth-informatik <DOT> de>
AuthorDate: Tue Oct 22 22:04:34 2024 +0000
Commit:     Alexander Puck Neuwirth <alexander <AT> neuwirth-informatik <DOT> de>
CommitDate: Tue Oct 22 22:04:34 2024 +0000
URL:        https://gitweb.gentoo.org/proj/sci.git/commit/?id=dd532d98

sci-physics/cernlib: add 2024.06.12.0

Signed-off-by: Alexander Puck Neuwirth <alexander <AT> neuwirth-informatik.de>

 sci-physics/cernlib/cernlib-2024.06.12.0.ebuild | 79 +++++++++++++++++++++++++
 1 file changed, 79 insertions(+)

diff --git a/sci-physics/cernlib/cernlib-2024.06.12.0.ebuild b/sci-physics/cernlib/cernlib-2024.06.12.0.ebuild
new file mode 100644
index 000000000..299399738
--- /dev/null
+++ b/sci-physics/cernlib/cernlib-2024.06.12.0.ebuild
@@ -0,0 +1,79 @@
+EAPI=8
+
+CMAKE_MAKEFILE_GENERATOR="emake"
+inherit cmake fortran-2 flag-o-matic
+
+DESCRIPTION="CERN program library for High Energy Physics"
+HOMEPAGE="https://cernlib.web.cern.ch/cernlib/"
+SRC_URI="
+	free? ( https://cernlib.web.cern.ch/download/$(ver_cut 1)_source/tar/${PN}-${P}-free.tar.gz )
+	!free? ( https://cernlib.web.cern.ch/download/$(ver_cut 1)_source/tar/${PN}-${P}.tar.gz )
+"
+S="${WORKDIR}/${PN}-${P}"
+LICENSE="
+	free? ( BSD LGPL-2+ GPL-1+ )
+	!free? ( all-rights-reserved )
+"
+SLOT="0"
+KEYWORDS="~amd64"
+# static-libs as default since otherwise test fail...
+IUSE="+free +static-libs"
+RESTRICT="mirror"
+
+RDEPEND="
+	x11-libs/motif:0
+	x11-libs/libXaw
+	x11-libs/libXau
+	virtual/lapack
+	dev-lang/cfortran
+	x11-libs/xbae
+	net-libs/libnsl
+	virtual/libcrypt:=
+"
+DEPEND="${RDEPEND}"
+BDEPEND="
+	virtual/pkgconfig
+"
+
+PATCHES=(
+	"${FILESDIR}"/${PN}-2023.10.31.0-cfortran.patch
+	"${FILESDIR}"/${PN}-2023.10.31.0-man.patch
+)
+
+src_unpack() {
+	default
+	if use free; then
+		mv ${PN}-${P}-free ${PN}-${P} || die
+	fi
+}
+
+src_prepare() {
+	cmake_src_prepare
+	# cfortran.patch
+	# Remove cfortran.h since it is already installed from dev-lang/cfortran
+	# thereby we avoid collisions if e.g. sci-physics/root[fortran] is installed.
+	rm cfortran/cfortran.h || die
+}
+
+src_configure() {
+	# docs follow rpm like spliting into packages cernlib, cernlib-devel, etc.
+	# we move them into a folder that agrees with gentoo doc structure.
+	sed -i "s#/doc/#/doc/${PF}/#g" CMakeLists.txt || die
+	# let upstream decide on optimization (-O0) since code is fragile
+	#filter-flags -O1 -O2 -O3 -Os -Oz -Og -Ofast
+	# with -O2 some tests fail
+	append-flags -O0
+	local mycmakeargs=(
+		-DBUILD_SHARED_LIBS=$(usex static-libs OFF ON)
+	)
+	cmake_src_configure
+}
+
+src_install() {
+	cmake_src_install
+	# man.patch
+	# The CMakeLists.txt already compresses the manual before install
+	# therefore we install it manually and avoid QA problems.
+	doman contrib/man/man1/*.1
+	doman contrib/man/man8/*.8
+}


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

end of thread, other threads:[~2024-10-22 22:04 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2024-04-24 14:13 [gentoo-commits] proj/sci:master commit in: sci-physics/cernlib/ Alexander Puck Neuwirth
  -- strict thread matches above, loose matches on Subject: below --
2024-10-22 22:04 Alexander Puck Neuwirth
2024-04-23 14:17 Alexander Puck Neuwirth
2024-04-09 13:06 Alexander Puck Neuwirth

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