openbsd-ports/x11/xscreensaver/Makefile
2013-03-11 11:35:43 +00:00

80 lines
2.5 KiB
Makefile

# $OpenBSD: Makefile,v 1.77 2013/03/11 11:46:19 espie Exp $
COMMENT= screen saver and locker for the X Window System
DISTNAME= xscreensaver-5.20
CATEGORIES= x11
HOMEPAGE= http://www.jwz.org/xscreensaver/
# BSD
PERMIT_PACKAGE_CDROM= Yes
WANTLIB += GL GLU ICE SM X11 Xcomposite Xcursor Xdamage Xext Xfixes
WANTLIB += Xi Xinerama Xmu Xpm Xrandr Xrender Xt Xxf86misc Xxf86vm
WANTLIB += atk-1.0 c cairo expat fontconfig freetype gdk-x11-2.0
WANTLIB += gdk_pixbuf-2.0 gdk_pixbuf_xlib-2.0 gio-2.0 glade-2.0
WANTLIB += gle glib-2.0 gmodule-2.0 gobject-2.0 gtk-x11-2.0 jpeg
WANTLIB += m pango-1.0 pangocairo-1.0 pangoft2-1.0 pixman-1 png
WANTLIB += pthread pthread-stubs util xcb xcb-render xcb-shm xml2
WANTLIB += z
MASTER_SITES= ${HOMEPAGE}
MODULES= devel/gettext \
textproc/intltool
RUN_DEPENDS= devel/desktop-file-utils
LIB_DEPENDS= devel/libglade2 \
graphics/gdk-pixbuf2 \
graphics/gle
# ${FILESDIR}/migrate-xscreensaver-config.sh needs xsltproc
BUILD_DEPENDS += textproc/libxslt
# see pre-configure
BUILD_DEPENDS += devel/xdg-utils
RUN_DEPENDS += devel/xdg-utils
USE_GMAKE= Yes
USE_GROFF= Yes
NO_TEST= Yes
CONFIGURE_STYLE= gnu
CONFIGURE_ARGS= --with-hackdir="${PREFIX}/libexec/xscreensaver" \
--with-x-app-defaults="${PREFIX}/lib/X11/app-defaults" \
--without-pam
CONFIGURE_ENV= CPPFLAGS="-I${LOCALBASE}/include" \
CFLAGS="${CFLAGS} -I${LOCALBASE}/include" \
LDFLAGS="-L${LOCALBASE}/lib -liconv -lintl"
# Create desktop files from xscreensaver xml files for use by
# freedesktop compliant screensavers.
post-extract:
cp ${FILESDIR}/migrate-xscreensaver-config.sh ${WRKSRC}/hacks/config
cp ${FILESDIR}/xscreensaver-config.xsl ${WRKSRC}/hacks/config
pre-configure:
perl -pi -e 's,gnome-open,xdg-open,g' ${WRKSRC}/configure
post-install:
# remove conflict on games/circuit, misc/deco
for i in circuit deco ; do \
mv ${PREFIX}/man/man6/$${i}.6 ${PREFIX}/man/man6/x$${i}.6 ; \
mv ${PREFIX}/libexec/xscreensaver/$${i} \
${PREFIX}/libexec/xscreensaver/x$${i} && \
mv ${PREFIX}/share/xscreensaver/config/$${i}.xml \
${PREFIX}/share/xscreensaver/config/x$${i}.xml && \
mv ${WRKSRC}/hacks/config/$${i}.xml \
${WRKSRC}/hacks/config/x$${i}.xml ; done
cd ${WRKSRC}/hacks/config && \
for i in ${WRKSRC}/hacks/config/*.xml; do \
/bin/sh migrate-xscreensaver-config.sh $${i} ; done
${INSTALL_DATA_DIR} ${PREFIX}/share/applications/screensavers/
${INSTALL_DATA} ${WRKSRC}/hacks/config/*.desktop \
${PREFIX}/share/applications/screensavers/
.include <bsd.port.mk>