summaryrefslogtreecommitdiff
path: root/lang
diff options
context:
space:
mode:
authorasau <asau@pkgsrc.org>2010-02-11 20:43:49 +0000
committerasau <asau@pkgsrc.org>2010-02-11 20:43:49 +0000
commit3052d9a7e07595aaf1bb079706f1f09bf5f179d6 (patch)
tree59d49d1b2d9e6ab9aeb8c139b2880595c11ec1c2 /lang
parent9bf63ee99c82dfbe47a30a1cf123988201e82d77 (diff)
downloadpkgsrc-3052d9a7e07595aaf1bb079706f1f09bf5f179d6.tar.gz
Update to Yap 5.1.3.
Many improvements, bug and compatibility fixes since previous 5.0.0 package.
Diffstat (limited to 'lang')
-rw-r--r--lang/yap/Makefile17
-rw-r--r--lang/yap/PLIST243
-rw-r--r--lang/yap/distinfo18
-rw-r--r--lang/yap/patches/patch-ab16
-rw-r--r--lang/yap/patches/patch-ac12
-rw-r--r--lang/yap/patches/patch-ad16
-rw-r--r--lang/yap/patches/patch-ae14
-rw-r--r--lang/yap/patches/patch-af15
-rw-r--r--lang/yap/patches/patch-ag56
-rw-r--r--lang/yap/patches/patch-ah15
-rw-r--r--lang/yap/patches/patch-ai15
11 files changed, 253 insertions, 184 deletions
diff --git a/lang/yap/Makefile b/lang/yap/Makefile
index 44b29f562ef..e6625d322ef 100644
--- a/lang/yap/Makefile
+++ b/lang/yap/Makefile
@@ -1,11 +1,10 @@
-# $NetBSD: Makefile,v 1.6 2008/06/12 02:14:33 joerg Exp $
+# $NetBSD: Makefile,v 1.7 2010/02/11 20:43:49 asau Exp $
#
-DISTNAME= Yap-5.0.0
-PKGREVISION= 1
+DISTNAME= Yap-5.1.3
CATEGORIES= lang
-MASTER_SITES= ${MASTER_SITE_SOURCEFORGE:=yap/}
-DIST_SUBDIR= ${PKGNAME_NOREV}-1
+# MASTER_SITES= ${MASTER_SITE_SOURCEFORGE:=yap/}
+MASTER_SITES= http://www.dcc.fc.up.pt/~vsc/Yap/current/
MAINTAINER= pkgsrc-users@NetBSD.org
HOMEPAGE= http://www.ncc.up.pt/~vsc/Yap/
@@ -16,6 +15,14 @@ PKG_DESTDIR_SUPPORT= user-destdir
USE_PKGLOCALEDIR= yes
GNU_CONFIGURE= yes
+# Don't enable system malloc, it dumps core otherwise:
+#CONFIGURE_ARGS= --enable-use-malloc
CONFIGURE_ENV+= INDENT=${TRUE:Q}
+# debug option:
+#CONFIGURE_ARGS+= --enable-debug-yap
+
+.include "../../devel/ncurses/buildlink3.mk"
+.include "../../devel/readline/buildlink3.mk"
+.include "../../devel/gmp/buildlink3.mk"
.include "../../mk/bsd.pkg.mk"
diff --git a/lang/yap/PLIST b/lang/yap/PLIST
index f65b1695771..69144e942e8 100644
--- a/lang/yap/PLIST
+++ b/lang/yap/PLIST
@@ -1,8 +1,12 @@
-@comment $NetBSD: PLIST,v 1.3 2009/06/14 18:03:45 joerg Exp $
+@comment $NetBSD: PLIST,v 1.4 2010/02/11 20:43:49 asau Exp $
bin/yap
+include/Yap/SWI-Prolog.h
+include/Yap/SWI-Stream.h
include/Yap/YapInterface.h
include/Yap/c_interface.h
include/Yap/yap_structs.h
+lib/Yap/itries.so
+lib/Yap/matrix.so
lib/Yap/random.so
lib/Yap/regcomp.so
lib/Yap/regerror.so
@@ -11,208 +15,118 @@ lib/Yap/regexp.so
lib/Yap/regfree.so
lib/Yap/startup
lib/Yap/sys.so
-lib/Yap/yap2swi.so
-lib/Yap/yap_tries.so
+lib/Yap/tries.so
+lib/Yap/yap_rl.so
lib/libYap.a
-share/Yap/CHR.LICENSE
-share/Yap/CLPQR.LICENSE
+share/Yap/aggregate.pl
+share/Yap/apply.pl
+share/Yap/apply.yap
share/Yap/apply_macros.yap
+share/Yap/arg.yap
share/Yap/assoc.yap
share/Yap/atts.yap
share/Yap/avl.yap
share/Yap/charsio.yap
-share/Yap/chr.yap
-share/Yap/chr/chrcmp.pl
-share/Yap/chr/compenv.pl
-share/Yap/chr/concat.pl
-share/Yap/chr/examples/allentable.pl
-share/Yap/chr/examples/arc.pl
-share/Yap/chr/examples/bool.pl
-share/Yap/chr/examples/cft.pl
-share/Yap/chr/examples/domain.pl
-share/Yap/chr/examples/examples-adder.bool
-share/Yap/chr/examples/examples-benchmark.math
-share/Yap/chr/examples/examples-deussen.bool
-share/Yap/chr/examples/examples-diaz.bool
-share/Yap/chr/examples/examples-fourier.math
-share/Yap/chr/examples/examples-holzbaur.math
-share/Yap/chr/examples/examples-lim1.math
-share/Yap/chr/examples/examples-lim2.math
-share/Yap/chr/examples/examples-lim3.math
-share/Yap/chr/examples/examples-puzzle.bool
-share/Yap/chr/examples/examples-queens.bool
-share/Yap/chr/examples/examples-queens.domain
-share/Yap/chr/examples/examples-stuckey.math
-share/Yap/chr/examples/examples-thom.math
-share/Yap/chr/examples/gcd.pl
-share/Yap/chr/examples/interval.pl
-share/Yap/chr/examples/kl-one.pl
-share/Yap/chr/examples/leq.pl
-share/Yap/chr/examples/list.pl
-share/Yap/chr/examples/listdom.pl
-share/Yap/chr/examples/math-elim.pl
-share/Yap/chr/examples/math-fougau.pl
-share/Yap/chr/examples/math-fourier.pl
-share/Yap/chr/examples/math-gauss.pl
-share/Yap/chr/examples/math-utilities.pl
-share/Yap/chr/examples/minmax.pl
-share/Yap/chr/examples/modelgenerator.pl
-share/Yap/chr/examples/osf.pl
-share/Yap/chr/examples/oztype.pl
-share/Yap/chr/examples/path.pl
-share/Yap/chr/examples/pathc.pl
-share/Yap/chr/examples/primes.pl
-share/Yap/chr/examples/scheduling.pl
-share/Yap/chr/examples/tarski.pl
-share/Yap/chr/examples/term.pl
-share/Yap/chr/examples/time-pc.pl
-share/Yap/chr/examples/time-point.pl
-share/Yap/chr/examples/time-rnd.pl
-share/Yap/chr/examples/time.pl
-share/Yap/chr/examples/tree.pl
-share/Yap/chr/examples/type.pl
-share/Yap/chr/getval.pl
-share/Yap/chr/matching.pl
-share/Yap/chr/operator.pl
-share/Yap/chr/ordering.pl
-share/Yap/chr/sbag.pl
-share/Yap/chr/sbag_a.pl
-share/Yap/chr/sbag_l.pl
-share/Yap/chr/trace.yap
share/Yap/cleanup.yap
+share/Yap/clp/clp_events.pl
share/Yap/clpbn.yap
share/Yap/clpbn/aggregates.yap
share/Yap/clpbn/bnt.yap
share/Yap/clpbn/discrete_utils.yap
+share/Yap/clpbn/display.yap
+share/Yap/clpbn/dists.yap
share/Yap/clpbn/evidence.yap
+share/Yap/clpbn/examples/School/README
+share/Yap/clpbn/examples/School/evidence_128.yap
+share/Yap/clpbn/examples/School/schema.yap
+share/Yap/clpbn/examples/School/school_128.yap
+share/Yap/clpbn/examples/School/school_32.yap
+share/Yap/clpbn/examples/School/school_64.yap
+share/Yap/clpbn/examples/School/tables.yap
+share/Yap/clpbn/examples/cg.yap
+share/Yap/clpbn/examples/sprinkler.yap
share/Yap/clpbn/gibbs.yap
share/Yap/clpbn/graphs.yap
share/Yap/clpbn/graphviz.yap
+share/Yap/clpbn/hmm.yap
+share/Yap/clpbn/jt.yap
+share/Yap/clpbn/learning/bnt_parms.yap
+share/Yap/clpbn/learning/learn_utils.yap
+share/Yap/clpbn/learning/mle.yap
+share/Yap/clpbn/matrix_cpt_utils.yap
share/Yap/clpbn/topsort.yap
share/Yap/clpbn/utils.yap
share/Yap/clpbn/vel.yap
share/Yap/clpbn/viterbi.yap
share/Yap/clpbn/xbif.yap
-share/Yap/clpq.yap
-share/Yap/clpq/arith_q.yap
-share/Yap/clpq/class.yap
-share/Yap/clpq/geler.yap
-share/Yap/clpq/nf.yap
-share/Yap/clpq/nfq.yap
-share/Yap/clpqr/arith.pl
-share/Yap/clpqr/bb.yap
-share/Yap/clpqr/bv.yap
-share/Yap/clpqr/compenv.pl
+share/Yap/clpfd.pl
+share/Yap/clpq.pl
+share/Yap/clpq/bb_q.pl
+share/Yap/clpq/bv_q.pl
+share/Yap/clpq/fourmotz_q.pl
+share/Yap/clpq/ineq_q.pl
+share/Yap/clpq/itf_q.pl
+share/Yap/clpq/nf_q.pl
+share/Yap/clpq/store_q.pl
+share/Yap/clpqr/README
+share/Yap/clpqr/class.pl
share/Yap/clpqr/dump.pl
-share/Yap/clpqr/examples/README
-share/Yap/clpqr/examples/SESSION/010
-share/Yap/clpqr/examples/SESSION/011
-share/Yap/clpqr/examples/SESSION/012
-share/Yap/clpqr/examples/SESSION/013
-share/Yap/clpqr/examples/SESSION/014
-share/Yap/clpqr/examples/SESSION/015
-share/Yap/clpqr/examples/SESSION/016
-share/Yap/clpqr/examples/SESSION/017
-share/Yap/clpqr/examples/SESSION/018
-share/Yap/clpqr/examples/SESSION/019
-share/Yap/clpqr/examples/SESSION/020
-share/Yap/clpqr/examples/SESSION/021
-share/Yap/clpqr/examples/SESSION/022
-share/Yap/clpqr/examples/SESSION/023
-share/Yap/clpqr/examples/SESSION/024
-share/Yap/clpqr/examples/SESSION/030
-share/Yap/clpqr/examples/SESSION/031
-share/Yap/clpqr/examples/SESSION/032
-share/Yap/clpqr/examples/SESSION/033
-share/Yap/clpqr/examples/SESSION/034
-share/Yap/clpqr/examples/SESSION/035
-share/Yap/clpqr/examples/SESSION/110
-share/Yap/clpqr/examples/SESSION/111
-share/Yap/clpqr/examples/SESSION/112
-share/Yap/clpqr/examples/SESSION/113
-share/Yap/clpqr/examples/SESSION/114
-share/Yap/clpqr/examples/SESSION/115
-share/Yap/clpqr/examples/SESSION/116
-share/Yap/clpqr/examples/SESSION/117
-share/Yap/clpqr/examples/SESSION/118
-share/Yap/clpqr/examples/SESSION/119
-share/Yap/clpqr/examples/SESSION/120
-share/Yap/clpqr/examples/SESSION/122
-share/Yap/clpqr/examples/SESSION/123
-share/Yap/clpqr/examples/SESSION/124
-share/Yap/clpqr/examples/SESSION/130
-share/Yap/clpqr/examples/SESSION/131
-share/Yap/clpqr/examples/SESSION/132
-share/Yap/clpqr/examples/SESSION/133
-share/Yap/clpqr/examples/SESSION/134
-share/Yap/clpqr/examples/SESSION/135
-share/Yap/clpqr/examples/caneghem.pl
-share/Yap/clpqr/examples/eliminat.pl
-share/Yap/clpqr/examples/matmul.pl
-share/Yap/clpqr/examples/mg.pl
-share/Yap/clpqr/examples/mip.pl
-share/Yap/clpqr/examples/monash/README
-share/Yap/clpqr/examples/monash/air
-share/Yap/clpqr/examples/monash/amplif
-share/Yap/clpqr/examples/monash/complex
-share/Yap/clpqr/examples/monash/critical
-share/Yap/clpqr/examples/monash/dnf
-share/Yap/clpqr/examples/monash/fib
-share/Yap/clpqr/examples/monash/findroot
-share/Yap/clpqr/examples/monash/invert
-share/Yap/clpqr/examples/monash/laplace
-share/Yap/clpqr/examples/monash/mortgage
-share/Yap/clpqr/examples/monash/nrev
-share/Yap/clpqr/examples/monash/option
-share/Yap/clpqr/examples/monash/pictures
-share/Yap/clpqr/examples/monash/rkf45
-share/Yap/clpqr/examples/monash/rlc
-share/Yap/clpqr/examples/monash/smm
-share/Yap/clpqr/examples/monash/toolpath
-share/Yap/clpqr/examples/monash/zebra
-share/Yap/clpqr/examples/root.pl
-share/Yap/clpqr/examples/simplex.pl
-share/Yap/clpqr/examples/squares.pl
-share/Yap/clpqr/expand.yap
-share/Yap/clpqr/fourmotz.pl
-share/Yap/clpqr/ineq.yap
-share/Yap/clpqr/itf3.pl
-share/Yap/clpqr/monash.pl
-share/Yap/clpqr/ordering.yap
-share/Yap/clpqr/printf.pl
+share/Yap/clpqr/geler.pl
+share/Yap/clpqr/itf.pl
+share/Yap/clpqr/ordering.pl
share/Yap/clpqr/project.pl
share/Yap/clpqr/redund.pl
-share/Yap/clpqr/store.yap
-share/Yap/clpr.yap
-share/Yap/clpr/arith_r.yap
-share/Yap/clpr/class.yap
-share/Yap/clpr/geler.yap
-share/Yap/clpr/nf.yap
-share/Yap/clpr/nfr.yap
+share/Yap/clpr.pl
+share/Yap/clpr/bb_r.pl
+share/Yap/clpr/bv_r.pl
+share/Yap/clpr/fourmotz_r.pl
+share/Yap/clpr/ineq_r.pl
+share/Yap/clpr/itf_r.pl
+share/Yap/clpr/nf_r.pl
+share/Yap/clpr/store_r.pl
+share/Yap/dbqueues.yap
+share/Yap/debug.pl
+share/Yap/dgraphs.yap
+share/Yap/error.pl
+share/Yap/gensym.yap
+share/Yap/hacks.yap
share/Yap/heaps.yap
share/Yap/icon_address.pl
+share/Yap/itries.yap
+share/Yap/lam_mpi.yap
+share/Yap/lineutils.yap
+share/Yap/listing.yap
share/Yap/lists.yap
-share/Yap/logtalk.yap
-share/Yap/logtalk/logtalk.pl
-share/Yap/logtalk/yap.config
+share/Yap/maplist.pl
+share/Yap/matlab.yap
+share/Yap/matrix.yap
+share/Yap/nb.yap
+share/Yap/occurs.yap
+share/Yap/operators.pl
+share/Yap/option.pl
share/Yap/ordsets.yap
+share/Yap/pairs.pl
share/Yap/pillow.pl
share/Yap/pl/arith.yap
share/Yap/pl/arrays.yap
share/Yap/pl/boot.yap
share/Yap/pl/callcount.yap
share/Yap/pl/checker.yap
+share/Yap/pl/chtypes.yap
share/Yap/pl/consult.yap
share/Yap/pl/corout.yap
share/Yap/pl/debug.yap
share/Yap/pl/depth_bound.yap
share/Yap/pl/directives.yap
+share/Yap/pl/eam.yap
share/Yap/pl/errors.yap
share/Yap/pl/grammar.yap
share/Yap/pl/ground.yap
+share/Yap/pl/hacks.yap
share/Yap/pl/init.yap
share/Yap/pl/listing.yap
share/Yap/pl/load_foreign.yap
+share/Yap/pl/messages.yap
share/Yap/pl/modules.yap
share/Yap/pl/preds.yap
share/Yap/pl/profile.yap
@@ -229,16 +143,27 @@ share/Yap/pl/utils.yap
share/Yap/pl/yapor.yap
share/Yap/pl/yio.yap
share/Yap/prandom.yap
+share/Yap/prolog_source.pl
+share/Yap/prolog_xref.pl
share/Yap/queues.yap
share/Yap/random.yap
share/Yap/rbtrees.yap
+share/Yap/readutil.yap
share/Yap/regexp.yap
+share/Yap/rltree.yap
share/Yap/splay.yap
+share/Yap/stringutils.yap
share/Yap/swi.yap
+share/Yap/swi/apply_macros.pl
share/Yap/system.yap
share/Yap/terms.yap
share/Yap/timeout.yap
share/Yap/trees.yap
share/Yap/tries.yap
share/Yap/ugraphs.yap
+share/Yap/undgraphs.yap
+share/Yap/varnumbers.yap
+share/Yap/wdgraphs.yap
+share/Yap/wgraphs.yap
+share/Yap/wundgraphs.yap
share/Yap/ypp.yap
diff --git a/lang/yap/distinfo b/lang/yap/distinfo
index 99c1e62970c..62868699d7e 100644
--- a/lang/yap/distinfo
+++ b/lang/yap/distinfo
@@ -1,8 +1,14 @@
-$NetBSD: distinfo,v 1.5 2006/01/11 18:35:19 joerg Exp $
+$NetBSD: distinfo,v 1.6 2010/02/11 20:43:49 asau Exp $
-SHA1 (Yap-5.0.0-1/Yap-5.0.0.tar.gz) = 56c6ddc976208f66f49c59f2a6787590d1512732
-RMD160 (Yap-5.0.0-1/Yap-5.0.0.tar.gz) = e63d5ecf66dda0fced26afe9dc9afb892a02762b
-Size (Yap-5.0.0-1/Yap-5.0.0.tar.gz) = 3102749 bytes
+SHA1 (Yap-5.1.3.tar.gz) = 76c84b32ad8fbe8324a1db370f8440be11398c34
+RMD160 (Yap-5.1.3.tar.gz) = b2e1153c7a6853a4814a672992d2b8b3834796bc
+Size (Yap-5.1.3.tar.gz) = 3266063 bytes
SHA1 (patch-aa) = dca2acac805aabd8e2815b509ad516294484ad0f
-SHA1 (patch-ab) = fc4e742886129fac5cbb2195e8aec072c7a3e9ac
-SHA1 (patch-ac) = 4ebf6b8c6c7a9d4cecd2d0d59ee708168c4de60a
+SHA1 (patch-ab) = 76e1a2b4a183215c37ede5c8cbec624e901fe427
+SHA1 (patch-ac) = c0d382127f9bc3a962d01a0da34c99968f7388ab
+SHA1 (patch-ad) = e3765c0d6729b4d531cdea59dc8e442055091d10
+SHA1 (patch-ae) = cf4a79ccd0c34e42ca3d8a108619a9974288cde6
+SHA1 (patch-af) = e49296d42247aec7ead7f65d67a42f93b400ca0f
+SHA1 (patch-ag) = a9f2bfc921f5c2aaf2a92e6659c54047e5c13321
+SHA1 (patch-ah) = 572e29729d97d5e9942a3d2c22e121d4e756d648
+SHA1 (patch-ai) = a702088735520c36ada438e752b1852d9567e5e2
diff --git a/lang/yap/patches/patch-ab b/lang/yap/patches/patch-ab
index a0696dd7bf6..522fb39775b 100644
--- a/lang/yap/patches/patch-ab
+++ b/lang/yap/patches/patch-ab
@@ -1,22 +1,22 @@
-$NetBSD: patch-ab,v 1.1 2006/01/11 18:35:19 joerg Exp $
+$NetBSD: patch-ab,v 1.2 2010/02/11 20:43:49 asau Exp $
---- H/Yap.h.orig 2006-01-11 18:06:46.000000000 +0000
-+++ H/Yap.h
-@@ -237,7 +237,7 @@ extern char Yap_Option[20];
+--- H/Yap.h.orig 2008-05-23 14:02:13.000000000 +0400
++++ H/Yap.h 2009-02-06 21:36:00.000000000 +0300
+@@ -231,7 +231,7 @@
#endif
- #if !IN_SECOND_QUADRANT
+ #if !defined(IN_SECOND_QUADRANT)
-#if __linux__ || __FreeBSD__ || __NetBSD__ || mips || __APPLE__
+#if defined(__linux__) || defined(__FreeBSD__) || defined(__NetBSD__) || defined(mips) || defined(__APPLE__) || defined(__DragonFly__)
#if defined(YAPOR) && defined(__alpha)
#define MMAP_ADDR 0x40000000
-@@ -641,7 +641,7 @@ typedef enum
+@@ -650,7 +650,7 @@
if you place things in the lower addresses (power to the libc people).
*/
--#if (defined(_AIX) || defined(_WIN32) || defined(__APPLE__) || defined(sparc) || defined(__sparc) || defined(mips) || defined(__FreeBSD__) || defined(_POWER) || defined(__linux__) || defined(IN_SECOND_QUADRANT) || defined(__CYGWIN__))
-+#if (defined(_AIX) || defined(_WIN32) || defined(__APPLE__) || defined(sparc) || defined(__sparc) || defined(mips) || defined(__FreeBSD__) || defined(__DragonFly__) || defined(_POWER) || defined(__linux__) || defined(IN_SECOND_QUADRANT) || defined(__CYGWIN__))
+-#if (defined(_AIX) || (defined(__APPLE__) && !defined(__LP64__)) || defined(_WIN32) || defined(sparc) || defined(__sparc) || defined(mips) || defined(__FreeBSD__) || defined(_POWER) || defined(__POWERPC__) || defined(__linux__) || defined(IN_SECOND_QUADRANT) || defined(__CYGWIN__))
++#if (defined(_AIX) || (defined(__APPLE__) && !defined(__LP64__)) || defined(_WIN32) || defined(sparc) || defined(__sparc) || defined(mips) || defined(__FreeBSD__) || defined(__DragonFly__) || defined(_POWER) || defined(__linux__) || defined(IN_SECOND_QUADRANT) || defined(__CYGWIN__))
#define USE_LOW32_TAGS 1
#endif
diff --git a/lang/yap/patches/patch-ac b/lang/yap/patches/patch-ac
index b5a3f15ef39..d65137dc2b1 100644
--- a/lang/yap/patches/patch-ac
+++ b/lang/yap/patches/patch-ac
@@ -1,10 +1,10 @@
-$NetBSD: patch-ac,v 1.1 2006/01/11 18:35:19 joerg Exp $
+$NetBSD: patch-ac,v 1.2 2010/02/11 20:43:49 asau Exp $
---- configure.orig 2006-01-11 18:15:45.000000000 +0000
-+++ configure
-@@ -6058,7 +6058,7 @@ fi
- INSTALL_DLLS=""
- CC="cc -no-cpp-precomp"
+--- configure.orig 2008-05-24 02:29:49.000000000 +0400
++++ configure 2009-02-06 21:25:15.000000000 +0300
+@@ -7002,7 +7002,7 @@
+ JAVALIBPATH="-L/System/Library/Frameworks/JavaVM.framework/Libraries"
+ JAVAINCPATH="-I/System/Library/Frameworks/JavaVM.framework/Headers"
;;
- *netbsd*|*freebsd*)
+ *netbsd*|*freebsd*|*dragonfly*)
diff --git a/lang/yap/patches/patch-ad b/lang/yap/patches/patch-ad
new file mode 100644
index 00000000000..0bd35e88a23
--- /dev/null
+++ b/lang/yap/patches/patch-ad
@@ -0,0 +1,16 @@
+$NetBSD: patch-ad,v 1.1 2010/02/11 20:43:49 asau Exp $
+
+--- C/dlmalloc.c.orig 2008-01-24 03:11:59.000000000 +0300
++++ C/dlmalloc.c 2009-02-06 22:25:05.000000000 +0300
+@@ -2508,7 +2508,11 @@
+ ------------------------------ mallinfo ------------------------------
+ */
+
++#if __STD_C
++struct mallinfo mALLINFo(void)
++#else
+ struct mallinfo mALLINFo()
++#endif
+ {
+ mstate av = get_malloc_state();
+ struct mallinfo mi;
diff --git a/lang/yap/patches/patch-ae b/lang/yap/patches/patch-ae
new file mode 100644
index 00000000000..7c902d7f44d
--- /dev/null
+++ b/lang/yap/patches/patch-ae
@@ -0,0 +1,14 @@
+$NetBSD: patch-ae,v 1.1 2010/02/11 20:43:49 asau Exp $
+
+--- C/c_interface.c.orig 2008-06-17 17:37:48.000000000 +0400
++++ C/c_interface.c 2009-02-06 22:53:50.000000000 +0300
+@@ -326,6 +326,9 @@
+ #if HAVE_STDARG_H
+ #include <stdarg.h>
+ #endif
++#if USE_SYSTEM_MALLOC
++#include <stdlib.h>
++#endif
+ #if HAVE_STRING_H
+ #include <string.h>
+ #endif
diff --git a/lang/yap/patches/patch-af b/lang/yap/patches/patch-af
new file mode 100644
index 00000000000..fd712efd796
--- /dev/null
+++ b/lang/yap/patches/patch-af
@@ -0,0 +1,15 @@
+$NetBSD: patch-af,v 1.1 2010/02/11 20:43:49 asau Exp $
+
+No "struct mallinfo" on NetBSD (?)
+
+--- H/dlmalloc.h.orig 2005-11-23 06:01:33.000000000 +0300
++++ H/dlmalloc.h 2009-04-19 05:14:25.000000000 +0400
+@@ -489,7 +489,7 @@
+ HAVE_USR_INCLUDE_MALLOC_H.
+ */
+
+-#if HAVE_MALLOC_H && !defined(_WIN32)
++#if HAVE_MALLOC_H && !defined(__NetBSD__) && !defined(_WIN32)
+ #define HAVE_USR_INCLUDE_MALLOC_H 1
+ #endif
+
diff --git a/lang/yap/patches/patch-ag b/lang/yap/patches/patch-ag
new file mode 100644
index 00000000000..d89c1f4d7c0
--- /dev/null
+++ b/lang/yap/patches/patch-ag
@@ -0,0 +1,56 @@
+$NetBSD: patch-ag,v 1.1 2010/02/11 20:43:49 asau Exp $
+
+--- LGPL/chr/Makefile.in.orig 2008-04-03 17:26:38.000000000 +0400
++++ LGPL/chr/Makefile.in 2009-04-19 05:42:22.000000000 +0400
+@@ -48,42 +48,42 @@
+ $(srcdir)/Benchmarks/bool.chr $(srcdir)/Benchmarks/family.chr $(srcdir)/Benchmarks/fibonacci.chr $(srcdir)/Benchmarks/leq.chr $(srcdir)/Benchmarks/listdom.chr \
+ $(srcdir)/Benchmarks/chrdif.chr
+
+-all: chr_translate.pl
++all: chr_translate.pl guard_entailment.pl
+
+ chr_translate_bootstrap1.pl: $(srcdir)/chr_translate_bootstrap1.chr
+ $(PL) -f -l chr_swi_bootstrap.yap \
+- -g "chr_compile_step1('$<','$@'),halt." \
++ -g "chr_compile_step1('$>','$@'),halt." \
+ -z 'halt(1).'
+ $(PL) -f -l chr_swi_bootstrap.yap \
+- -g "chr_compile_step2('$<','$@'),halt." \
++ -g "chr_compile_step2('$>','$@'),halt." \
+ -z 'halt(1).'
+
+ chr_translate_bootstrap2.pl: $(srcdir)/chr_translate_bootstrap2.chr chr_translate_bootstrap1.pl
+ $(PL) -f -l chr_swi_bootstrap.yap \
+- -g "chr_compile_step2('$<','$@'),halt." \
++ -g "chr_compile_step2('$>','$@'),halt." \
+ -z 'halt(1).'
+ $(PL) -f -l chr_swi_bootstrap.yap \
+- -g "chr_compile_step3('$<','$@'),halt." \
++ -g "chr_compile_step3('$>','$@'),halt." \
+ -z 'halt(1).'
+
+ guard_entailment.pl: $(srcdir)/guard_entailment.chr chr_translate_bootstrap2.pl
+ $(PL) -f -l chr_swi_bootstrap.yap \
+- -g "chr_compile_step3('$<','$@'),halt." \
++ -g "chr_compile_step3('$>','$@'),halt." \
+ -z 'halt(1).'
+
+ chr_translate.pl: $(srcdir)/chr_translate.chr chr_translate_bootstrap2.pl guard_entailment.pl
+ $(PL) -f -l chr_swi_bootstrap.yap \
+- -g "chr_compile_step3('$<','$@'),halt." \
++ -g "chr_compile_step3('$>','$@'),halt." \
+ -z 'halt(1).'
+ $(PL) -f -p chr=. -l chr_swi_bootstrap.yap \
+ -g "chr_compile_step4('guard_entailment.chr','guard_entailment.pl'),halt." \
+ -z 'halt(1).'
+ $(PL) -f -p chr=. -l chr_swi_bootstrap.yap \
+- -g "chr_compile_step4('$<','$@'),halt." \
++ -g "chr_compile_step4('$>','$@'),halt." \
+ -z 'halt(1).'
+
+ chr.pl: chr_swi.pl
+- cp $< $@
++ cp $> $@
+
+ install: chr_translate.pl guard_entailment.pl
+ mkdir -p $(DESTDIR)$(CHRDIR)
diff --git a/lang/yap/patches/patch-ah b/lang/yap/patches/patch-ah
new file mode 100644
index 00000000000..0cb42b7e801
--- /dev/null
+++ b/lang/yap/patches/patch-ah
@@ -0,0 +1,15 @@
+$NetBSD: patch-ah,v 1.1 2010/02/11 20:43:49 asau Exp $
+
+--- library/system/sys.c.orig 2008-05-23 17:16:13.000000000 +0400
++++ library/system/sys.c 2009-04-20 13:00:04.000000000 +0400
+@@ -97,6 +97,10 @@
+ #if HAVE_TIME_H
+ #include <time.h>
+ #endif
++#if !HAVE_DAYLIGHT
++time_t _daylight_() { time_t t = time(NULL); return localtime(&t)->tm_gmtoff; }
++#define daylight _daylight_()
++#endif
+ #if HAVE_SYS_TYPES_H
+ #include <sys/types.h>
+ #endif
diff --git a/lang/yap/patches/patch-ai b/lang/yap/patches/patch-ai
new file mode 100644
index 00000000000..e75e8c5a26f
--- /dev/null
+++ b/lang/yap/patches/patch-ai
@@ -0,0 +1,15 @@
+$NetBSD: patch-ai,v 1.1 2010/02/11 20:43:49 asau Exp $
+
+Disable parts to avoid breakage.
+
+--- Makefile.in.orig 2008-06-04 18:47:18.000000000 +0400
++++ Makefile.in 2009-12-11 05:30:54.000000000 +0300
+@@ -659,7 +659,7 @@
+ @INSTALLCLP@(cd LGPL/clp ; make install)
+ @INSTALLCLP@(cd GPL/clpqr ; make install)
+ # (cd CHR ; make install)
+- @INSTALLCLP@(cd LGPL/chr ; make install)
++# @INSTALLCLP@(cd LGPL/chr ; make install)
+ @INSTALLCLP@(cd CLPBN ; make install)
+
+