Fix build on 4.x systems.
Reported by: bento via kris
This commit is contained in:
parent
245fc26903
commit
68d4f1b2b1
Notes:
svn2git
2021-03-31 03:12:20 +00:00
svn path=/head/; revision=92857
@ -7,7 +7,7 @@
|
||||
|
||||
PORTNAME= passepartout
|
||||
PORTVERSION= 0.2
|
||||
PORTREVISION= 1
|
||||
PORTREVISION= 2
|
||||
CATEGORIES= graphics gnome
|
||||
MASTER_SITES= http://www.stacken.kth.se/project/pptout/files/
|
||||
|
||||
@ -30,6 +30,12 @@ USE_X_PREFIX= yes
|
||||
USE_GNOME= gnometarget gnomehack
|
||||
USE_LIBTOOL= yes
|
||||
|
||||
.include <bsd.port.pre.mk>
|
||||
|
||||
.if ${OSVERSION} < 500000
|
||||
EXTRA_PATCHES= ${PATCHDIR}/extra-patch-old_cxx
|
||||
.endif
|
||||
|
||||
# Fix for recent libxml++ API change
|
||||
post-patch:
|
||||
@${FIND} ${WRKSRC}/src/pptout -name *.cc \
|
||||
@ -37,4 +43,4 @@ post-patch:
|
||||
| ${XARGS} ${REINPLACE_CMD} -e \
|
||||
's|add_attribute|set_attribute|'
|
||||
|
||||
.include <bsd.port.mk>
|
||||
.include <bsd.port.post.mk>
|
||||
|
48
graphics/passepartout/files/extra-patch-old_cxx
Normal file
48
graphics/passepartout/files/extra-patch-old_cxx
Normal file
@ -0,0 +1,48 @@
|
||||
--- src/ps/pfb2pfa.cc.orig Fri Oct 31 20:57:37 2003
|
||||
+++ src/ps/pfb2pfa.cc Sun Nov 2 11:47:20 2003
|
||||
@@ -4,8 +4,8 @@
|
||||
#include "encode.h"
|
||||
|
||||
void PS::pfb2pfa(std::istream &in, std::ostream &out) {
|
||||
- in.exceptions(std::ios_base::eofbit); // throw exception on eof
|
||||
- try {
|
||||
+// in.exceptions(std::ios_base::eofbit); // throw exception on eof
|
||||
+// try {
|
||||
while(in) { // parse header
|
||||
if (in.peek() != 128)
|
||||
throw std::runtime_error("bad magic number for segment");
|
||||
@@ -40,9 +40,9 @@
|
||||
filter.end();
|
||||
}
|
||||
}
|
||||
- } catch (std::ios_base::failure) {
|
||||
- throw std::runtime_error("unexpected end of file");
|
||||
- }
|
||||
+// } catch (std::ios::failure) {
|
||||
+// throw std::runtime_error("unexpected end of file");
|
||||
+// }
|
||||
}
|
||||
|
||||
#ifdef PFB2PFA_STANDALONE
|
||||
--- src/util/filesys.h.orig Fri Oct 31 20:47:03 2003
|
||||
+++ src/util/filesys.h Fri Oct 31 20:52:19 2003
|
||||
@@ -4,7 +4,7 @@
|
||||
// Copyright (C) 2002, 2003, Fredrik Arnerup & Rasmus Kaj, See COPYING
|
||||
///
|
||||
#include <string>
|
||||
-#include <ios> // mode for access
|
||||
+#include <iostream> // mode for access
|
||||
|
||||
// Check if the specified file exists
|
||||
bool exists(const std::string& filename);
|
||||
--- src/pptout/docview.cc.orig Sun Nov 2 11:56:40 2003
|
||||
+++ src/pptout/docview.cc Sun Nov 2 12:04:37 2003
|
||||
@@ -467,7 +467,7 @@
|
||||
|
||||
void Document_View::on_clipboard_clear() {
|
||||
// not really necessary
|
||||
- clip.clear();
|
||||
+ clip.resize(0);
|
||||
}
|
||||
|
||||
void Document_View::cut() {
|
10
graphics/passepartout/files/patch-src::pptout::filewatcher.h
Normal file
10
graphics/passepartout/files/patch-src::pptout::filewatcher.h
Normal file
@ -0,0 +1,10 @@
|
||||
--- src/pptout/filewatcher.h.orig Sun Nov 2 11:53:06 2003
|
||||
+++ src/pptout/filewatcher.h Sun Nov 2 11:53:23 2003
|
||||
@@ -5,6 +5,7 @@
|
||||
///
|
||||
#include <sigc++/sigc++.h>
|
||||
#include <string>
|
||||
+#include <sys/time.h>
|
||||
|
||||
class File_Watcher: public SigC::Object {
|
||||
public:
|
19
graphics/passepartout/files/patch-src::testbed::testbed.cc
Normal file
19
graphics/passepartout/files/patch-src::testbed::testbed.cc
Normal file
@ -0,0 +1,19 @@
|
||||
--- src/testbed/testbed.cc.orig Fri Oct 31 20:36:24 2003
|
||||
+++ src/testbed/testbed.cc Fri Oct 31 20:39:09 2003
|
||||
@@ -1,6 +1,7 @@
|
||||
#include "testbed.hh"
|
||||
#include "util/warning.h"
|
||||
#include <glibmm/exception.h> // Stupid glib!
|
||||
+#include <algorithm>
|
||||
#include <functional>
|
||||
///
|
||||
// Copyright (C) 2003, Fredrik Arnerup & Rasmus Kaj, See COPYING
|
||||
@@ -53,7 +54,7 @@
|
||||
verbose.active = true;
|
||||
verbose << "Starting test run. " << TestCase::cases.size()
|
||||
<< " case(s) to try." << std::endl;
|
||||
- for_each(TestCase::cases.begin(), TestCase::cases.end(),
|
||||
+ std::for_each(TestCase::cases.begin(), TestCase::cases.end(),
|
||||
std::mem_fun(&TestCase::run));
|
||||
verbose << "Done running " << TestCase::cases.size() << " test case(s). "
|
||||
<< TestCase::successes << " succeded, "
|
12
graphics/passepartout/files/patch-src::util::filesys.cc
Normal file
12
graphics/passepartout/files/patch-src::util::filesys.cc
Normal file
@ -0,0 +1,12 @@
|
||||
--- src/util/filesys.cc.orig Fri Oct 31 20:53:31 2003
|
||||
+++ src/util/filesys.cc Fri Oct 31 20:55:05 2003
|
||||
@@ -5,7 +5,9 @@
|
||||
#include "stringutil.h"
|
||||
#include "os.h"
|
||||
#include <unistd.h>
|
||||
+#include <errno.h>
|
||||
#include <stdexcept>
|
||||
+#include <memory>
|
||||
|
||||
using std::string;
|
||||
|
11
graphics/passepartout/files/patch-src::util::stringutil.cc
Normal file
11
graphics/passepartout/files/patch-src::util::stringutil.cc
Normal file
@ -0,0 +1,11 @@
|
||||
--- src/util/stringutil.cc.orig Fri Oct 31 20:40:15 2003
|
||||
+++ src/util/stringutil.cc Fri Oct 31 20:44:29 2003
|
||||
@@ -17,7 +17,7 @@
|
||||
|
||||
bool whitespace(char c)
|
||||
{
|
||||
- return std::isspace(c);
|
||||
+ return isspace(c);
|
||||
}
|
||||
|
||||
std::string strip_whitespace(std::string s, bool front, bool back)
|
@ -0,0 +1,11 @@
|
||||
--- src/xml2ps/pagedstream.cc.orig Sun Nov 2 11:48:29 2003
|
||||
+++ src/xml2ps/pagedstream.cc Sun Nov 2 11:49:54 2003
|
||||
@@ -3,6 +3,8 @@
|
||||
#include <fstream>
|
||||
#include <sstream>
|
||||
#include <iostream>
|
||||
+#include <exception>
|
||||
+#include <memory>
|
||||
|
||||
xml2ps::PagedStream::PagedStream()
|
||||
: current_part(0)
|
Loading…
Reference in New Issue
Block a user