2000-07-10 04:09:17 +00:00
|
|
|
# New ports collection makefile for: libjparser
|
|
|
|
# Date created: 14 June 2000
|
|
|
|
# Whom: Mario S F Ferreira <lioux@linf.unb.br> et al.
|
|
|
|
#
|
|
|
|
# $FreeBSD$
|
|
|
|
#
|
|
|
|
|
|
|
|
PORTNAME= libjparser
|
|
|
|
PORTVERSION= 1.1.8
|
|
|
|
CATEGORIES= x11-toolkits
|
|
|
|
MASTER_SITES= ftp://ftp.newplanetsoftware.com/pub/glove/source/ \
|
|
|
|
ftp://ftp.newplanetsoftware.com/pub/thx/source/
|
|
|
|
DISTNAME= JParser_source-${PORTVERSION}
|
|
|
|
|
2000-10-03 05:12:49 +00:00
|
|
|
MAINTAINER= lioux@FreeBSD.org
|
2000-07-10 04:09:17 +00:00
|
|
|
|
2000-10-03 05:00:35 +00:00
|
|
|
BUILD_DEPENDS= ${NONEXISTENT}:${JXPORT}:configure \
|
2000-07-10 04:09:17 +00:00
|
|
|
makemake:${JXPORT}
|
|
|
|
LIB_DEPENDS= jx-1_5_3.1:${JXPORT}
|
|
|
|
|
|
|
|
WRKSRC= ${WRKDIR}/JX-1.5.3
|
|
|
|
|
|
|
|
USE_X_PREFIX= yes
|
|
|
|
USE_GMAKE= yes
|
|
|
|
MAKE_ARGS= CC="${CC}" CXX="${CXX}" \
|
|
|
|
CFLAGS="${CFLAGS}" CXXFLAGS="${CXXFLAGS}"
|
|
|
|
MAKE_ENV= JX_INSTALL_ROOT="${PREFIX}/bin" \
|
|
|
|
JX_LIB_ROOT="${PREFIX}/lib"
|
|
|
|
PLIST_SUB= PORTNAME="${PORTNAME}" \
|
|
|
|
LIBNUMBER="${LIBNUMBER}" \
|
|
|
|
LIBVERSION="${LIBVERSION}" \
|
|
|
|
EXTRALIBFILES_MAKE_FILES="${EXTRALIBFILES_MAKE_FILES}" \
|
|
|
|
INCLUDEDIR="${INCLUDEDIR}"
|
2000-10-03 05:00:35 +00:00
|
|
|
INSTALLS_SHLIB= yes
|
2000-07-10 04:09:17 +00:00
|
|
|
|
|
|
|
# Make environment
|
|
|
|
PORTINCLUDES= -I${X11BASE}/include/jcore -I${X11BASE}/include/jx \
|
|
|
|
-I${X11BASE}/share/jx
|
|
|
|
|
|
|
|
# Installs dir with proper permissions
|
|
|
|
INSTALL_DATA_DIR= ${INSTALL} -d -o ${SHAREOWN} -g ${SHAREGRP} -m 755
|
|
|
|
# New version number
|
|
|
|
LIBVERSION= 1_1_8
|
|
|
|
# the libraries
|
|
|
|
LIBFILES= ${PORTNAME}-${LIBVERSION}.a ${PORTNAME}-${LIBVERSION}.so
|
|
|
|
# header files
|
|
|
|
INCLUDEDIR= jparser
|
|
|
|
# documentation
|
|
|
|
DOCDIR_PREFIX= ${PREFIX}/share/doc/jx
|
|
|
|
DOCDIRS= ${PORTNAME}
|
|
|
|
DOCDIRFILES= LICENSE README
|
|
|
|
# additional configuration and header files
|
|
|
|
EXTRALIB_PREFIX= ${PREFIX}/lib/jx
|
|
|
|
EXTRALIBDIRS= lib make
|
|
|
|
EXTRALIBFILES_MAKE_WRKSRC= include/make
|
|
|
|
EXTRALIBFILES_MAKE_FILES= jparser_constants
|
2000-10-03 05:00:35 +00:00
|
|
|
|
|
|
|
.include <bsd.port.pre.mk>
|
|
|
|
|
2000-07-10 04:09:17 +00:00
|
|
|
# main jx distribution port wrksrc
|
|
|
|
JXPORT= ${PORTSDIR}/x11-toolkits/jx
|
2000-10-03 05:00:35 +00:00
|
|
|
JXPORT_WRKSRC!= cd ${JXPORT} && ${MAKE} -V WRKSRC
|
2000-07-10 04:09:17 +00:00
|
|
|
# main jx distribution files needed for building
|
|
|
|
COPY_JXDIRS= include
|
|
|
|
COPY_JXFILES= Makefile
|
|
|
|
|
|
|
|
.if ${OSVERSION} >= 300000
|
|
|
|
ALL_TARGET= freebsd3.x
|
|
|
|
LIBNUMBER= 1
|
|
|
|
.else
|
|
|
|
ALL_TARGET= freebsd2.x
|
|
|
|
LIBNUMBER= 1.1
|
|
|
|
.endif
|
|
|
|
|
|
|
|
.if defined(NOPORTDOCS)
|
|
|
|
PLIST_SUB+= PORTDOCS:="@comment "
|
|
|
|
.else
|
|
|
|
PLIST_SUB+= PORTDOCS:=
|
|
|
|
.endif # !defined(NOPORTDOCS)
|
|
|
|
|
|
|
|
post-extract:
|
|
|
|
.for i in ${COPY_JXDIRS}
|
|
|
|
@${CP} -Rp ${JXPORT_WRKSRC}/${i} ${WRKSRC}
|
|
|
|
.endfor
|
|
|
|
.for i in ${COPY_JXFILES}
|
|
|
|
@${CP} -p ${JXPORT_WRKSRC}/${i} ${WRKSRC}
|
|
|
|
.endfor
|
|
|
|
|
|
|
|
post-patch:
|
|
|
|
@${ECHO} "SEARCHDIRS += ${PORTINCLUDES}" >> \
|
|
|
|
${WRKSRC}/${EXTRALIBFILES_MAKE_WRKSRC}/jx_constants
|
|
|
|
|
|
|
|
post-build:
|
|
|
|
@cd ${WRKSRC}/${PORTNAME}; ${SETENV} ${MAKE_ENV} makemake; \
|
|
|
|
${SETENV} ${MAKE_ENV} ${GMAKE} \
|
|
|
|
${MAKE_FLAGS} ${MAKEFILE} ${MAKE_ARGS}
|
|
|
|
|
|
|
|
do-install:
|
|
|
|
.if !defined(NOPORTDOCS)
|
|
|
|
# Install all documentation
|
|
|
|
.for i in ${DOCDIRS}
|
|
|
|
@for j in ${DOCDIRFILES} ; \
|
|
|
|
do \
|
|
|
|
if [ -f ${WRKSRC}/programs/${i}/$${j} ]; \
|
|
|
|
then \
|
|
|
|
${INSTALL_DATA} ${WRKSRC}/programs/${i}/$${j} \
|
|
|
|
${DOCDIR_PREFIX}/$${j}_${i} ; \
|
|
|
|
elif [ -f ${WRKSRC}/${i}/$${j} ]; \
|
|
|
|
then \
|
|
|
|
${INSTALL_DATA} ${WRKSRC}/${i}/$${j} \
|
|
|
|
${DOCDIR_PREFIX}/$${j}_${i} ; \
|
|
|
|
fi ; \
|
|
|
|
done
|
|
|
|
.endfor
|
|
|
|
.endif # !defined(NOPORTDOCS)
|
|
|
|
# Install all header files
|
|
|
|
.for i in ${INCLUDEDIR}
|
|
|
|
@${INSTALL_DATA_DIR} ${PREFIX}/include/${i} ; \
|
|
|
|
for j in ${WRKSRC}/include/${i}/*.*h \
|
|
|
|
${WRKSRC}/include/${i}/*.tmpl \
|
|
|
|
${WRKSRC}/include/${i}/*.tmpls ; \
|
|
|
|
do \
|
|
|
|
if [ -f $${j} ]; \
|
|
|
|
then \
|
|
|
|
${INSTALL_DATA} $${j} ${PREFIX}/include/${i}/ ; \
|
|
|
|
fi ; \
|
|
|
|
done
|
|
|
|
.endfor
|
|
|
|
# Install all libraries
|
|
|
|
.for i in ${LIBFILES}
|
|
|
|
@${INSTALL_PROGRAM} ${WRKSRC}/lib/${i} ${PREFIX}/lib
|
|
|
|
.endfor
|
|
|
|
# Install additional library files
|
|
|
|
.for i in ${EXTRALIBDIRS}
|
|
|
|
@${INSTALL_DATA_DIR} ${EXTRALIB_PREFIX}/${i}
|
|
|
|
.endfor
|
|
|
|
.for i in ${EXTRALIBFILES_MAKE_FILES}
|
|
|
|
@${INSTALL_DATA} ${WRKSRC}/${EXTRALIBFILES_MAKE_WRKSRC}/${i} \
|
|
|
|
${EXTRALIB_PREFIX}/make/${i}
|
|
|
|
.endfor
|
|
|
|
|
|
|
|
post-install:
|
|
|
|
@${LN} -sf ${PORTNAME}-${LIBVERSION}.so \
|
|
|
|
${PREFIX}/lib/${PORTNAME}-${LIBVERSION}.so.${LIBNUMBER}
|
|
|
|
.for i in ${LIBFILES}
|
|
|
|
@${LN} -sf ../../${i} ${EXTRALIB_PREFIX}/lib/${i}
|
|
|
|
.endfor
|
|
|
|
|
|
|
|
.include <bsd.port.post.mk>
|