# this is to be included by vdr plugin ports # # $FreeBSD$ BUILD_DEPENDS+= ${LOCALBASE}/include/linux/dvb/frontend.h:multimedia/v4l_compat BUILD_DEPENDS+= vdr:multimedia/vdr RUN_DEPENDS+= vdr:multimedia/vdr APIVERSION= 1.7.29 DIST_SUBDIR= vdr PATCH_SUBDIR= vdr USES+= gettext gmake VDRDIR= ${LOCALBASE}/include/vdr VDRINCDIR= ${LOCALBASE}/include USE_CSTD?= gnu89 MAKE_ARGS+= CC="${CC}" MAKE_ARGS+= CXX="${CXX}" MAKE_ARGS+= DVBDIR=${LOCALBASE}/include MAKE_ARGS+= VDRDIR=${VDRDIR} MAKE_ARGS+= VDR_USER=${VDR_USER} MAKE_ARGS+= INSTALL_PROGRAM="${INSTALL_PROGRAM}" MAKE_ARGS+= OSTYPE=FreeBSD MAKE_ARGS+= PREFIX=${PREFIX} PLUGIN?= ${PORTNAME:S/^vdr-plugin-//} CONFIGURE_ENV+= LOCALBASE=${LOCALBASE} MAKE_ENV+= LOCALBASE=${LOCALBASE} VDR_USER= vdr VDR_GROUP= vdr PLIST_SUB= VDR_USER=${VDR_USER} PLIST_SUB+= VDR_GROUP=${VDR_GROUP} PLIST_SUB+= APIVERSION=${APIVERSION} .include .if ${PORT_OPTIONS:MNLS} PLIST_SUB+= NLS="" .else PLIST_SUB+= NLS="@comment " .endif localeplist: @${FIND} ${WRKDIR}/locale -type f -print |${SED} 's|^.*locale/|%%NLS%%share/locale/|' post-patch-plugin: @${MKDIR} ${WRKDIR}/lib ${WRKDIR}/locale @${REINPLACE_CMD} -e 's/^\(LIBDIR[[:space:]]*\)[?]*\(=[[:space:]]*\).*/\1\2..\/lib/;' \ -e 's/^\(LOCALEDIR[[:space:]]*\)[?]*\(=[[:space:]]*\).*/\1\2..\/locale/;' \ -e 's/^\(VDRDIR[[:space:]]*\)[?]*\(=[[:space:]]*\).*/\1\2'"${VDRDIR:S-/-\\\\/-g}/;" \ -e 's/^\(VDRINCDIR[[:space:]]*\)[?]*\(=[[:space:]]*\).*/\1\2'"${VDRINCDIR:S-/-\\\\/-g}/;" \ -e 's/^\(BINDIR[[:space:]]*\)[?]*\(=[[:space:]]*\).*/\1\2'"${PREFIX:S-/-\\\\/-g}\/bin/;" \ -e '/^MAKEDEP.*-MM/s/-MG[[:space:]]*$$/# -MG/' \ ${WRKSRC}/Makefile ${VDR_PLUGIN_MAKEFILES} post-install-pluginlocales: .if ${PORT_OPTIONS:MNLS} @(cd ${WRKDIR} && ${COPYTREE_SHARE} locale ${STAGEDIR}${PREFIX}/share/) .endif