diff --git a/devel/colorer/Makefile b/devel/colorer/Makefile index ab9fdb7bb111..c86e3cbd3c99 100644 --- a/devel/colorer/Makefile +++ b/devel/colorer/Makefile @@ -16,8 +16,7 @@ DISTNAME= Colorer-take5.beta2 MAINTAINER= ports@FreeBSD.org COMMENT= A syntax highlighting and text parsing library -BUILD_DEPENDS= ${ANT}:${PORTSDIR}/devel/apache-ant \ - fop:${PORTSDIR}/textproc/fop \ +BUILD_DEPENDS= fop:${PORTSDIR}/textproc/fop \ ${LOCALBASE}/share/xsl/docbook/catalog:${PORTSDIR}/textproc/docbook-xsl \ ${LOCALBASE}/share/docbook-xsd/docbook.xsd:${PORTSDIR}/textproc/docbook-xsd \ ${LOCALBASE}/share/mathml-xsd/mathml2.xsd:${PORTSDIR}/textproc/mathml-xsd \ @@ -26,25 +25,18 @@ BUILD_DEPENDS= ${ANT}:${PORTSDIR}/devel/apache-ant \ USE_BZIP2= yes USE_REINPLACE= yes USE_JAVA= 1.4+ +USE_ANT= yes NEED_JAVAC= yes -ANT?= ${LOCALBASE}/bin/ant -ANT_TARGET?= library-linux +ALL_TARGET?= library-linux USE_GMAKE= yes PLIST_FILES= bin/colorer lib/libcolorer.so -.include - -.if ${OSVERSION} >= 502126 -BROKEN= "Does not compile on FreeBSD >= 5.x" -.endif - -do-build: - @(cd ${WRKSRC} && \ - ${SETENV} JAVA_HOME=${JAVA_HOME} ${ANT} ${ANT_TARGET} ; \ - cd distr/Colorer-take5-linux.beta2 ; \ - ${REINPLACE_CMD} -e "s|make -C|${GMAKE} -C|" Makefile.in ; \ - ${CHMOD} +x configure && ${SETENV} ${CONFIGURE_ENV} ./configure ; \ - ${GMAKE} ${PORTNAME} \ +post-build: + @(cd ${WRKSRC}/distr/Colorer-take5-linux.beta2 ; \ + ${REINPLACE_CMD} -e "s|make -C|${GMAKE} -C|" Makefile.in ; \ + ${REINPLACE_CMD} -e "s|-O3|${CFLAGS}|" src/shared/makefile.colorer.gcc ; \ + ${CHMOD} +x configure && ${SETENV} ${CONFIGURE_ENV} ./configure ; \ + ${GMAKE} ${PORTNAME} \ ) do-install: @@ -82,4 +74,4 @@ do-install: ${SED} 's,^${PREFIX}/,@dirrm ,' >> ${TMPPLIST} .endif -.include +.include diff --git a/devel/colorer/files/patch-src:shared:common:Hashtable.h b/devel/colorer/files/patch-src:shared:common:Hashtable.h new file mode 100644 index 000000000000..c4644a59ed6b --- /dev/null +++ b/devel/colorer/files/patch-src:shared:common:Hashtable.h @@ -0,0 +1,59 @@ +--- src/shared/common/Hashtable.h.orig Fri Sep 12 20:46:35 2003 ++++ src/shared/common/Hashtable.h Sat Sep 18 12:38:09 2004 +@@ -20,8 +20,8 @@ + + T get(const String *key) const{ + int hash = key->hashCode(); +- int bno = (hash&0x7FFFFFFF) % capacity; +- for(HashEntry *he = bucket[bno]; he != null; he = he->next) ++ int bno = (hash&0x7FFFFFFF) % this->capacity; ++ for(HashEntry *he = this->bucket[bno]; he != null; he = he->next) + if (he->hash == hash && *he->key == *key) + return he->value; + return null; +@@ -31,7 +31,7 @@ + Returns first element value in a sequence, or null, if hashtable is empty. + */ + T enumerate() const{ +- T * retval = enumerate_int(); ++ T * retval = this->enumerate_int(); + if (retval == null) return null; + return *retval; + }; +@@ -40,7 +40,7 @@ + is thrown. + */ + T next() const{ +- T *retval = next_int(); ++ T *retval = this->next_int(); + if (retval == null) return null; + return *retval; + }; +@@ -62,8 +62,8 @@ + + const T *get(const String *key) const{ + int hash = key->hashCode(); +- int bno = (hash&0x7FFFFFFF) % capacity; +- for(HashEntry *he = bucket[bno]; he != null; he = he->next) ++ int bno = (hash&0x7FFFFFFF) % this->capacity; ++ for(HashEntry *he = this->bucket[bno]; he != null; he = he->next) + if (he->hash == hash && *he->key == *key) + return &he->value; + return null; +@@ -73,14 +73,14 @@ + Returns first element value in a sequence, or null, if hashtable is empty + */ + T *enumerate() const{ +- return enumerate_int(); ++ return this->enumerate_int(); + }; + /** Returns the next value object with current enumeration procedure. + If hashtable state is changed, and next() call occurs, exception + is thrown. + */ + T *next() const{ +- return next_int(); ++ return this->next_int(); + }; + }; +