96167b2ecd
Personal/recreational applications, not aligned with broad server focus
118 lines
2.8 KiB
Makefile
118 lines
2.8 KiB
Makefile
# Shared by timidity++ interface ports
|
|
|
|
BUILD_DEPENDS+= libarc>0:archivers/libarc
|
|
RUN_DEPENDS+= timidity++>0:audio/timidity++
|
|
|
|
SLAVEDIRS= audio/timidity++-emacs \
|
|
audio/timidity++-tcltk \
|
|
audio/timidity++-xskin
|
|
|
|
INTERFACE= ${PKGNAMESUFFIX:S/^-//}
|
|
|
|
DESCR= ${.CURDIR}/pkg-descr
|
|
|
|
.if exists(${.CURDIR}/pkg-plist)
|
|
PLIST= ${.CURDIR}/pkg-plist
|
|
.else
|
|
PLIST= ${NONEXISTENT}
|
|
.endif
|
|
|
|
.if exists(${.CURDIR}/pkg-message)
|
|
PKGMESSAGE= ${.CURDIR}/pkg-message
|
|
.else
|
|
PKGMESSAGE= ${NONEXISTENT}
|
|
.endif
|
|
|
|
BUILD_WRKSRC= ${WRKSRC}/interface
|
|
INSTALL_WRKSRC= ${WRKSRC}/interface
|
|
|
|
CONFIGURE_ARGS+=--enable-dynamic=${INTERFACE}
|
|
|
|
# interface section
|
|
|
|
.if ${INTERFACE} == "emacs"
|
|
CONFIGURE_ARGS+=--with-lispdir=${PREFIX}/share/emacs/site-lisp
|
|
.endif
|
|
|
|
.if ${INTERFACE} == "tcltk"
|
|
LINK= tkmidi
|
|
|
|
.if defined(JAPANESE)
|
|
LIB_DEPENDS+= libtk80jp.so:japanese/tk80
|
|
CONFIGURE_ARGS+=\
|
|
--with-tcl-includes=${LOCALBASE}/include/tcl8.0jp \
|
|
--with-tk-includes=${LOCALBASE}/include/tk8.0jp \
|
|
--with-tcl-libs=${LOCALBASE}/lib \
|
|
--with-tk-libs=${LOCALBASE}/lib
|
|
WISH= ${LOCALBASE}/bin/wish8.0jp
|
|
.else
|
|
USES+= tk
|
|
CONFIGURE_ARGS+=\
|
|
--with-tcl-includes=${TCL_INCLUDEDIR} \
|
|
--with-tk-includes=${TK_INCLUDEDIR} \
|
|
--with-tcl-libs=${LOCALBASE}/lib \
|
|
--with-tk-libs=${LOCALBASE}/lib
|
|
.endif
|
|
|
|
USES+= shebangfix xorg
|
|
SHEBANG_FILES= interface/tkmidity.ptcl interface/tkpanel.tcl
|
|
SHEBANG_LANG= wish
|
|
wish_OLD_CMD= /usr/bin/wish
|
|
wish_CMD= ${WISH}
|
|
USE_XORG= x11
|
|
CONFIGURE_ENV+= WISH="${WISH}"
|
|
|
|
LDFLAGS+= -L${LOCALBASE}/lib -lX11
|
|
|
|
DESKTOP_ENTRIES="TkMidi" "" "" "${LINK}" "AudioVideo;Audio;Midi;" ""
|
|
.endif
|
|
|
|
.if ${INTERFACE} == "xskin"
|
|
LINK= xskinmidi
|
|
|
|
USES+= xorg
|
|
USE_XORG= x11
|
|
|
|
DESKTOP_ENTRIES="XSkinMidi" "" "" "${LINK}" "AudioVideo;Audio;Midi;" ""
|
|
.endif
|
|
|
|
post-extract:
|
|
@${RM} ${WRKSRC}/libarc/*.h
|
|
@${RM} ${WRKSRC}/utils/mblock.h
|
|
|
|
post-patch:
|
|
.if ${INTERFACE} == "tcltk"
|
|
.if defined(JAPANESE)
|
|
@${REINPLACE_CMD} -e \
|
|
's|in tcl.*;|in tcl80jp;| ; \
|
|
s|in tk.*;|in tk80jp;|' ${WRKSRC}/configure
|
|
.else
|
|
@${REINPLACE_CMD} -e \
|
|
's|in tcl.*;|in tcl${TCL_VER:S|.||};| ; \
|
|
s|in tk.*;|in tk${TK_VER:S|.||};|' ${WRKSRC}/configure
|
|
.endif
|
|
.endif
|
|
|
|
post-install:
|
|
.if ${INTERFACE} == "tcltk"
|
|
@${MKDIR} ${STAGEDIR}${DOCSDIR}
|
|
(cd ${WRKSRC}/doc/C && ${INSTALL_DATA} README.tk \
|
|
${STAGEDIR}${DOCSDIR})
|
|
@${MKDIR} ${STAGEDIR}${PREFIX}/share/doc/ja/${PORTNAME}
|
|
(cd ${WRKSRC}/doc/ja_JP.eucJP && ${INSTALL_DATA} README.tk \
|
|
${STAGEDIR}${PREFIX}/share/doc/ja/${PORTNAME})
|
|
.endif
|
|
#
|
|
.if ${INTERFACE} == "xskin"
|
|
@${MKDIR} ${STAGEDIR}${DOCSDIR}
|
|
(cd ${WRKSRC}/doc/C && ${INSTALL_DATA} README.xskin \
|
|
${STAGEDIR}${DOCSDIR})
|
|
@${MKDIR} ${STAGEDIR}${PREFIX}/share/doc/ja/${PORTNAME}
|
|
(cd ${WRKSRC}/doc/ja_JP.eucJP && ${INSTALL_DATA} README.xskin \
|
|
${STAGEDIR}${PREFIX}/share/doc/ja/${PORTNAME})
|
|
.endif
|
|
#
|
|
.if defined(LINK)
|
|
${LN} -sf timidity ${STAGEDIR}${PREFIX}/bin/${LINK}
|
|
.endif
|