diff --git a/Mk/Uses/fpc.mk b/Mk/Uses/fpc.mk index 31b6151aeba4..7538914c2d48 100644 --- a/Mk/Uses/fpc.mk +++ b/Mk/Uses/fpc.mk @@ -1,75 +1,71 @@ # Support for FPC-based ports. This automatically will install free pascal # compiler and units. # # Feature: fpc # Usage: USES=fpc # Valid ARGS: (none), run # # run - Free pascal compiler and units will be registered also # as run dependencies. # # Example: # # USES+= fpc:run # .if !defined(_INCLUDE_USES_FPC_MK) FPC_Include_MAINTAINER= acm@FreeBSD.org _INCLUDE_USES_FPC_MK= yes . if defined(DEFAULT_FPC_VER) WARNING+= "DEFAULT_FPC_VER is defined, consider using DEFAULT_VERSIONS=fpc=${DEFAULT_FPC_VER} instead" . endif . if ${fpc_ARGS:Nrun} IGNORE= Unknown argument for USES=fpc: ${fpc_ARGS:Nrun} . endif DEFAULT_FPC_VER= ${FPC_DEFAULT} # When adding a version, please keep the comment in # Mk/bsd.default-versions.mk in sync. FPC_VER= ${DEFAULT_FPC_VER} FPC_ARCH= ${ARCH:S/amd64/x86_64/} . if exists(${LOCALBASE}/bin/fpc) FPC_CURRENT_VER!= ${LOCALBASE}/bin/fpc -iV . if ${FPC_CURRENT_VER} != ${FPC_VER} IGNORE= incompatible fpc ${FPC_CURRENT_VER} compiler, please install ${FPC_VER} version . endif . endif . if ${ARCH} == "i386" PPNAME= ppc386 . elif ${ARCH} == "amd64" PPNAME= ppcx64 . elif ${ARCH} == "aarch64" PPNAME= ppca64 . else PPNAME= ppc_not_yet_ported . endif . if (defined(WANT_FPC_DEVEL) && !empty(WANT_FPC_DEVEL)) || ${ARCH:Maarch64} FPC_DEVELSUFFIX= -devel -ONLY_FOR_ARCHS= i386 amd64 aarch64 -ONLY_FOR_ARCHS_REASON= not yet ported to anything other than i386, amd64 and aarch64 . else FPC_DEVELSUFFIX= # -ONLY_FOR_ARCHS= i386 amd64 -ONLY_FOR_ARCHS_REASON= not yet ported to anything other than i386 and amd64 . endif BUILD_DEPENDS+= ${LOCALBASE}/bin/as:devel/binutils \ ${LOCALBASE}/lib/fpc/${FPC_VER}/${PPNAME}:lang/fpc${FPC_DEVELSUFFIX} . if ${fpc_ARGS:Mrun} RUN_DEPENDS+= ${LOCALBASE}/bin/as:devel/binutils \ ${LOCALBASE}/lib/fpc/${FPC_VER}/${PPNAME}:lang/fpc${FPC_DEVELSUFFIX} . endif BUILDNAME= ${FPC_ARCH}-${OPSYS:tl} UNITSDIR= ${LOCALBASE}/lib/fpc/${FPC_VER}/units/${BUILDNAME} MKINSTDIR= ${LOCALBASE}/lib/fpc/${FPC_VER}/fpmkinst/${BUILDNAME} .endif diff --git a/Mk/Uses/lazarus.mk b/Mk/Uses/lazarus.mk index ca8cf5cf70b9..8def6ad69799 100644 --- a/Mk/Uses/lazarus.mk +++ b/Mk/Uses/lazarus.mk @@ -1,155 +1,151 @@ # Support for Lazarus-based ports. # # Feature: lazarus # Usage: USES=lazarus # Valid ARGS: (none), gtk2, qt5, qt6, flavors # # (none) - This automatically build lazarus-app with gtk2 interface # # gtk2 - This automatically build lazarus-app with gtk2 interface # # qt5 - This automatically build lazarus-app with qt5 interface # # qt6 - This automatically build lazarus-app with qt6 interface # # flavors - This automatically build lazarus-app with flavors feature # # If the port not requires compile lazarus project files automatically, you can # defined the following: # # NO_LAZBUILD= yes # # Variables for ports: # # LAZARUS_PROJECT_FILES - List of lpi files. It must not be empty # Default: empty # LAZARUS_DIR - Path to lazarus installation directory # Default: ${LOCALBASE}/share/lazarus-${LAZARUS_VER} # LAZBUILD_ARGS - lazbuild extra args. It could be -d most of cases. # See man lazbuild for more information # Default: empty # LAZARUS_NO_FLAVORS - Do NOT build these lazarus flavors. # If LAZARUS_NO_FLAVORS is not define then all # valid lazarus flavors are assumed. # # Example: # # USES+= lazarus:flavors # LAZARUS_NO_FLAVORS=qt5 # .if !defined(_INCLUDE_USES_LAZARUS_MK) LAZARUS_Include_MAINTAINER= acm@FreeBSD.org _INCLUDE_USES_LAZARUS_MK= yes . if defined(DEFAULT_LAZARUS_VER) WARNING+= "DEFAULT_LAZARUS_VER is defined, consider using DEFAULT_VERSIONS=lazarus=${DEFAULT_LAZARUS_VER} instead" . endif . if ${lazarus_ARGS:Ngtk2:Nqt5:Nqt6:Nflavors} IGNORE= Unknown argument for USES=lazarus: ${lazarus_ARGS:Ngtk2:Nqt5:Nqt6:Nflavors} . endif . if !empty(LAZARUS_NO_FLAVORS) . if ${LAZARUS_NO_FLAVORS:Ngtk2:Nqt5:Nqt6} IGNORE= Unknown argument for LAZARUS_NO_FLAVORS: ${LAZARUS_NO_FLAVORS:Ngtk2:Nqt5:Nqt6} . endif . endif DEFAULT_LAZARUS_VER= ${LAZARUS_DEFAULT} DEFAULT_FPC_VER= ${FPC_DEFAULT} # When adding a version, please keep the comment in # Mk/bsd.default-versions.mk in sync. LAZARUS_VER= ${DEFAULT_LAZARUS_VER} FPC_VER= ${DEFAULT_FPC_VER} LAZARUS_ARCH= ${ARCH:S/amd64/x86_64/} LAZARUS_PROJECT_FILES?= # empty LAZARUS_DIR?= ${LOCALBASE}/share/lazarus-${LAZARUS_VER} . if (defined(WANT_FPC_DEVEL) && !empty(WANT_FPC_DEVEL)) || ${ARCH:Maarch64} FPC_DEVELSUFFIX= -devel . else FPC_DEVELSUFFIX= # . endif BUILDNAME= ${LAZARUS_ARCH}-${OPSYS:tl} LCL_UNITS_DIR= ${LOCALBASE}/share/lazarus-${LAZARUS_VER}/lcl/units/${BUILDNAME} MKINSTDIR= ${LOCALBASE}/lib/fpc/${FPC_VER}/fpmkinst/${BUILDNAME} BUILD_DEPENDS+= ${LOCALBASE}/bin/as:devel/binutils \ ${MKINSTDIR}/utils-lexyacc.fpm:lang/fpc${FPC_DEVELSUFFIX} LAZARUS_FLAVORS= gtk2 qt5 qt6 . if ${lazarus_ARGS:Mflavors} . if defined(LAZARUS_NO_FLAVORS) . for flavor in ${LAZARUS_NO_FLAVORS} FLAVORS:= ${LAZARUS_FLAVORS:N${flavor}} . endfor . else FLAVORS:= ${LAZARUS_FLAVORS} . endif . if empty(FLAVOR) FLAVOR= ${FLAVORS:[1]} . endif . endif LAZARUS_PKGNAMESUFFIX= -${FLAVOR} . if (defined(WANT_LAZARUS_DEVEL) && !empty(WANT_LAZARUS_DEVEL)) || ${ARCH:Maarch64} LAZARUS_DEVELSUFFIX= -devel -ONLY_FOR_ARCHS= i386 amd64 aarch64 -ONLY_FOR_ARCHS_REASON= not yet ported to anything other than i386, amd64 and aarch64 . else LAZARUS_DEVELSUFFIX= # -ONLY_FOR_ARCHS= i386 amd64 -ONLY_FOR_ARCHS_REASON= not yet ported to anything other than i386 and amd64 . endif . if ${lazarus_ARGS:Mgtk2} || ${FLAVOR} == gtk2 LIB_DEPENDS+= libglib-2.0.so:devel/glib20 \ libgtk-x11-2.0.so:x11-toolkits/gtk20 \ libatk-1.0.so:accessibility/at-spi2-core \ libpango-1.0.so:x11-toolkits/pango \ libgdk_pixbuf-2.0.so:graphics/gdk-pixbuf2 LCL_PLATFORM= gtk2 BUILD_DEPENDS+= ${LCL_UNITS_DIR}/${LCL_PLATFORM}/interfaces.ppu:editors/lazarus${LAZARUS_DEVELSUFFIX} . endif . if ${lazarus_ARGS:Mqt5} || ${FLAVOR} == qt5 LIB_DEPENDS+= libQt5Pas.so:x11-toolkits/qt5pas LCL_PLATFORM= qt5 BUILD_DEPENDS+= ${LCL_UNITS_DIR}/${LCL_PLATFORM}/interfaces.ppu:editors/lazarus-qt5${LAZARUS_DEVELSUFFIX} . endif . if ${lazarus_ARGS:Mqt6} || ${FLAVOR} == qt6 LIB_DEPENDS+= libQt6Pas.so:x11-toolkits/qt6pas LCL_PLATFORM= qt6 BUILD_DEPENDS+= ${LCL_UNITS_DIR}/${LCL_PLATFORM}/interfaces.ppu:editors/lazarus-qt6${LAZARUS_DEVELSUFFIX} . endif LAZBUILD_CMD= ${LOCALBASE}/bin/lazbuild LAZBUILD_ARGS?= # empty _USES_POST+= lazarus .endif # End of _INCLUDE_USES_LAZARUS_MK .if defined(_POSTMKINCLUDED) && !defined(_INCLUDE_USES_LAZARUS_POST_MK) _INCLUDE_USES_LAZARUS_POST_MK= yes . if !defined(NO_LAZBUILD) . if !target(do-build) do-build: . for PROJECT_FILE in ${LAZARUS_PROJECT_FILES} @(cd ${BUILD_WRKSRC}; ${SETENVI} ${WRK_ENV} ${MAKE_ENV} ${LAZBUILD_CMD} \ ${LAZBUILD_ARGS} --ws=${LCL_PLATFORM} --lazarusdir=${LAZARUS_DIR} ${PROJECT_FILE}) . endfor . endif # !target(do-build) . endif .endif # End of _INCLUDE_USES_LAZARUS_POST_MK