Files
rsadowski e8035d4760 Update CMake to 4.1.2
Major update from 3.31.8 to 4.1.2.

CMake 4.0 introduces a breaking change: compatibility with versions older than
3.5 has been removed. Projects calling cmake_minimum_required() or
cmake_policy() with versions < 3.5 now error out.

To maintain compatibility with existing ports during the transition, the cmake
module now provides MODCMAKE_POLICY_VERSION_OVERRIDE (idea from sthen@)
support:

- MODCMAKE_POLICY_VERSION_OVERRIDE ?= No
- MODCMAKE_POLICY_VERSION_OVERRIDE_VER ?= 3.5

When MODCMAKE_POLICY_VERSION_OVERRIDE is set to "yes", CMake is instructed to
accept policy versions down to the specified minimum (default 3.5) via
-DCMAKE_POLICY_VERSION_MINIMUM. This allows older ports to build while
acknowledging they may use deprecated features.

https://cmake.org/cmake/help/latest/release/4.0.html
https://cmake.org/cmake/help/latest/release/4.1.html

OK sthen@
2026-02-13 12:02:13 +00:00

49 lines
1.2 KiB
Makefile

COMMENT = OpenGL to PostScript printing library
DISTNAME = gl2ps-1.4.2
REVISION = 0
SHARED_LIBS = gl2ps 0.2 # 1.4
CATEGORIES = print
HOMEPAGE = http://www.geuz.org/gl2ps/
# LGPLv2
PERMIT_PACKAGE = Yes
WANTLIB = GL GLU Xi Xmu glut m png z
SITES = http://geuz.org/gl2ps/src/
EXTRACT_SUFX = .tgz
MODULES = devel/cmake
BUILD_DEPENDS = print/texlive/base
LIB_DEPENDS = graphics/freeglut \
graphics/png
MODCMAKE_LDFLAGS = -L${X11BASE}/lib -L${LOCALBASE}/lib
MODCMAKE_POLICY_VERSION_OVERRIDE = Yes
TEST_IS_INTERACTIVE = x11
TEST_TMP=${WRKDIR}/test_tmp
do-test:
mkdir -p ${TEST_TMP}
${CC} -I${LOCALBASE}/include -I${X11BASE}/include \
-L${LOCALBASE}/lib -L${X11BASE}/lib -L${WRKBUILD} \
-lgl2ps -lglut -lGL -lGLU -lX11 -lm \
${WRKSRC}/gl2psTestSimple.c -o ${TEST_TMP}/gl2psTestSimple
${CC} -I${LOCALBASE}/include -I${X11BASE}/include \
-L${LOCALBASE}/lib -L${X11BASE}/lib -L${WRKBUILD} \
-lgl2ps -lglut -lGL -lGLU -lX11 -lm \
-DHAVE_LIBPNG -DHAVE_ZLIB -lpng -lz \
${WRKSRC}/gl2psTest.c -o ${TEST_TMP}/gl2psTest
cd ${TEST_TMP} && LD_LIBRARY_PATH=${WRKBUILD} ${TEST_TMP}/gl2psTestSimple
cd ${TEST_TMP} && LD_LIBRARY_PATH=${WRKBUILD} ${TEST_TMP}/gl2psTest
.include <bsd.port.mk>