2012-11-09 20:06:36 +00:00
|
|
|
# Created by: Thomas Gellekum <tg@FreeBSD.org>
|
1999-08-25 06:06:33 +00:00
|
|
|
# $FreeBSD$
|
1999-05-27 13:53:03 +00:00
|
|
|
|
2000-04-14 12:28:40 +00:00
|
|
|
PORTNAME= rocksndiamonds
|
2010-07-12 07:38:51 +00:00
|
|
|
PORTVERSION= 3.3.0.1
|
2013-01-23 15:00:18 +00:00
|
|
|
PORTREVISION= 3
|
1999-05-27 13:53:03 +00:00
|
|
|
CATEGORIES= games
|
2013-03-22 22:22:00 +00:00
|
|
|
MASTER_SITES= http://www.artsoft.org/RELEASES/unix/rocksndiamonds/:game \
|
|
|
|
SF/${PORTNAME}.mirror/:game \
|
|
|
|
http://www.jb-line.de/rnd/:rnd \
|
2012-12-28 12:46:55 +00:00
|
|
|
http://www.artsoft.org/RELEASES/rocksndiamonds/levels/:levels \
|
|
|
|
http://www.bd-fans.com/Files/RnD/Levels/ \
|
|
|
|
SF/nemysisfreebsdp/${PORTNAME}/:icons
|
|
|
|
# Please contact the MAINTAINER if a Level is missing
|
2013-03-22 22:22:00 +00:00
|
|
|
DISTFILES= ${PORTNAME}-${DISTVERSION}${EXTRACT_SUFX}:game \
|
|
|
|
rnd_jue-3.3.0.0.tar.gz:rnd \
|
2012-12-28 12:46:55 +00:00
|
|
|
Sokoban-1.0.0.zip:levels \
|
|
|
|
Contributions-1.2.0.zip:levels \
|
|
|
|
${LEVELS_BD_FANS:S/$/.zip/} \
|
|
|
|
Gavin_Davidson_2006.zip \
|
|
|
|
Trucky_Cargos_v0.1.zip \
|
|
|
|
Walpurgis_Collection.zip \
|
|
|
|
${PORTNAME}_icons.zip:icons
|
|
|
|
DIST_SUBDIR= ${PORTNAME}
|
|
|
|
EXTRACT_ONLY= ${PORTNAME}-${DISTVERSION}${EXTRACT_SUFX} \
|
|
|
|
rnd_jue-3.3.0.0.tar.gz \
|
|
|
|
${PORTNAME}_icons.zip
|
2000-11-19 15:21:39 +00:00
|
|
|
|
2012-12-28 12:46:55 +00:00
|
|
|
MAINTAINER= nemysis@gmx.ch
|
2003-02-21 12:06:51 +00:00
|
|
|
COMMENT= Colorful Boulderdash'n'Emerald Mine'n'Sokoban'n'Stuff
|
1999-05-27 13:53:03 +00:00
|
|
|
|
2012-11-09 20:06:36 +00:00
|
|
|
LICENSE= GPLv2
|
|
|
|
|
2012-12-28 12:46:55 +00:00
|
|
|
LIB_DEPENDS= smpeg:${PORTSDIR}/multimedia/smpeg
|
2013-02-06 09:38:11 +00:00
|
|
|
EXTRACT_DEPENDS=${UNZIP_CMD}:${PORTSDIR}/archivers/unzip
|
2012-11-09 20:06:36 +00:00
|
|
|
|
2012-12-28 12:46:55 +00:00
|
|
|
USE_ICONV= yes
|
|
|
|
USE_SDL= image mixer net sdl
|
2004-04-09 18:24:05 +00:00
|
|
|
USE_GMAKE= yes
|
2006-01-20 16:43:13 +00:00
|
|
|
MAKE_ARGS= CC="${CC}" MAKE="${GMAKE}" OPTIONS="${CFLAGS}" \
|
2012-12-28 12:46:55 +00:00
|
|
|
RO_GAME_DIR="${DATADIR}" \
|
- Remove unneeded dependency from gtk12/gtk20 [1]
- Remove USE_XLIB/USE_X_PREFIX/USE_XPM in favor of USE_XORG
- Remove X11BASE support in favor of LOCALBASE or PREFIX
- Use USE_LDCONFIG instead of INSTALLS_SHLIB
- Remove unneeded USE_GCC 3.4+
Thanks to all Helpers:
Dmitry Marakasov, Chess Griffin, beech@, dinoex, rafan, gahr,
ehaupt, nox, itetcu, flz, pav
PR: 116263
Tested on: pointyhat
Approved by: portmgr (pav)
2008-04-19 17:56:05 +00:00
|
|
|
X11_PATH="${LOCALBASE}"
|
2012-12-28 12:46:55 +00:00
|
|
|
ALL_TARGET= sdl
|
2012-11-09 20:06:36 +00:00
|
|
|
MAKE_JOBS_SAFE= yes
|
1999-05-27 13:53:03 +00:00
|
|
|
|
2012-12-28 12:46:55 +00:00
|
|
|
SUB_FILES= pkg-message
|
|
|
|
|
|
|
|
LEVELS_ARTSOFT= rnd_jue Sokoban Contributions
|
|
|
|
|
|
|
|
LEVELS_BD_FANS= Bug_Hunter Colourful_World Earth_Shaker_Collection \
|
|
|
|
Glasses Love_Pac Maniac_Mines Negundo_Dash Pipemania Rockfighter \
|
|
|
|
Step_Puzzles Super_Jetset_Willy_Bros_3 Through_the_Ages \
|
|
|
|
rnd_the_h_world
|
|
|
|
|
2004-04-09 18:24:05 +00:00
|
|
|
MAN1= rocksndiamonds.1
|
1999-05-27 13:53:03 +00:00
|
|
|
|
2012-12-28 12:46:55 +00:00
|
|
|
PORTDOCS= *
|
|
|
|
|
|
|
|
DOCSRCDIR1= ${WRKSRC}
|
|
|
|
DOC_FILES1= CREDITS ChangeLog README
|
|
|
|
|
|
|
|
DOCSRCDIR2= ${WRKSRC}/docs/elements
|
|
|
|
DOCSDIR2= ${DOCSDIR}/docs/elements
|
|
|
|
DOC_FILES2= *.txt
|
|
|
|
|
|
|
|
INSTALLS_ICONS= yes
|
|
|
|
ICON_SIZES= 32x32 48x48 64x64 72x72 96x96
|
|
|
|
|
|
|
|
DESKTOP_ENTRIES="Rocks'n'Diamonds" "${COMMENT}" "${PORTNAME}" \
|
|
|
|
"${PORTNAME}" "Game;ArcadeGame;" false
|
|
|
|
|
2012-11-09 20:06:36 +00:00
|
|
|
.include <bsd.port.options.mk>
|
|
|
|
|
2012-12-28 12:46:55 +00:00
|
|
|
post-extract-script:
|
|
|
|
${MKDIR} ${WRKDIR}/${PORTNAME}
|
|
|
|
@(cd ${WRKDIR}/rnd_jue* && ${COPYTREE_SHARE} levels/rnd_jue ${WRKDIR}/${PORTNAME})
|
|
|
|
@(cd ${WRKDIR}/${PORTNAME}/levels ; ${MV} rnd_jue .. ; cd .. ; ${RMDIR} levels)
|
|
|
|
.for l in Sokoban-1.0.0.zip Contributions-1.2.0.zip
|
|
|
|
@${UNZIP_CMD} -qo -d ${WRKDIR}/${PORTNAME} ${DISTDIR}/${DIST_SUBDIR}/${l}
|
|
|
|
.endfor
|
|
|
|
|
|
|
|
.for l in ${LEVELS_BD_FANS:S/$/.zip/} Gavin_Davidson_2006.zip Trucky_Cargos_v0.1.zip Walpurgis_Collection.zip
|
|
|
|
@${UNZIP_CMD} -qo -d ${WRKDIR}/${PORTNAME} ${DISTDIR}/${DIST_SUBDIR}/${l}
|
|
|
|
.endfor
|
|
|
|
@${RM} -f ${WRKDIR}/${PORTNAME}/Readme.txt
|
2001-02-14 22:22:15 +00:00
|
|
|
|
2004-04-09 18:24:05 +00:00
|
|
|
post-patch:
|
2012-12-28 12:46:55 +00:00
|
|
|
@${REINPLACE_CMD} \
|
|
|
|
-e 's|sdl-config|$${SDL_CONFIG}|g' ${WRKSRC}/src/Makefile
|
|
|
|
@${REINPLACE_CMD} \
|
|
|
|
-e 's|machine/soundcard.h|sys/soundcard.h|' ${WRKSRC}/src/libgame/sound.c
|
|
|
|
@${REINPLACE_CMD} \
|
|
|
|
-e 's|machine/joystick.h|sys/joystick.h|' ${WRKSRC}/src/libgame/joystick.c
|
2004-04-09 18:24:05 +00:00
|
|
|
|
1999-05-27 13:53:03 +00:00
|
|
|
do-install:
|
2012-12-28 12:46:55 +00:00
|
|
|
${INSTALL_PROGRAM} ${WRKSRC}/${PORTNAME} ${PREFIX}/bin
|
|
|
|
${INSTALL_MAN} ${WRKSRC}/${PORTNAME}.1 ${MAN1PREFIX}/man/man1
|
|
|
|
|
|
|
|
.for dir in graphics levels music sounds
|
2009-06-26 14:48:57 +00:00
|
|
|
@(cd ${WRKSRC} && ${COPYTREE_SHARE} ${dir} ${DATADIR})
|
|
|
|
.endfor
|
2012-12-28 12:46:55 +00:00
|
|
|
@cd ${WRKDIR}/${PORTNAME} && ${COPYTREE_SHARE} \* ${DATADIR}/levels
|
|
|
|
|
|
|
|
post-install:
|
|
|
|
.for s in ${ICON_SIZES}
|
|
|
|
${MKDIR} ${PREFIX}/share/icons/hicolor/${s}/apps
|
|
|
|
${INSTALL_DATA} ${WRKDIR}/${PORTNAME}_${s}.png \
|
|
|
|
${PREFIX}/share/icons/hicolor/${s}/apps/${PORTNAME}.png
|
1999-05-27 13:53:03 +00:00
|
|
|
.endfor
|
2012-12-28 12:46:55 +00:00
|
|
|
${LN} -sf ${PREFIX}/share/icons/hicolor/48x48/apps/${PORTNAME}.png \
|
|
|
|
${PREFIX}/share/pixmaps
|
|
|
|
|
|
|
|
.if ${PORT_OPTIONS:MDOCS}
|
|
|
|
${MKDIR} ${DOCSDIR}
|
|
|
|
${INSTALL_DATA} ${DOC_FILES1:S|^|${DOCSRCDIR1}/|} ${DOCSDIR}
|
|
|
|
${MKDIR} ${DOCSDIR2}
|
|
|
|
${INSTALL_DATA} ${DOC_FILES2:S|^|${DOCSRCDIR2}/|} ${DOCSDIR2}
|
1999-05-27 13:53:03 +00:00
|
|
|
.endif
|
|
|
|
|
2012-12-28 12:46:55 +00:00
|
|
|
# Dynamically generate part of the PLIST, because the Levels are large
|
|
|
|
.for l in ${LEVELS_ARTSOFT}
|
|
|
|
@${FIND} ${DATADIR}/levels/${l}/ ! -type d | ${SED} 's|^${PREFIX}/||' >> ${TMPPLIST}
|
|
|
|
@${FIND} -ds ${DATADIR}/levels/${l}/ -type d | \
|
|
|
|
${SED} -E -e 's,(.*),@unexec ${RMDIR} "\1" 2>/dev/null || true,' >> ${TMPPLIST}
|
|
|
|
.endfor
|
|
|
|
|
|
|
|
.for l in ${LEVELS_BD_FANS} "Gavin Davidson 2006" Trucky_Cargos "Walpurgis Collection"
|
|
|
|
@${FIND} ${DATADIR}/levels/${l}/ ! -type d | ${SED} 's|^${PREFIX}/||' >> ${TMPPLIST}
|
|
|
|
@${FIND} -ds ${DATADIR}/levels/${l}/ -type d | \
|
|
|
|
${SED} -E -e 's,(.*),@unexec ${RMDIR} "\1" 2>/dev/null || true,' >> ${TMPPLIST}
|
|
|
|
.endfor
|
|
|
|
@${ECHO} "@unexec ${RMDIR} \"${DATADIR}/levels\" 2>/dev/null || true" >> ${TMPPLIST}
|
|
|
|
@${ECHO} "@unexec ${RMDIR} \"${DATADIR}\" 2>/dev/null || true" >> ${TMPPLIST}
|
|
|
|
|
|
|
|
@${ECHO_CMD}
|
|
|
|
@${CAT} ${PKGMESSAGE}
|
|
|
|
@${ECHO_CMD}
|
|
|
|
|
1999-05-27 13:53:03 +00:00
|
|
|
.include <bsd.port.mk>
|