Bug 278073 - science/libaec: Update to 1.1.3
Summary: science/libaec: Update to 1.1.3
Status: Closed FIXED
Alias: None
Product: Ports & Packages
Classification: Unclassified
Component: Individual Port(s) (show other bugs)
Version: Latest
Hardware: Any Any
: --- Affects Only Me
Assignee: Po-Chuan Hsieh
URL: https://github.com/MathisRosenhauer/l...
Keywords:
Depends on:
Blocks:
 
Reported: 2024-03-31 16:53 UTC by Daniel Engberg
Modified: 2024-04-06 00:08 UTC (History)
1 user (show)

See Also:
bugzilla: maintainer-feedback? (sunpoet)


Attachments
Patch for libaec (1.68 KB, patch)
2024-03-31 16:53 UTC, Daniel Engberg
no flags Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Daniel Engberg freebsd_committer freebsd_triage 2024-03-31 16:53:21 UTC
Created attachment 249597 [details]
Patch for libaec

* Only build test suite on request

Compile and runtime tested on FreeBSD 14.0-RELEASE (amd64) (make, make check-plist, make test)
Poudriere testport OK 14.0-RELEASE (amd64)
Poudriere testport OK 13.2-RELEASE (amd64)

Tested with following consumers in 13.2-RELEASE (amd64) using Poudriere:
astro/oskar
biology/kallisto
cad/gmsh
cad/py-gmsh
graphics/alembic
graphics/gdal
graphics/qgis
graphics/qgis-ltr
graphics/vigra
graphics/vv
math/ambit
math/flann
math/labplot
math/mathgl
math/mdal
math/openturns
math/pdal
math/saga
misc/adios2
science/ALPSCore
science/InsightToolkit
science/InsightToolkit501
science/abinit
science/ascent
science/avogadrolibs
science/axom
science/cdo
science/cgnslib
science/cgribex
science/chemps2
science/chrono
science/conduit
science/dakota
science/dynare
science/eccodes
science/erkale
science/gnudatalanguage
science/hdf
science/hdf5
science/hdf5-110
science/helfem
science/lammps
science/netcdf
science/openmc
science/openmolcas
science/polytope
science/qmcpack
science/votca		(fails, unrelated, build_fs_violation in Poudriere)
sysutils/slurm-wlm
Comment 1 Gleb Popov freebsd_committer freebsd_triage 2024-03-31 20:39:33 UTC
It seems strange to have both  	CMAKE_OFF=BUILD_TESTING and USES=cmake:testing
Comment 2 Daniel Engberg freebsd_committer freebsd_triage 2024-03-31 21:15:04 UTC
There's no CMAKE_TESTING_OFF that gets applied to CMAKE_ARGS running a "normal build" (make) at least it doesn't work like that on my boxes.

Since CMAKE_TESTING_ARGS gets appended after CMAKE_ARGS it works either way.
https://cgit.freebsd.org/ports/tree/Mk/Uses/cmake.mk#n173
Comment 3 Gleb Popov freebsd_committer freebsd_triage 2024-04-01 17:39:24 UTC
I mean, just remove the ":testing" arg if you don't want to build tests as part of the normal build.

I find it strange however that CMake seemingly offers no option to just generate test targets, but build them only when `make test` is invoked.
Comment 4 Daniel Engberg freebsd_committer freebsd_triage 2024-04-01 17:50:53 UTC
The tests are enabled by default, it's not a side-effect of cmake:testing.

USES= cmake
make
...
[100% 27/27]


USES= cmake:testing
make
...
[100% 27/27]


USES= cmake:testing
CMAKE_OFF= AEC_FUZZING BUILD_TESTING (AEC is alread disabled so unnecessary)
make
...
[100% 13/13]


This is also reproduceable using Poudriere
Comment 5 Daniel Engberg freebsd_committer freebsd_triage 2024-04-01 17:52:16 UTC
To clarify, I think you're looking for https://cmake.org/cmake/help/latest/module/CTest.html :-)
Comment 6 Gleb Popov freebsd_committer freebsd_triage 2024-04-01 18:01:05 UTC
I still don't get it. What sets BUILD_TESTING to ON during the configure phase? If it is enabled by default then cmake.mk should always pass ENABLE_TESTING=OFF
Comment 7 Daniel Engberg freebsd_committer freebsd_triage 2024-04-01 18:02:21 UTC
https://cmake.org/cmake/help/latest/module/CTest.html --> The module automatically creates a BUILD_TESTING option that selects whether to enable testing support (ON by default).

https://github.com/MathisRosenhauer/libaec/blob/v1.1.3/CMakeLists.txt#L7
Comment 8 commit-hook freebsd_committer freebsd_triage 2024-04-06 00:03:56 UTC
A commit in branch main references this bug:

URL: https://cgit.FreeBSD.org/ports/commit/?id=bc32c0c8486198b2bb1ef7bb8c9baeeb705cd280

commit bc32c0c8486198b2bb1ef7bb8c9baeeb705cd280
Author:     Po-Chuan Hsieh <sunpoet@FreeBSD.org>
AuthorDate: 2024-04-06 00:00:10 +0000
Commit:     Po-Chuan Hsieh <sunpoet@FreeBSD.org>
CommitDate: 2024-04-06 00:00:10 +0000

    science/libaec: Do not build testing unconditionally

    PR:             278073
    Reported by:    diizzy

 science/libaec/Makefile | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)
Comment 9 Po-Chuan Hsieh freebsd_committer freebsd_triage 2024-04-06 00:08:44 UTC
Committed. Thanks!