mirror of
https://git.FreeBSD.org/ports.git
synced 2024-11-19 00:13:33 +00:00
Remove bits replaced by USES=gecko
This commit is contained in:
parent
2acd3c6d9c
commit
f718dc1633
Notes:
svn2git
2021-03-31 03:12:20 +00:00
svn path=/head/; revision=350810
409
Mk/bsd.gecko.mk
409
Mk/bsd.gecko.mk
@ -8,17 +8,6 @@
|
||||
#
|
||||
# 4 column tabs prevent hair loss and tooth decay!
|
||||
|
||||
# ======================= USERS =================================
|
||||
# To specify which gecko-based backend you prefer, use something like:
|
||||
#
|
||||
# WITH_GECKO= libxul
|
||||
#
|
||||
# The valid backends are:
|
||||
# libxul
|
||||
#
|
||||
# See below for more details.
|
||||
# ======================= /USERS ================================
|
||||
|
||||
# bsd.gecko.mk abstracts the selection of gecko-based backends. It allows users
|
||||
# and porters to support any available gecko backend without needing to build
|
||||
# many conditional tests. ${USE_GECKO} is the list of backends that your port
|
||||
@ -26,403 +15,7 @@
|
||||
# Users set ${WITH_GECKO} to the list of gecko backends they want on their
|
||||
# system.
|
||||
|
||||
.if defined(USE_GECKO) && ${USE_GECKO}!="gecko"
|
||||
|
||||
.if !defined(Gecko_Pre_Include)
|
||||
# Please make sure all changes to this file are passed through the maintainer.
|
||||
# Do not commit them yourself (unless of course you're the Port's Wraith ;).
|
||||
Gecko_Include_MAINTAINER= gecko@FreeBSD.org
|
||||
Gecko_Pre_Include= bsd.gecko.mk
|
||||
|
||||
# Users should use the following syntax:
|
||||
#
|
||||
# WITH_GECKO= libxul
|
||||
# Use libxul whenever a port supports it
|
||||
# WITH_GECKO= libxul
|
||||
# Sets your preferred backend. With this example, libxul will always
|
||||
# be chosen, unless the port doesn't support a libxul backend. In that
|
||||
# case, you get whatever the porter chose as the default. Better to use
|
||||
# the first example.
|
||||
#
|
||||
#
|
||||
# Ports should use the following:
|
||||
#
|
||||
# USE_GECKO= libxul
|
||||
# The list of gecko backends that the port supports. Unless the user
|
||||
# overrides it with WITH_GECKO, the first gecko listed in USE_GECKO
|
||||
# will be the default.
|
||||
#
|
||||
# USE_GECKO= libxul19<->libxul
|
||||
# This will sed -e 's/libxul/libxul19/' on Makefile.in's and configure
|
||||
# if ${GECKO}=="libxul19"
|
||||
#
|
||||
# Example:
|
||||
# USE_GECKO= libxul
|
||||
#
|
||||
# post-patch:
|
||||
# @${REINPLACE_CMD} -e 's|mozilla-|${GECKO}-|' \
|
||||
# ${MOZSRC}/configure
|
||||
#
|
||||
# If you want your port to check the ${GECKO} variable to see which backend
|
||||
# has been chosen.
|
||||
#
|
||||
# Example:
|
||||
# USE_GECKO= libxul
|
||||
#
|
||||
# post-patch:
|
||||
# .if ${GECKO}=="libxul19"
|
||||
# @${REINPLACE_CMD} -e 's|mozilla-|libxul-|' \
|
||||
# ${MOZSRC}/configure
|
||||
# .endif
|
||||
|
||||
_GECKO_ALL= libxul
|
||||
|
||||
libxul_PLIST= libxul>=24
|
||||
|
||||
.for gecko in ${_GECKO_ALL}
|
||||
${gecko}_PORTSDIR?= www
|
||||
${gecko}_DEPENDS?= ${PORTSDIR}/${${gecko}_PORTSDIR}/${gecko}
|
||||
${gecko}_PLIST?= ${LOCALBASE}/lib/${gecko}/libgtkembedmoz.so
|
||||
.endfor
|
||||
|
||||
# Figure out which mozilla to use
|
||||
# Weed out bad options in USE_GECKO
|
||||
.for badgecko in ${USE_GECKO}
|
||||
. if ${_GECKO_ALL:M${badgecko:C/^([^<->]+).*/\1/}}!=""
|
||||
GOOD_USE_GECKO+= ${badgecko:C/^([^<->]+).*/\1/}
|
||||
. endif
|
||||
. if ${_GECKO_ALL:M${badgecko:C/^[^<->]+<->([^<->]+).*/\1/}}!="${badgecko:C/^([^<->]+).*/\1/}"
|
||||
${badgecko:C/^([^<->]+).*/\1/}_HACK= s:${badgecko:C/^[^<->]+<->([^<->]+).*/\1/}:${badgecko:C/^([^<->]+).*/\1/}:g
|
||||
. endif
|
||||
.endfor
|
||||
|
||||
.undef GECKO_FALLTHROUGH
|
||||
.undef _FOUND_WITH_GECKO
|
||||
# Figure out which gecko to use and weed out the bad ones
|
||||
.if defined(WITH_GECKO) && defined(GOOD_USE_GECKO)
|
||||
. for badgecko in ${WITH_GECKO}
|
||||
. if ${GOOD_USE_GECKO:M${badgecko}}!=""
|
||||
GOOD_WITH_GECKO+= ${badgecko}
|
||||
. endif
|
||||
. endfor
|
||||
. if defined(GOOD_WITH_GECKO)
|
||||
. for gecko in ${GOOD_WITH_GECKO}
|
||||
. if !defined(GECKO_FALLTHROUGH)
|
||||
GECKO= ${gecko}
|
||||
GECKO_FALLTHROUGH= ${TRUE}
|
||||
_FOUND_WITH_GECKO= ${TRUE}
|
||||
. endif
|
||||
. endfor
|
||||
. endif
|
||||
.endif
|
||||
|
||||
.if !defined(GECKO) && defined(GOOD_USE_GECKO)
|
||||
. for gecko in ${GOOD_USE_GECKO}
|
||||
. if !defined(GECKO_FALLTRHOUGH)
|
||||
GECKO= ${gecko}
|
||||
GECKO_FALLTRHOUGH= ${TRUE}
|
||||
. endif
|
||||
. endfor
|
||||
.endif
|
||||
|
||||
# Generic defines
|
||||
GECKO_CONFIG?= ${LOCALBASE}/bin/${GECKO}-config
|
||||
XPIDL?= ${LOCALBASE}/lib/${GECKO}/xpidl
|
||||
XPIDL_INCL?= `${GECKO_CONFIG} --idlflags`
|
||||
|
||||
.if defined(GECKO) && ${_GECKO_ALL:M${GECKO}}!=""
|
||||
BUILD_DEPENDS+= ${${GECKO}_PLIST}:${${GECKO}_DEPENDS}
|
||||
RUN_DEPENDS+= ${${GECKO}_PLIST}:${${GECKO}_DEPENDS}
|
||||
.else
|
||||
IGNORE= Unable to find a supported gecko, please check USE_GECKO
|
||||
.endif
|
||||
|
||||
pre-everything:: _gecko-pre-everything
|
||||
|
||||
_gecko-pre-everything::
|
||||
@${ECHO_CMD} ""
|
||||
.if !defined(_FOUND_WITH_GECKO) && defined(WITH_GECKO)
|
||||
@${ECHO_CMD} " Warning: ${PORTNAME} does not support any gecko you"
|
||||
@${ECHO_CMD} " listed in WITH_GECKO=${WITH_GECKO}."
|
||||
@${ECHO_CMD} " \"${GECKO}\" will be used"
|
||||
@${ECHO_CMD} ""
|
||||
@${ECHO_CMD} " for gecko support, but you can change that by using one of"
|
||||
@${ECHO_CMD} " the following values:"
|
||||
.else
|
||||
@${ECHO_CMD} " ${PORTNAME} is using ${GECKO} for gecko support, but you can"
|
||||
@${ECHO_CMD} " change that by defining WITH_GECKO to the following values:"
|
||||
.endif
|
||||
@${ECHO_CMD} ""
|
||||
.for gecko in ${GOOD_USE_GECKO}
|
||||
@${ECHO_CMD} " ${gecko} "
|
||||
.endfor
|
||||
@${ECHO_CMD} ""
|
||||
|
||||
post-patch: gecko-post-patch
|
||||
|
||||
gecko-post-patch:
|
||||
.if defined(${GECKO}_HACK)
|
||||
${FIND} ${WRKSRC} -name "Makefile.in" -type f -o -name "configure" -type f | \
|
||||
${XARGS} ${REINPLACE_CMD} -e ${${GECKO}_HACK}
|
||||
.endif
|
||||
.endif
|
||||
|
||||
.elif !defined(_POSTMKINCLUDED) && !defined(Gecko_Pre_Include) && (defined(USE_FIREFOX) || defined(USE_FIREFOX_BUILD) || defined(USE_SEAMONKEY) || defined(USE_SEAMONKEY_BUILD) || defined(USE_THUNDERBIRD) || defined(USE_THUNDERBIRD_BUILD))
|
||||
Gecko_Pre_Include= bsd.gecko.mk
|
||||
|
||||
# Ports can use the following:
|
||||
#
|
||||
# USE_FIREFOX Add runtime dependency on Firefox. If no version
|
||||
# is given by the maintainer via the port or by the
|
||||
# user via defined variable try to find the highest
|
||||
# stable installed version.
|
||||
# Available values: yes 24+ 28+ 24 28
|
||||
# NOTE:
|
||||
# default value 24 is used in case of USE_FIREFOX=yes
|
||||
#
|
||||
# USE_FIREFOX_BUILD Add buildtime dependency on Firefox.
|
||||
# Available values: see USE_FIREFOX
|
||||
#
|
||||
# USE_SEAMONKEY Add runtime dependency on SeaMonkey. If no
|
||||
# version is given by the maintainer via the port
|
||||
# or by the user via defined variable try to find
|
||||
# the highest stable installed version.
|
||||
# Available values: yes 25+ 25
|
||||
# NOTE:
|
||||
# default value 25 is used in case of USE_SEAMONKEY=yes
|
||||
#
|
||||
# USE_SEAMONKEY_BUILD Add buildtime dependency on SeaMonkey.
|
||||
# Available values: see USE_SEAMONKEY
|
||||
#
|
||||
# USE_THUNDERBIRD Add runtime dependency on Thunderbird. If no
|
||||
# version is given by the maintainer via the port
|
||||
# or by the user via defined variable try to find
|
||||
# the highest stable installed version.
|
||||
# Available values: yes 24+ 24
|
||||
# NOTE:
|
||||
# default value 24 is used in case of USE_THUNDERBIRD=yes
|
||||
#
|
||||
# USE_THUNDERBIRD_BUILD Add buildtime dependency on Thunderbird.
|
||||
# Available values: see USE_THUNDERBIRD
|
||||
#
|
||||
|
||||
#
|
||||
# Firefox part
|
||||
#
|
||||
.if defined(USE_FIREFOX) || defined(USE_FIREFOX_BUILD)
|
||||
|
||||
# Process USE_FIREFOX_BUILD
|
||||
.if defined(USE_FIREFOX_BUILD)
|
||||
USE_FIREFOX:= ${USE_FIREFOX_BUILD}
|
||||
_FIREFOX_BUILD_DEPENDS= yes
|
||||
.endif
|
||||
|
||||
_FIREFOX_DEFAULT_VERSION= 24
|
||||
_FIREFOX_VERSIONS= 24 28
|
||||
_FIREFOX_RANGE_VERSIONS= 24+ 28+
|
||||
|
||||
# For specifying [24, ..]+
|
||||
_FIREFOX_28P= 28 ${_FIREFOX_24P}
|
||||
_FIREFOX_24P= 24
|
||||
|
||||
# Set the default Firefox version and check if USE_FIREFOX=yes was given
|
||||
.if ${USE_FIREFOX} == "yes"
|
||||
USE_FIREFOX= ${_FIREFOX_DEFAULT_VERSION}
|
||||
.endif
|
||||
|
||||
# Setting/finding Firefox version we want.
|
||||
.if exists(${LOCALBASE}/bin/firefox)
|
||||
_FIREFOX_VER!= ${LOCALBASE}/bin/firefox --version 2>/dev/null | ${HEAD} -1 | ${SED} -e 's/Mozilla Firefox \([0-9]\{1,2\}\)\.\([0-9]*\).*/\1/'
|
||||
.endif
|
||||
|
||||
# Check if installed Firefox version matches the wanted one
|
||||
.if defined(_FIREFOX_VER)
|
||||
_SUPFIREFOX= no
|
||||
.if ${USE_FIREFOX:C/[0-9][0-9]//} == "+"
|
||||
.for ver in ${_FIREFOX_RANGE_VERSIONS}
|
||||
.if ${USE_FIREFOX} == "${ver}"
|
||||
_MATCHED_FIREFOX_VER:= ${ver:S/+//}
|
||||
.for firefox in ${_FIREFOX_${_MATCHED_FIREFOX_VER}P}
|
||||
.if ${_FIREFOX_VER} == ${firefox}
|
||||
_SUPFIREFOX= yes
|
||||
USE_FIREFOX= ${_FIREFOX_VER}
|
||||
.endif
|
||||
.endfor
|
||||
.endif
|
||||
.endfor
|
||||
.else
|
||||
.if ${_FIREFOX_VER} == ${USE_FIREFOX}
|
||||
_SUPFIREFOX= yes
|
||||
.endif
|
||||
.endif
|
||||
.if ${_SUPFIREFOX} == no
|
||||
_DISPLAY_VERSION_HAVE= ${_FIREFOX_VER}
|
||||
_DISPLAY_VERSION_WANT= ${USE_FIREFOX}
|
||||
|
||||
IGNORE= cannot install: Firefox versions mismatch: firefox-${_DISPLAY_VERSION_HAVE} is installed and wanted version is firefox-${_DISPLAY_VERSION_WANT}
|
||||
.endif
|
||||
.endif
|
||||
|
||||
.if !defined(_FIREFOX_${USE_FIREFOX:S/+//}P)
|
||||
IGNORE= cannot install: unknown Firefox version: firefox-${USE_FIREFOX:C/([0-9])([0-9])/\1.\2/}
|
||||
.endif
|
||||
|
||||
# Dependence lines for different Firefox versions
|
||||
24_DEPENDS= ${LOCALBASE}/lib/firefox/firefox:${PORTSDIR}/www/firefox-esr
|
||||
28_DEPENDS= ${LOCALBASE}/lib/firefox/firefox:${PORTSDIR}/www/firefox
|
||||
|
||||
# Add dependencies
|
||||
.if defined(USE_FIREFOX)
|
||||
.if defined(_FIREFOX_BUILD_DEPENDS)
|
||||
BUILD_DEPENDS+= ${${USE_FIREFOX}_DEPENDS}
|
||||
.endif
|
||||
RUN_DEPENDS+= ${${USE_FIREFOX}_DEPENDS}
|
||||
.endif
|
||||
|
||||
.endif # defined(USE_FIREFOX)
|
||||
#
|
||||
# SeaMonkey part
|
||||
#
|
||||
.if defined(USE_SEAMONKEY) || defined(USE_SEAMONKEY_BUILD)
|
||||
|
||||
# Process USE_SEAMONKEY_BUILD
|
||||
.if defined(USE_SEAMONKEY_BUILD)
|
||||
USE_SEAMONKEY:= ${USE_SEAMONKEY_BUILD}
|
||||
_SEAMONKEY_BUILD_DEPENDS= yes
|
||||
.endif
|
||||
|
||||
_SEAMONKEY_DEFAULT_VERSION= 25
|
||||
_SEAMONKEY_VERSIONS= 25
|
||||
_SEAMONKEY_RANGE_VERSIONS= 25+
|
||||
|
||||
# For specifying [25, ..]+
|
||||
_SEAMONKEY_25P= 25
|
||||
|
||||
# Set the default SeaMonkey version and check if USE_SEAMONKEY=yes was given
|
||||
.if ${USE_SEAMONKEY} == "yes"
|
||||
USE_SEAMONKEY= ${_SEAMONKEY_DEFAULT_VERSION}
|
||||
.endif
|
||||
|
||||
# Setting/finding SeaMonkey version we want.
|
||||
.if exists(${LOCALBASE}/bin/seamonkey)
|
||||
_SEAMONKEY_VER!= ${LOCALBASE}/bin/seamonkey --version 2>/dev/null | ${HEAD} -1 | ${SED} -e 's/Mozilla SeaMonkey \([0-9]\{1,2\}\)\.\([0-9]*\).*/\2/'
|
||||
.endif
|
||||
|
||||
# Check if installed SeaMonkey version matches the wanted one
|
||||
.if defined(_SEAMONKEY_VER)
|
||||
_SUPSEAMONKEY= no
|
||||
.if ${USE_SEAMONKEY:C/[0-9][0-9]//} == "+"
|
||||
.for ver in ${_SEAMONKEY_RANGE_VERSIONS}
|
||||
.if ${USE_SEAMONKEY} == "${ver}"
|
||||
_MATCHED_SEAMONKEY_VER:= ${ver:S/+//}
|
||||
.for seamonkey in ${_SEAMONKEY_${_MATCHED_SEAMONKEY_VER}P}
|
||||
.if ${_SEAMONKEY_VER} == ${seamonkey}
|
||||
_SUPSEAMONKEY= yes
|
||||
USE_SEAMONKEY= ${_SEAMONKEY_VER}
|
||||
.endif
|
||||
.endfor
|
||||
.endif
|
||||
.endfor
|
||||
.else
|
||||
.if ${_SEAMONKEY_VER} == ${USE_SEAMONKEY}
|
||||
_SUPSEAMONKEY= yes
|
||||
.endif
|
||||
.endif
|
||||
.if ${_SUPSEAMONKEY} == no
|
||||
IGNORE= cannot install: SeaMonkey versions mismatch: seamonkey-2.${_SEAMONKEY_VER} is installed and wanted version is seamonkey-2.${USE_SEAMONKEY}
|
||||
.endif
|
||||
.endif
|
||||
|
||||
.if !defined(_SEAMONKEY_${USE_SEAMONKEY:S/+//}P)
|
||||
IGNORE= cannot install: unknown SeaMonkey version: seamonkey-2.${USE_SEAMONKEY}
|
||||
.endif
|
||||
|
||||
# Dependence lines for different SeaMonkey versions
|
||||
25_DEPENDS= ${LOCALBASE}/lib/seamonkey/seamonkey:${PORTSDIR}/www/seamonkey
|
||||
|
||||
# Add dependencies
|
||||
.if defined(USE_SEAMONKEY)
|
||||
.if defined(_SEAMONKEY_BUILD_DEPENDS)
|
||||
BUILD_DEPENDS+= ${${USE_SEAMONKEY}_DEPENDS}
|
||||
.endif
|
||||
RUN_DEPENDS+= ${${USE_SEAMONKEY}_DEPENDS}
|
||||
.endif
|
||||
|
||||
.endif # defined(USE_SEAMONKEY)
|
||||
#
|
||||
# Thunderbird part
|
||||
#
|
||||
.if defined(USE_THUNDERBIRD) || defined(USE_THUNDERBIRD_BUILD)
|
||||
|
||||
# Process USE_THUNDERBIRD_BUILD
|
||||
.if defined(USE_THUNDERBIRD_BUILD)
|
||||
USE_THUNDERBIRD:= ${USE_THUNDERBIRD_BUILD}
|
||||
_THUNDERBIRD_BUILD_DEPENDS= yes
|
||||
.endif
|
||||
|
||||
_THUNDERBIRD_DEFAULT_VERSION= 24
|
||||
_THUNDERBIRD_VERSIONS= 24
|
||||
_THUNDERBIRD_RANGE_VERSIONS= 24+
|
||||
|
||||
# For specifying [24, ..]+
|
||||
_THUNDERBIRD_24P= 24
|
||||
|
||||
# Set the default Thunderbird version and check if USE_THUNDERBIRD=yes was given
|
||||
.if ${USE_THUNDERBIRD} == "yes"
|
||||
USE_THUNDERBIRD= ${_THUNDERBIRD_DEFAULT_VERSION}
|
||||
.endif
|
||||
|
||||
# Setting/finding Thunderbird version we want.
|
||||
.if exists(${LOCALBASE}/bin/thunderbird)
|
||||
_THUNDERBIRD_VER!= ${LOCALBASE}/bin/thunderbird --version 2>/dev/null | ${HEAD} -1 | ${SED} -e 's/ Thunderbird \([0-9]\{1,2\}\)\.\([0-9]*\).*/\1/'
|
||||
.endif
|
||||
|
||||
# Check if installed Thunderbird version matches the wanted one
|
||||
.if defined(_THUNDERBIRD_VER)
|
||||
_SUPTHUNDERBIRD= no
|
||||
.if ${USE_THUNDERBIRD:C/[0-9][0-9]//} == "+"
|
||||
.for ver in ${_THUNDERBIRD_RANGE_VERSIONS}
|
||||
.if ${USE_THUNDERBIRD} == "${ver}"
|
||||
_MATCHED_THUNDERBIRD_VER:= ${ver:S/+//}
|
||||
.for thunderbird in ${_THUNDERBIRD_${_MATCHED_THUNDERBIRD_VER}P}
|
||||
.if ${_THUNDERBIRD_VER} == ${thunderbird}
|
||||
_SUPTHUNDERBIRD= yes
|
||||
USE_THUNDERBIRD= ${_THUNDERBIRD_VER}
|
||||
.endif
|
||||
.endfor
|
||||
.endif
|
||||
.endfor
|
||||
.else
|
||||
.if ${_THUNDERBIRD_VER} == ${USE_THUNDERBIRD}
|
||||
_SUPTHUNDERBIRD= yes
|
||||
.endif
|
||||
.endif
|
||||
.if ${_SUPTHUNDERBIRD} != yes
|
||||
_DISPLAY_VERSION_HAVE= ${_THUNDERBIRD_VER}
|
||||
_DISPLAY_VERSION_WANT= ${USE_THUNDERBIRD}
|
||||
IGNORE= cannot install: Thunderbird versions mismatch: thunderbird-${_DISPLAY_VERSION_HAVE} is installed and wanted version is thunderbird-${_DISPLAY_VERSION_WANT}
|
||||
.endif
|
||||
.endif
|
||||
|
||||
.if !defined(_THUNDERBIRD_${USE_THUNDERBIRD:S/+//}P)
|
||||
IGNORE= cannot install: unknown Thunderbird version: thunderbird-${USE_THUNDERBIRD:C/([0-9])([0-9])/\1.\2/}
|
||||
.endif
|
||||
|
||||
# Dependence lines for different Thunderbird versions
|
||||
24_DEPENDS= ${LOCALBASE}/lib/thunderbird/thunderbird:${PORTSDIR}/mail/thunderbird
|
||||
|
||||
# Add dependencies
|
||||
.if defined(USE_THUNDERBIRD)
|
||||
.if defined(_THUNDERBIRD_BUILD_DEPENDS)
|
||||
BUILD_DEPENDS+= ${${USE_THUNDERBIRD}_DEPENDS}
|
||||
.endif
|
||||
RUN_DEPENDS+= ${${USE_THUNDERBIRD}_DEPENDS}
|
||||
.endif
|
||||
|
||||
.endif # defined(USE_THUNDERBIRD)
|
||||
|
||||
.else # split
|
||||
|
||||
.if defined(USE_GECKO)
|
||||
.if !defined(_POSTMKINCLUDED) && !defined(Gecko_Pre_Include)
|
||||
Gecko_Pre_Include= bsd.gecko.mk
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user