1
0
mirror of https://git.FreeBSD.org/ports.git synced 2025-01-26 09:46:09 +00:00
freebsd-ports/games/xye/Makefile
Stefan Eßer b7f05445c0 Add WWW entries to port Makefiles
It has been common practice to have one or more URLs at the end of the
ports' pkg-descr files, one per line and prefixed with "WWW:". These
URLs should point at a project website or other relevant resources.

Access to these URLs required processing of the pkg-descr files, and
they have often become stale over time. If more than one such URL was
present in a pkg-descr file, only the first one was tarnsfered into
the port INDEX, but for many ports only the last line did contain the
port specific URL to further information.

There have been several proposals to make a project URL available as
a macro in the ports' Makefiles, over time.

This commit implements such a proposal and moves one of the WWW: entries
of each pkg-descr file into the respective port's Makefile. A heuristic
attempts to identify the most relevant URL in case there is more than
one WWW: entry in some pkg-descr file. URLs that are not moved into the
Makefile are prefixed with "See also:" instead of "WWW:" in the pkg-descr
files in order to preserve them.

There are 1256 ports that had no WWW: entries in pkg-descr files. These
ports will not be touched in this commit.

The portlint port has been adjusted to expect a WWW entry in each port
Makefile, and to flag any remaining "WWW:" lines in pkg-descr files as
deprecated.

Approved by:		portmgr (tcberner)
2022-09-07 23:10:59 +02:00

96 lines
2.8 KiB
Makefile

PORTNAME= xye
PORTVERSION= 0.12.2
PORTREVISION= 4
CATEGORIES= games
MASTER_SITES= SF:game \
http://xye.sourceforge.net/levels/ \
http://xye.sourceforge.net/:xmas \
SF/nemysisfreebsdp/${CATEGORIES}/${PORTNAME}/:nemysis \
http://xye.sourceforge.net/skins/:skins
DISTFILES= ${PORTNAME}-${DISTVERSION}${EXTRACT_SUFX}:game \
${LEVELS:S/$/.zip/} \
${LEVELS_XYE:S/$/.xye/} \
xmas-xye-2009.zip:xmas \
xye_extra_levels.20121109.zip:nemysis \
Xye%20skin%20-%20classic%20kye.zip:skins \
XMASKYESKIN.zip:skins
DIST_SUBDIR= ${PORTNAME}
EXTRACT_ONLY= ${PORTNAME}-${DISTVERSION}${EXTRACT_SUFX}
MAINTAINER= ports@FreeBSD.org
COMMENT= Puzzle games like sokoban or boulderdash
WWW= http://xye.sourceforge.net/
LICENSE= ZLIB
EXTRACT_DEPENDS=${UNZIP_CMD}:archivers/unzip
USES= compiler gmake sdl
USE_SDL= sdl image ttf
GNU_CONFIGURE= yes
CONFIGURE_ARGS= --with-docdir=${PREFIX}/share/doc
CXXFLAGS+= ${CXXFLAGS_${CHOSEN_COMPILER_TYPE}}
CXXFLAGS_clang= -Wno-c++11-narrowing
LEVELS= Xye%20level%20-%204corners Xye%20level%20-%20Against%20the%20force \
Xye%20level%20-%20Stop%20that%20cab Xye%20level%20-%20Helping%20Hand \
Xye%20level%20-%20The%20plan Xye%20level%20-%20Controller \
Xye%20level%20-%20At%20once Xye%20level%20-%20Open%20Ended \
Xye%20level%20-%20Sorting Xye%20level%20-%20The%20insider \
Xye%20level%20-%20The%20slow%20speedrun Xye%20levels%20-%20SuperJustin \
Xye%20level%20-%20disturbingarrows Xye%20level%20-%20Duels%20of%20fate \
nuffmagnets Xye%20levels%20-%20Pyramid%20treasure afirflood \
Xye%20level%20-%20Blob%20prison Xye%20levels%20-%20ActionReplay \
Xye%20level%20-%20gravity Xye%20level%20-%20pluzze
LEVELS_XYE= dungeon turnaround chekhov
SKINS= Xye%20skin%20-%20classic%20kye XMASKYESKIN
PORTDOCS= *
DESKTOP_ENTRIES="Xye" "${COMMENT}" "${PORTNAME}" \
"${PORTNAME}" "Game;LogicGame;" false
SUB_FILES= pkg-message
OPTIONS_DEFINE= DOCS SKINS
OPTIONS_DEFAULT= SKINS
SKINS_DESC= Install additional skins
OPTIONS_SUB= yes
.include <bsd.port.options.mk>
post-extract-script:
.for l in ${LEVELS:S/$/.zip/} xmas-xye-2009.zip xye_extra_levels.20121109.zip
@${UNZIP_CMD} -qoj -d ${WRKDIR} ${_DISTDIR}/${l}
.endfor
.if ${PORT_OPTIONS:MSKINS}
. for s in ${SKINS:S/$/.zip/}
@${UNZIP_CMD} -qoj -d ${WRKDIR}/skins ${_DISTDIR}/${s}
. endfor
.endif
post-patch:
@${REINPLACE_CMD} -e 's|docedir = $$(datadir)|docedir = ${PREFIX}/share/doc|' \
${WRKSRC}/Makefile.in
.if ! ${PORT_OPTIONS:MDOCS}
@${REINPLACE_CMD} '/install-data-am:/s/install-doceDATA//' \
${WRKSRC}/Makefile.in
.endif
post-install:
@(cd ${WRKDIR} && ${COPYTREE_SHARE} "*.xye *.txt" ${STAGEDIR}${DATADIR}/levels)
.if ${PORT_OPTIONS:MSKINS}
@(cd ${WRKDIR}/skins && ${COPYTREE_SHARE} . ${STAGEDIR}${DATADIR}/res)
.endif
${RLN} ${STAGEDIR}${DATADIR}/res/detailed_icon.png \
${STAGEDIR}${PREFIX}/share/pixmaps/${PORTNAME}.png
.include <bsd.port.mk>