. Have c2hs-config return the right -package flags

. Keep the version number in lib/c2hs-${V}
. Add haskell package "lang" as a dependency

ok pvalchev@
This commit is contained in:
dons 2004-05-09 07:46:12 +00:00
parent 8d3e176d2b
commit df59dba23b
4 changed files with 36 additions and 44 deletions

View File

@ -0,0 +1,16 @@
$OpenBSD: patch-c2hs_c2hs-config_in,v 1.1 2004/05/09 07:46:12 dons Exp $
Have the old (non-package) configuration tool report the correct paths
to the library
--- c2hs/c2hs-config.in.orig 2002-07-12 14:39:46.000000000 +1000
+++ c2hs/c2hs-config.in 2004-05-09 15:20:56.000000000 +1000
@@ -74,7 +74,7 @@ fi
if test x$has_pkg = xyes; then
if test "$echo_cflags" = "yes" -o "$echo_libs" = "yes"; then
if test "$pkg_added" != "yes"; then
- echo -n "-package-conf $pkg_conf "
+ echo -n ""
fi
echo "-package c2hs"
fi

View File

@ -1,24 +1,20 @@
$OpenBSD: patch-c2hs_c2hs_conf_in,v 1.1.1.1 2004/05/08 07:21:03 dons Exp $
$OpenBSD: patch-c2hs_c2hs_conf_in,v 1.2 2004/05/09 07:46:12 dons Exp $
Better package.conf.in. lang => haskell98
Better package.conf.in. add haskell98 6.2.1ism
--- c2hs/c2hs.conf.in.orig 2002-02-13 15:49:06.000000000 +1100
+++ c2hs/c2hs.conf.in 2004-05-08 14:17:22.000000000 +1000
@@ -1,16 +1,14 @@
+++ c2hs/c2hs.conf.in 2004-05-09 15:20:56.000000000 +1000
@@ -1,4 +1,3 @@
-[
Package {
name = "c2hs",
- import_dirs = ["@LIBDIR@/c2hs-@C2HS_VERSION@/@SYS@/import"],
+ import_dirs = ["${PREFIX}/lib/c2hs/imports"],
source_dirs = [],
- library_dirs = ["@LIBDIR@/c2hs-@C2HS_VERSION@/@SYS@"],
+ library_dirs = ["${PREFIX}/lib/c2hs"],
hs_libraries = ["c2hs"],
import_dirs = ["@LIBDIR@/c2hs-@C2HS_VERSION@/@SYS@/import"],
@@ -8,9 +7,8 @@ Package {
extra_libraries = [],
include_dirs = [],
c_includes = [],
- package_deps = ["lang"],
+ package_deps = ["haskell98"],
+ package_deps = ["lang","haskell98"],
extra_ghc_opts = ["-fglasgow-exts"],
extra_cc_opts = [],
extra_ld_opts = []

View File

@ -1,21 +0,0 @@
$OpenBSD: patch-mk_config_mk_in,v 1.1.1.1 2004/05/08 07:21:03 dons Exp $
Canonical install directory
--- mk/config.mk.in.orig 2004-05-08 13:27:43.000000000 +1000
+++ mk/config.mk.in 2004-05-08 13:28:09.000000000 +1000
@@ -72,10 +72,10 @@ DESTDIR =
# the $(PACKAGE) variable is set by the toplevel Makefile in each compiler
# package
#
-pkgdatadir = $(datadir)/$(PACKAGE)-$(PCKVERSION)
-pkgdocdir = $(docdir)/$(PACKAGE)-$(PCKVERSION)
-pkglibdir = $(libdir)/$(PACKAGE)-$(PCKVERSION)/$(SYS)
-pkgimportdir = $(pkglibdir)/import
+pkgdatadir = $(datadir)/$(PACKAGE)
+pkgdocdir = $(docdir)/$(PACKAGE)
+pkglibdir = $(libdir)/$(PACKAGE)
+pkgimportdir = $(pkglibdir)/imports
# Haskell compiler: for details in the supported systems check

View File

@ -1,20 +1,21 @@
@comment $OpenBSD: PLIST,v 1.1.1.1 2004/05/08 07:21:03 dons Exp $
@comment $OpenBSD: PLIST,v 1.2 2004/05/09 07:46:12 dons Exp $
bin/c2hs
bin/c2hs-config
lib/c2hs/c2hs.conf
lib/c2hs/imports/C2HS.hi
lib/c2hs/imports/C2HSBase.hi
lib/c2hs/imports/C2HSDeprecated.hi
lib/c2hs/imports/C2HSMarsh.hi
lib/c2hs/imports/NewStablePtr.hi
lib/c2hs/imports/NewStorable.hi
lib/c2hs/libc2hs.a
lib/c2hs-0.12.0/ghc6/c2hs.conf
lib/c2hs-0.12.0/ghc6/import/C2HS.hi
lib/c2hs-0.12.0/ghc6/import/C2HSBase.hi
lib/c2hs-0.12.0/ghc6/import/C2HSDeprecated.hi
lib/c2hs-0.12.0/ghc6/import/C2HSMarsh.hi
lib/c2hs-0.12.0/ghc6/import/NewStablePtr.hi
lib/c2hs-0.12.0/ghc6/import/NewStorable.hi
lib/c2hs-0.12.0/ghc6/libc2hs.a
man/man1/c2hs-config.1
man/man1/c2hs.1
@dirrm lib/c2hs/imports
@dirrm lib/c2hs
@dirrm lib/c2hs-0.12.0/ghc6/import
@dirrm lib/c2hs-0.12.0/ghc6
@dirrm lib/c2hs-0.12.0
@comment call ghc-pkg to register/unregister this library with ghc
@exec cat %D/lib/c2hs/c2hs.conf | /usr/bin/env PREFIX=%D %D/bin/ghc-pkg -u
@exec cat %D/lib/c2hs-0.12.0/ghc6/c2hs.conf | /usr/bin/env PREFIX=%D %D/bin/ghc-pkg -u
@exec /bin/rm -f %D/lib/ghc-6.2.1/package.conf.old
@unexec %D/bin/ghc-pkg -r c2hs
@unexec /bin/rm -f %D/lib/ghc-6.2.1/package.conf.old