Changeset View
Changeset View
Standalone View
Standalone View
devel/cmake/Makefile
- This file was copied to devel/cmake-core/Makefile.
PORTNAME= cmake | PORTNAME= cmake | ||||
# Remember to update devel/cmake-doc and devel/cmake-gui as well. | |||||
DISTVERSION= 3.23.3 | DISTVERSION= 3.23.3 | ||||
CATEGORIES= devel | CATEGORIES= devel | ||||
MASTER_SITES= https://github.com/Kitware/CMake/releases/download/v${DISTVERSION}/ \ | PORTREVISION= 1 | ||||
https://www.cmake.org/files/v${PORTVERSION}/ | |||||
MAINTAINER= kde@FreeBSD.org | MAINTAINER= kde@FreeBSD.org | ||||
COMMENT= Cross-platform Makefile generator | COMMENT= Meta-port to connect all CMake bits | ||||
WWW= https://www.cmake.org/ | WWW= https://www.cmake.org/ | ||||
LICENSE= BSD3CLAUSE | LICENSE= BSD3CLAUSE | ||||
LICENSE_FILE= ${WRKSRC}/Copyright.txt | |||||
LIB_DEPENDS= libcurl.so:ftp/curl \ | USES= cmake:run metaport | ||||
libexpat.so:textproc/expat2 \ | |||||
libjsoncpp.so:devel/jsoncpp \ | |||||
libuv.so:devel/libuv \ | |||||
librhash.so:security/rhash | |||||
USES= compiler:c++11-lang cpe ncurses | NO_LICENSES_INSTALL= yes | ||||
PLIST_FILES= # not applicable | |||||
CPE_VENDOR= cmake_project | OPTIONS_DEFINE= DOCS GUI MANPAGES | ||||
HAS_CONFIGURE= yes | |||||
CONFIGURE_ENV= MAKE=make | |||||
CONFIGURE_ARGS= --prefix=${PREFIX} \ | |||||
--datadir="/${DATADIR_REL}" \ | |||||
--docdir="/${DOCSDIR_REL}" \ | |||||
--system-libs \ | |||||
--parallel=${MAKE_JOBS_NUMBER} \ | |||||
--init="${WRKSRC}/InitialCache.cmake" | |||||
OPTIONS_DEFINE= DOCS MANPAGES CPACK | |||||
OPTIONS_DEFAULT=MANPAGES | OPTIONS_DEFAULT= MANPAGES | ||||
OPTIONS_SUB= yes | |||||
MANPAGES_USES= python:env | GUI_DESC= Qt-based GUI | ||||
tcberner: ^ seems to be a remnant of the previous version | |||||
MANPAGES_BUILD_DEPENDS= sphinx-build:textproc/py-sphinx | |||||
MANPAGES_CONFIGURE_ON= --sphinx-man | |||||
CPACK_DESC= Enable FreeBSD generator in CPack (experimental) | DOCS_RUN_DEPENDS= ${LOCALBASE}/share/doc/cmake/html/index.html:devel/cmake-doc | ||||
CPACK_LIB_DEPENDS= libpkg.so:${PKG_ORIGIN} | GUI_RUN_DEPENDS= ${LOCALBASE}/bin/cmake-gui:devel/cmake-gui | ||||
CPACK_USES_OFF= libarchive | MANPAGES_RUN_DEPENDS= ${LOCALBASE}/man/man1/cmake.1.gz:devel/cmake-man | ||||
# When CPACK is on, uses base libarchive and won't pass stage-qa | |||||
CXXFLAGS+= -D__BSD_VISIBLE | # Mk/Uses/cmake.mk sets do-configure which we don't want for a meta-port | ||||
do-configure: | |||||
.include <bsd.port.pre.mk> | .include <bsd.port.mk> | ||||
Not Done Inline Actions^ DOCSADD seems a bit weird -- why not simply call it DOCS as usual? tcberner: ^ `DOCSADD` seems a bit weird -- why not simply call it `DOCS` as usual? | |||||
Not Done Inline ActionsThis was to retain the current "setup", we can rename it to DOCS but I'd like to avoid hacking around defaults in our framework diizzy: This was to retain the current "setup", we can rename it to DOCS but I'd like to avoid hacking… | |||||
Done Inline Actions^ ? tcberner: ^ ? | |||||
Done Inline ActionsThis is to make the framework happy, otherwise it'll try to access non-existing directory and fail diizzy: This is to make the framework happy, otherwise it'll try to access non-existing directory and… | |||||
Done Inline Actions^ USES=metaport instead of MASTER_SITES, DISTFILES and so on on lines 2-3 and NO_ARCH, NO_BUILD on 12-13 tcberner: ^ `USES=metaport` instead of `MASTER_SITES, DISTFILES` and so on on lines 2-3 and `NO_ARCH… | |||||
.if defined(STRIP) && ${STRIP} != "" && !defined(WITH_DEBUG) | |||||
INSTALL_TARGET= install/strip | |||||
.endif | |||||
# Before running configure, substitute in the values of options | |||||
# for the build. CMake's configure doesn't accept --with-foo | |||||
# or similar options: it expects them to be set in CMake-style | |||||
# syntax in the initial cache. | |||||
pre-configure: | |||||
@${CP} "${FILESDIR}/InitialCache.cmake" "${WRKSRC}/InitialCache.cmake" | |||||
pre-configure-CPACK-on: | |||||
@${REINPLACE_CMD} \ | |||||
-e 's/@@CPACK_OPTION_VALUE@@/ON/' \ | |||||
-e 's/@@CPACK_OPTION_COMMENT@@//' \ | |||||
"${WRKSRC}/InitialCache.cmake" | |||||
pre-configure-CPACK-off: | |||||
@${REINPLACE_CMD} \ | |||||
-e 's/@@CPACK_OPTION_VALUE@@/OFF/' \ | |||||
-e 's/@@CPACK_OPTION_COMMENT@@/# /' \ | |||||
"${WRKSRC}/InitialCache.cmake" | |||||
post-patch: | |||||
@(${FIND} ${WRKSRC}/Modules -name "*.cmake" -print0; \ | |||||
${FIND} ${WRKSRC}/Tests -name "CMakeLists.txt" -print0 ) | \ | |||||
${XARGS} -0 -n 100 ${REINPLACE_CMD} -e 's,/usr/local,${LOCALBASE},g; \ | |||||
s,/usr/X11R6,${LOCALBASE},g' | |||||
@${REINPLACE_CMD} -e 's,/usr/local,${LOCALBASE},g' \ | |||||
${WRKSRC}/Source/cmLocalGenerator.cxx \ | |||||
${WRKSRC}/Source/CPack/cmCPackGenerator.cxx \ | |||||
${WRKSRC}/bootstrap | |||||
@${REINPLACE_CMD} -e 's,/opt/kde4,${PREFIX},g' \ | |||||
${WRKSRC}/Modules/FindKDE4.cmake | |||||
@${REINPLACE_CMD} -e 's,/usr/include,${LOCALBASE}/include,' \ | |||||
${WRKSRC}/Modules/FindDCMTK.cmake | |||||
@${REINPLACE_CMD} -e 's|%%LOCALBASE%%|${LOCALBASE}|g' \ | |||||
${WRKSRC}/Modules/FindFLEX.cmake | |||||
@${FIND} ${WRKSRC} -name "*.bak" -delete -o -name "*.orig" -delete | |||||
# cmake-gui(1) is installed by devel/cmake-gui. Remove the man page's source to | |||||
# prevent it from being built/installed by devel/cmake. | |||||
${RM} ${WRKSRC}/Help/manual/cmake-gui.1.rst | |||||
post-install: | |||||
${INSTALL_DATA} ${WRKSRC}/Auxiliary/cmake-mode.el ${STAGEDIR}${PREFIX}/share/emacs/site-lisp | |||||
# The .NoDartCoverage is supposed to suppress testing in the | |||||
# source directories, but gets accidentally installed. | |||||
@${FIND} ${STAGEDIR}${PREFIX} -name ".NoDartCoverage" -delete | |||||
.include <bsd.port.post.mk> |
^ seems to be a remnant of the previous version