Line # Revision Author
1 8 ahitrov@rambler.ru ##############################################################################
2 209 ahitrov # $HeadURL: svn+ssh://svn@vcs.dev.rambler.ru/Contenido/trunk/ports/all/XML-Parser-encodings/GNUmakefile $
3 # $Id: GNUmakefile 1654 2012-04-17 14:56:57Z abavykin $
4 8 ahitrov@rambler.ru ###############################################################################
5
6 PORTVERSION = 0.01
7 PERL_MAKEMAKER = yes
8 PORT_DEPENDS = XML-Encoding
9
10 WRKSRC = ${WRKDIR}/${PORTNAME}-${PORTVERSION}
11
12 do-fetch: ;
13 do-extract: ;
14 @mkdir -p ${WRKSRC}
15
16 do-configure: ;
17 do-build:
18 @export ${BUILD_ENV}; for ENC in *.txt; do \
19 ENC_NAME=`echo $${ENC} | perl -pe 's/\.txt$$//'`; \
20 209 ahitrov PATH=/usr/local/bin:${PREFIX}/bin make_encmap $${ENC_NAME} $${ENC_NAME}.txt | \
21 8 ahitrov@rambler.ru ${PERL} -pi -e "s/(?<=^<encmap name='$${ENC_NAME}')()(?=>)/ expat='yes'/;" > ${WRKSRC}/$${ENC_NAME}.xml;\
22 209 ahitrov PATH=/usr/local/bin:${PREFIX}/bin compile_encoding -o ${WRKSRC}/$${ENC_NAME}.enc ${WRKSRC}/$${ENC_NAME}.xml; \
23 8 ahitrov@rambler.ru done
24
25 do-install:
26 @mkdir -p ${PREFIX}/lib/perl5/site_perl/${PERL_VER}/${PERL_ARCH}/XML/Parser/Encodings/
27 @cp ${WRKSRC}/*.enc ${PREFIX}/lib/perl5/site_perl/${PERL_VER}/${PERL_ARCH}/XML/Parser/Encodings/
28
29 include ../../etc/ports.mk