On Wed, Oct 18, 2006 at 10:23:08AM -0600, Peter Valchev wrote:
> > This diff updates www/tidy port + adds building of shared library
> > which is usefull when, for example, compiling php with tidy support.
> ..
> > Index: tidy/pkg/PFRAG.shared
> > ===================================================================
> > RCS file: tidy/pkg/PFRAG.shared
> > diff -N tidy/pkg/PFRAG.shared
> > --- /dev/null 1 Jan 1970 00:00:00 -0000
> > +++ tidy/pkg/PFRAG.shared 28 Aug 2006 14:02:18 -0000
> > @@ -0,0 +1,2 @@
> > [EMAIL PROTECTED] $OpenBSD$
> > [EMAIL PROTECTED] lib/libtidy-0.99.so.${LIBtidy-0.99_VERSION}
>
> this is wrong, in OpenBSD, the libs are named libFOO.so.VERSION,
> not libFOO-version
>
The below patch should correct that.
Thanks.
-Dan
Index: tidy//Makefile
===================================================================
RCS file: /cvs/ports/www/tidy/Makefile,v
retrieving revision 1.19
diff -u -r1.19 Makefile
--- tidy//Makefile 2005/10/05 09:39:20 1.19
+++ tidy//Makefile 2006/10/18 17:00:38
@@ -2,9 +2,10 @@
COMMENT= "validate, correct, and pretty-print HTML files"
-TIDYDATE= 050921
+TIDYDATE= 051026
DISTNAME= tidy_src_${TIDYDATE}
PKGNAME= tidy-${TIDYDATE}
+SHARED_LIBS= tidy 1.0
CATEGORIES= www
@@ -23,8 +24,8 @@
MASTER_SITES1= ${HOMEPAGE}test/
EXTRACT_SUFX= .tgz
DISTFILES= ${DISTNAME}${EXTRACT_SUFX} \
- tidy_docs_050705${EXTRACT_SUFX}:0 \
- tidy_test_050919${EXTRACT_SUFX}:1
+ tidy_docs_051020${EXTRACT_SUFX}:0 \
+ tidy_test_051026${EXTRACT_SUFX}:1
USE_GMAKE= Yes
@@ -34,6 +35,9 @@
WRKBUILD= ${WRKDIST}/build/gmake
DOCDIR= ${PREFIX}/share/doc/tidy
+
+MAKE_FLAGS= TIDY_MAJOR=${LIBtidy_VERSION:R} TIDY_MINOR=${LIBtidy_VERSION:E}
+FAKE_FLAGS= TIDY_MAJOR=${LIBtidy_VERSION:R} TIDY_MINOR=${LIBtidy_VERSION:E}
post-install:
${INSTALL_DATA_DIR} ${DOCDIR}
Index: tidy//distinfo
===================================================================
RCS file: /cvs/ports/www/tidy/distinfo,v
retrieving revision 1.7
diff -u -r1.7 distinfo
--- tidy//distinfo 2005/10/05 09:39:20 1.7
+++ tidy//distinfo 2006/10/18 17:00:38
@@ -1,12 +1,12 @@
-MD5 (tidy_docs_050705.tgz) = 2e6533fc48b077ff6243deaf21a781de
-MD5 (tidy_src_050921.tgz) = 82c76c061abfdf5f67d02951b4dd2a02
-MD5 (tidy_test_050919.tgz) = c9ca834e381537039e516da549662651
-RMD160 (tidy_docs_050705.tgz) = 49b8c2eaf87a0291b1bef6479cf1eeda6b720f52
-RMD160 (tidy_src_050921.tgz) = 958f532245412e3f8ac5bdd56edc5693cadf4b5b
-RMD160 (tidy_test_050919.tgz) = 337ca275ca6af513b1bf2a5bd4b10a2a244e90fe
-SHA1 (tidy_docs_050705.tgz) = b243d7910ce2fe57a8df27ff8f775e6d397c732d
-SHA1 (tidy_src_050921.tgz) = 4a53aa129e2575004dcbaf0cf4c5c3f1637723b0
-SHA1 (tidy_test_050919.tgz) = d214f85d581ceeeb4ec58d24d8d7494e10e62125
-SIZE (tidy_docs_050705.tgz) = 150359
-SIZE (tidy_src_050921.tgz) = 256079
-SIZE (tidy_test_050919.tgz) = 106674
+MD5 (tidy_docs_051020.tgz) = 86de2f198e57399c063d2567b2a25628
+MD5 (tidy_src_051026.tgz) = 1e39fafd6808978871346658c8da1454
+MD5 (tidy_test_051026.tgz) = 4b35b2e0495ad2fc1bc391f779c9541d
+RMD160 (tidy_docs_051020.tgz) = 63f033560af9a53393d9a3f656f26bb12bf505b6
+RMD160 (tidy_src_051026.tgz) = 0cae41f8c0cec51d4600d1bf2aac338cf60aa6b9
+RMD160 (tidy_test_051026.tgz) = 1caaf13ce9d484d8321b8b370782966066ea3a6f
+SHA1 (tidy_docs_051020.tgz) = 04988d51267566db6899e8061d9f2e5b58fbeec4
+SHA1 (tidy_src_051026.tgz) = 53be36945344af0c4080c34ebc95728bf8617f1c
+SHA1 (tidy_test_051026.tgz) = a790c98bdabffb8c181796e7ef4007cfbeb1f370
+SIZE (tidy_docs_051020.tgz) = 150402
+SIZE (tidy_src_051026.tgz) = 256131
+SIZE (tidy_test_051026.tgz) = 107014
Index: tidy//patches/patch-build_gmake_Makefile
===================================================================
RCS file: /cvs/ports/www/tidy/patches/patch-build_gmake_Makefile,v
retrieving revision 1.2
diff -u -r1.2 patch-build_gmake_Makefile
--- tidy//patches/patch-build_gmake_Makefile 2005/07/19 08:10:10 1.2
+++ tidy//patches/patch-build_gmake_Makefile 2006/10/18 17:00:38
@@ -1,6 +1,5 @@
-$OpenBSD: patch-build_gmake_Makefile,v 1.2 2005/07/19 08:10:10 aanriot Exp $
---- build/gmake/Makefile.orig Tue May 3 08:58:08 2005
-+++ build/gmake/Makefile Tue Jul 12 12:03:54 2005
+--- build/gmake/Makefile.orig Fri Jul 15 02:57:48 2005
++++ build/gmake/Makefile Wed Oct 18 12:47:59 2006
@@ -58,8 +58,8 @@ SHELL=/bin/sh
PROJECT=tidy
@@ -19,7 +18,7 @@
-CC= gcc
-CFLAGS= -g -Wall -Wno-switch -Wno-parentheses -I $(INCDIR)
+#CC= gcc
-+CFLAGS+= -I $(INCDIR)
++CFLAGS+= -fPIC -I $(INCDIR)
# flags only supported with gcc 3.x
# CFLAGS += -Wunused-parameter
@@ -29,17 +28,29 @@
# OTHERCFLAGS+= -DSUPPORT_ACCESSIBILITY_CHECKS=1 -DSUPPORT_UTF16_ENCODINGS=1
-DSUPPORT_ASIAN_ENCODINGS=1
ifdef SUPPORT_UTF16_ENCODINGS
CFLAGS += -DSUPPORT_UTF16_ENCODINGS=$(SUPPORT_UTF16_ENCODINGS)
-@@ -115,7 +115,7 @@ LIBSUFFIX = .a
+@@ -112,10 +112,12 @@ TIDY_MINOR = 0
+ # This will come from autoconf again
+ LIBPREFIX = lib
+ LIBSUFFIX = .a
++SHAREDLIBSUFFIX = .so
OBJSUF = .o
LIBRARY = $(LIBDIR)/$(LIBPREFIX)$(PROJECT)$(LIBSUFFIX)
-AR=ar -r
++SHAREDLIBRARY =
$(LIBDIR)/$(LIBPREFIX)$(PROJECT)$(SHAREDLIBSUFFIX).$(TIDY_MAJOR).$(TIDY_MINOR)
+#AR=ar -r
XSLTPROC = xsltproc
-@@ -164,7 +164,7 @@ doc: $(DOCS)
+@@ -158,17 +160,21 @@ LIBHFILES= \
+ $(SRCDIR)/tidy-int.h
+
+-all: $(LIBRARY) $(EXES)
++all: $(LIBRARY) $(SHAREDLIBRARY) $(EXES)
+
+ doc: $(DOCS)
+
$(LIBRARY): $(OBJFILES)
if [ ! -d $(LIBDIR) ]; then mkdir $(LIBDIR); fi
- $(AR) $@ $(OBJFILES)
@@ -47,7 +58,15 @@
ifdef RANLIB
$(RANLIB) $@
endif
-@@ -205,19 +205,19 @@ clean:
+
++$(SHAREDLIBRARY): $(OBJFILES)
++ if [ ! -d $(LIBDIR) ]; then mkdir $(LIBDIR); fi
++ $(CC) -shared -fPIC -o $(SHAREDLIBRARY) $(OBJFILES)
++
+ $(OBJDIR)/%$(OBJSUF): $(SRCDIR)/%.c $(HFILES) $(LIBHFILES) Makefile
+ if [ ! -d $(OBJDIR) ]; then mkdir $(OBJDIR); fi
+ $(CC) $(CFLAGS) $(OTHERCFLAGS) -o $@ -c $<
+@@ -205,19 +211,20 @@ clean:
if [ "$(BINDIR)" != "$(TOPDIR)" -a -d $(BINDIR) ]; then rmdir
$(BINDIR); fi
installhdrs: $(HFILES)
@@ -59,6 +78,7 @@
if [ ! -d "$(libinst)" ]; then mkdir -p "$(libinst)"; fi
- cp -f $(LIBRARY) "$(libinst)/"
+ ${BSD_INSTALL_DATA} $(LIBRARY) "$(libinst)/"
++ ${BSD_INSTALL_DATA} $(SHAREDLIBRARY) "$(libinst)/"
installexes: $(EXES)
- if [ ! -d "$(bininst)" ]; then mkdir -p "$(bininst)"; fi
Index: tidy//pkg/PLIST
===================================================================
RCS file: /cvs/ports/www/tidy/pkg/PLIST,v
retrieving revision 1.6
diff -u -r1.6 PLIST
--- tidy//pkg/PLIST 2005/07/19 08:10:10 1.6
+++ tidy//pkg/PLIST 2006/10/18 17:00:38
@@ -1,4 +1,5 @@
@comment $OpenBSD: PLIST,v 1.6 2005/07/19 08:10:10 aanriot Exp $
+%%SHARED%%
bin/tab2space
bin/tidy
include/tidy/
--
"Burnished gallows set with red
Caress the fevered, empty mind
Of man who hangs bloodied and blind
To reach for wisdom, not for bread." -- Deoridhe Grimsdaughter