aboutsummaryrefslogtreecommitdiff
path: root/textproc/opensp
diff options
context:
space:
mode:
authorGuido Falsi <madpilot@FreeBSD.org>2018-02-03 13:36:44 +0000
committerGuido Falsi <madpilot@FreeBSD.org>2018-02-03 13:36:44 +0000
commitee08fc60e5738bfa9d02876d8374492f5ca168ea (patch)
treea762f4094545ebc68c8b8a8ffbcf3c35109aebb4 /textproc/opensp
parent3a0efcc56dbe7da06cc25419adafac7fb929babd (diff)
downloadports-ee08fc60e5738bfa9d02876d8374492f5ca168ea.tar.gz
ports-ee08fc60e5738bfa9d02876d8374492f5ca168ea.zip
- Fix opensp build with clang 6
- While here convert to USES=localbase PR: 225307 Submitted by: me Approved by: Maintainer timeout
Notes
Notes: svn path=/head/; revision=460812
Diffstat (limited to 'textproc/opensp')
-rw-r--r--textproc/opensp/Makefile4
-rw-r--r--textproc/opensp/files/patch-configure265
-rw-r--r--textproc/opensp/files/patch-include_IList.h13
-rw-r--r--textproc/opensp/files/patch-include_IListIter.h13
-rw-r--r--textproc/opensp/files/patch-include_Ptr.h13
-rw-r--r--textproc/opensp/files/patch-lib_Parser.h29
6 files changed, 333 insertions, 4 deletions
diff --git a/textproc/opensp/Makefile b/textproc/opensp/Makefile
index 135addf6286a..57567210e896 100644
--- a/textproc/opensp/Makefile
+++ b/textproc/opensp/Makefile
@@ -15,14 +15,12 @@ LICENSE_NAME= License of James Clark's Software
LICENSE_FILE= ${WRKSRC}/COPYING
LICENSE_PERMS= dist-mirror dist-sell pkg-mirror pkg-sell auto-accept
-USES= gmake iconv libtool perl5
+USES= gmake iconv libtool localbase perl5
USE_LDCONFIG= yes
GNU_CONFIGURE= yes
CONFIGURE_ARGS= --enable-default-catalog=${PREFIX}/share/sgml/catalog \
--datadir=${PREFIX}/share/sgml/openjade \
--disable-doc-build
-LDFLAGS+= -L${LOCALBASE}/lib
-CFLAGS+= -I${LOCALBASE}/include
OPTIONS_DEFINE= DOCS NLS
OPTIONS_SUB= yes
diff --git a/textproc/opensp/files/patch-configure b/textproc/opensp/files/patch-configure
index 13fd5e113476..59249b2646e5 100644
--- a/textproc/opensp/files/patch-configure
+++ b/textproc/opensp/files/patch-configure
@@ -1,6 +1,269 @@
--- configure.orig 2005-12-23 14:15:56 UTC
+++ configure
-@@ -26441,12 +26441,12 @@ cat >>conftest.$ac_ext <<_ACEOF
+@@ -2885,149 +2885,6 @@ echo "${ECHO_T}$ac_cv_prog_cc_stdc" >&6
+ CC="$CC $ac_cv_prog_cc_stdc" ;;
+ esac
+
+-# Some people use a C++ compiler to compile C. Since we use `exit',
+-# in C++ we need to declare it. In case someone uses the same compiler
+-# for both compiling C and C++ we need to have the C++ compiler decide
+-# the declaration of exit, since it's the most demanding environment.
+-cat >conftest.$ac_ext <<_ACEOF
+-#ifndef __cplusplus
+- choke me
+-#endif
+-_ACEOF
+-rm -f conftest.$ac_objext
+-if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
+- (eval $ac_compile) 2>conftest.er1
+- ac_status=$?
+- grep -v '^ *+' conftest.er1 >conftest.err
+- rm -f conftest.er1
+- cat conftest.err >&5
+- echo "$as_me:$LINENO: \$? = $ac_status" >&5
+- (exit $ac_status); } &&
+- { ac_try='test -z "$ac_c_werror_flag"
+- || test ! -s conftest.err'
+- { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
+- (eval $ac_try) 2>&5
+- ac_status=$?
+- echo "$as_me:$LINENO: \$? = $ac_status" >&5
+- (exit $ac_status); }; } &&
+- { ac_try='test -s conftest.$ac_objext'
+- { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
+- (eval $ac_try) 2>&5
+- ac_status=$?
+- echo "$as_me:$LINENO: \$? = $ac_status" >&5
+- (exit $ac_status); }; }; then
+- for ac_declaration in \
+- '' \
+- 'extern "C" void std::exit (int) throw (); using std::exit;' \
+- 'extern "C" void std::exit (int); using std::exit;' \
+- 'extern "C" void exit (int) throw ();' \
+- 'extern "C" void exit (int);' \
+- 'void exit (int);'
+-do
+- cat >conftest.$ac_ext <<_ACEOF
+-/* confdefs.h. */
+-_ACEOF
+-cat confdefs.h >>conftest.$ac_ext
+-cat >>conftest.$ac_ext <<_ACEOF
+-/* end confdefs.h. */
+-$ac_declaration
+-#include <stdlib.h>
+-int
+-main ()
+-{
+-exit (42);
+- ;
+- return 0;
+-}
+-_ACEOF
+-rm -f conftest.$ac_objext
+-if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
+- (eval $ac_compile) 2>conftest.er1
+- ac_status=$?
+- grep -v '^ *+' conftest.er1 >conftest.err
+- rm -f conftest.er1
+- cat conftest.err >&5
+- echo "$as_me:$LINENO: \$? = $ac_status" >&5
+- (exit $ac_status); } &&
+- { ac_try='test -z "$ac_c_werror_flag"
+- || test ! -s conftest.err'
+- { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
+- (eval $ac_try) 2>&5
+- ac_status=$?
+- echo "$as_me:$LINENO: \$? = $ac_status" >&5
+- (exit $ac_status); }; } &&
+- { ac_try='test -s conftest.$ac_objext'
+- { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
+- (eval $ac_try) 2>&5
+- ac_status=$?
+- echo "$as_me:$LINENO: \$? = $ac_status" >&5
+- (exit $ac_status); }; }; then
+- :
+-else
+- echo "$as_me: failed program was:" >&5
+-sed 's/^/| /' conftest.$ac_ext >&5
+-
+-continue
+-fi
+-rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
+- cat >conftest.$ac_ext <<_ACEOF
+-/* confdefs.h. */
+-_ACEOF
+-cat confdefs.h >>conftest.$ac_ext
+-cat >>conftest.$ac_ext <<_ACEOF
+-/* end confdefs.h. */
+-$ac_declaration
+-int
+-main ()
+-{
+-exit (42);
+- ;
+- return 0;
+-}
+-_ACEOF
+-rm -f conftest.$ac_objext
+-if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
+- (eval $ac_compile) 2>conftest.er1
+- ac_status=$?
+- grep -v '^ *+' conftest.er1 >conftest.err
+- rm -f conftest.er1
+- cat conftest.err >&5
+- echo "$as_me:$LINENO: \$? = $ac_status" >&5
+- (exit $ac_status); } &&
+- { ac_try='test -z "$ac_c_werror_flag"
+- || test ! -s conftest.err'
+- { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
+- (eval $ac_try) 2>&5
+- ac_status=$?
+- echo "$as_me:$LINENO: \$? = $ac_status" >&5
+- (exit $ac_status); }; } &&
+- { ac_try='test -s conftest.$ac_objext'
+- { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
+- (eval $ac_try) 2>&5
+- ac_status=$?
+- echo "$as_me:$LINENO: \$? = $ac_status" >&5
+- (exit $ac_status); }; }; then
+- break
+-else
+- echo "$as_me: failed program was:" >&5
+-sed 's/^/| /' conftest.$ac_ext >&5
+-
+-fi
+-rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
+-done
+-rm -f conftest*
+-if test -n "$ac_declaration"; then
+- echo '#ifdef __cplusplus' >>confdefs.h
+- echo $ac_declaration >>confdefs.h
+- echo '#endif' >>confdefs.h
+-fi
+-
+-else
+- echo "$as_me: failed program was:" >&5
+-sed 's/^/| /' conftest.$ac_ext >&5
+-
+-fi
+-rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
+ ac_ext=c
+ ac_cpp='$CPP $CPPFLAGS'
+ ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
+@@ -3685,112 +3542,7 @@ else
+ CXXFLAGS=
+ fi
+ fi
+-for ac_declaration in \
+- '' \
+- 'extern "C" void std::exit (int) throw (); using std::exit;' \
+- 'extern "C" void std::exit (int); using std::exit;' \
+- 'extern "C" void exit (int) throw ();' \
+- 'extern "C" void exit (int);' \
+- 'void exit (int);'
+-do
+- cat >conftest.$ac_ext <<_ACEOF
+-/* confdefs.h. */
+-_ACEOF
+-cat confdefs.h >>conftest.$ac_ext
+-cat >>conftest.$ac_ext <<_ACEOF
+-/* end confdefs.h. */
+-$ac_declaration
+-#include <stdlib.h>
+-int
+-main ()
+-{
+-exit (42);
+- ;
+- return 0;
+-}
+-_ACEOF
+-rm -f conftest.$ac_objext
+-if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
+- (eval $ac_compile) 2>conftest.er1
+- ac_status=$?
+- grep -v '^ *+' conftest.er1 >conftest.err
+- rm -f conftest.er1
+- cat conftest.err >&5
+- echo "$as_me:$LINENO: \$? = $ac_status" >&5
+- (exit $ac_status); } &&
+- { ac_try='test -z "$ac_cxx_werror_flag"
+- || test ! -s conftest.err'
+- { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
+- (eval $ac_try) 2>&5
+- ac_status=$?
+- echo "$as_me:$LINENO: \$? = $ac_status" >&5
+- (exit $ac_status); }; } &&
+- { ac_try='test -s conftest.$ac_objext'
+- { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
+- (eval $ac_try) 2>&5
+- ac_status=$?
+- echo "$as_me:$LINENO: \$? = $ac_status" >&5
+- (exit $ac_status); }; }; then
+- :
+-else
+- echo "$as_me: failed program was:" >&5
+-sed 's/^/| /' conftest.$ac_ext >&5
+
+-continue
+-fi
+-rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
+- cat >conftest.$ac_ext <<_ACEOF
+-/* confdefs.h. */
+-_ACEOF
+-cat confdefs.h >>conftest.$ac_ext
+-cat >>conftest.$ac_ext <<_ACEOF
+-/* end confdefs.h. */
+-$ac_declaration
+-int
+-main ()
+-{
+-exit (42);
+- ;
+- return 0;
+-}
+-_ACEOF
+-rm -f conftest.$ac_objext
+-if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
+- (eval $ac_compile) 2>conftest.er1
+- ac_status=$?
+- grep -v '^ *+' conftest.er1 >conftest.err
+- rm -f conftest.er1
+- cat conftest.err >&5
+- echo "$as_me:$LINENO: \$? = $ac_status" >&5
+- (exit $ac_status); } &&
+- { ac_try='test -z "$ac_cxx_werror_flag"
+- || test ! -s conftest.err'
+- { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
+- (eval $ac_try) 2>&5
+- ac_status=$?
+- echo "$as_me:$LINENO: \$? = $ac_status" >&5
+- (exit $ac_status); }; } &&
+- { ac_try='test -s conftest.$ac_objext'
+- { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
+- (eval $ac_try) 2>&5
+- ac_status=$?
+- echo "$as_me:$LINENO: \$? = $ac_status" >&5
+- (exit $ac_status); }; }; then
+- break
+-else
+- echo "$as_me: failed program was:" >&5
+-sed 's/^/| /' conftest.$ac_ext >&5
+-
+-fi
+-rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
+-done
+-rm -f conftest*
+-if test -n "$ac_declaration"; then
+- echo '#ifdef __cplusplus' >>confdefs.h
+- echo $ac_declaration >>confdefs.h
+- echo '#endif' >>confdefs.h
+-fi
+-
+ ac_ext=c
+ ac_cpp='$CPP $CPPFLAGS'
+ ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
+@@ -26441,12 +26193,12 @@ cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h. */
#include <libintl.h>
extern int _nl_msg_cat_cntr;
diff --git a/textproc/opensp/files/patch-include_IList.h b/textproc/opensp/files/patch-include_IList.h
new file mode 100644
index 000000000000..2776609b8b76
--- /dev/null
+++ b/textproc/opensp/files/patch-include_IList.h
@@ -0,0 +1,13 @@
+--- include/IList.h.orig 2005-07-21 14:04:38 UTC
++++ include/IList.h
+@@ -26,8 +26,8 @@ class IList : private IListBase { (public)
+ void swap(IList<T> &list) { IListBase::swap(list); }
+ T *head() const { return (T *)IListBase::head(); }
+ T *get() { return (T *)IListBase::get(); }
+- IListBase::clear;
+- IListBase::empty;
++ using IListBase::clear;
++ using IListBase::empty;
+ friend class IListIter<T>;
+ private:
+ IList(const IList<T> &); // undefined
diff --git a/textproc/opensp/files/patch-include_IListIter.h b/textproc/opensp/files/patch-include_IListIter.h
new file mode 100644
index 000000000000..29fe8e3f1e1d
--- /dev/null
+++ b/textproc/opensp/files/patch-include_IListIter.h
@@ -0,0 +1,13 @@
+--- include/IListIter.h.orig 2005-07-21 14:04:38 UTC
++++ include/IListIter.h
+@@ -17,8 +17,8 @@ class IListIter : private IListIterBase { (public)
+ IListIter(const IList<T> &list) : IListIterBase(list) { }
+ T *cur() const { return (T *)IListIterBase::cur(); }
+
+- IListIterBase::next;
+- IListIterBase::done;
++ using IListIterBase::next;
++ using IListIterBase::done;
+ };
+
+ #ifdef SP_NAMESPACE
diff --git a/textproc/opensp/files/patch-include_Ptr.h b/textproc/opensp/files/patch-include_Ptr.h
new file mode 100644
index 000000000000..a0756656525b
--- /dev/null
+++ b/textproc/opensp/files/patch-include_Ptr.h
@@ -0,0 +1,13 @@
+--- include/Ptr.h.orig 2005-07-21 14:04:39 UTC
++++ include/Ptr.h
+@@ -69,8 +69,8 @@ class ConstPtr : private Ptr<T> { (public)
+ const T *operator->() const { return Ptr<T>::pointer(); }
+ const T &operator*() const { return *Ptr<T>::pointer(); }
+ void swap(ConstPtr<T> &p) { Ptr<T>::swap(p); }
+- Ptr<T>::isNull;
+- Ptr<T>::clear;
++ using Ptr<T>::isNull;
++ using Ptr<T>::clear;
+ Boolean operator==(const Ptr<T> &p) const { return Ptr<T>::operator==(p); }
+ Boolean operator!=(const Ptr<T> &p) const { return Ptr<T>::operator!=(p); }
+ Boolean operator==(const ConstPtr<T> &p) const {
diff --git a/textproc/opensp/files/patch-lib_Parser.h b/textproc/opensp/files/patch-lib_Parser.h
new file mode 100644
index 000000000000..7aef32589965
--- /dev/null
+++ b/textproc/opensp/files/patch-lib_Parser.h
@@ -0,0 +1,29 @@
+--- lib/Parser.h.orig 2005-07-21 14:05:17 UTC
++++ lib/Parser.h
+@@ -62,16 +62,16 @@ class Parser : private ParserState { (public)
+ Parser(const SgmlParser::Params &);
+ Event *nextEvent();
+ void parseAll(EventHandler &, const volatile sig_atomic_t *cancelPtr);
+- ParserState::sdPointer;
+- ParserState::instanceSyntaxPointer;
+- ParserState::prologSyntaxPointer;
+- ParserState::activateLinkType;
+- ParserState::allLinkTypesActivated;
+- ParserState::entityManager;
+- ParserState::entityCatalog;
+- ParserState::baseDtd;
+- ParserState::options;
+- ParserState::instantiateDtd;
++ using ParserState::sdPointer;
++ using ParserState::instanceSyntaxPointer;
++ using ParserState::prologSyntaxPointer;
++ using ParserState::activateLinkType;
++ using ParserState::allLinkTypesActivated;
++ using ParserState::entityManager;
++ using ParserState::entityCatalog;
++ using ParserState::baseDtd;
++ using ParserState::options;
++ using ParserState::instantiateDtd;
+ friend class PiAttspecParser;
+ private:
+ Parser(const Parser &); // undefined