Skip to content
Permalink
Browse files

Fixed the labltk variant. This fixes problems with lablgtk.

Bug:            https://trac.macports.org/ticket/1394
Submitted by:
Reviewed by:
Approved by:
Obtained from:

git-svn-id: https://svn.macports.org/repository/macports/trunk/dports@4520 d073be05-634f-4543-b044-5fe20cf6d1d6
  • Loading branch information
pguyot committed Jan 8, 2004
1 parent c7b7754 commit c93f9671dd0fa92d8f7e0a08be04b18ce6e336f3
Showing with 40 additions and 2 deletions.
  1. +7 −2 lang/ocaml/Portfile
  2. +33 −0 lang/ocaml/files/patch-configure
@@ -1,8 +1,9 @@
# $Id: Portfile,v 1.11 2004/01/06 16:13:06 mww Exp $
# $Id: Portfile,v 1.12 2004/01/08 05:42:57 pguyot Exp $

PortSystem 1.0
name ocaml
version 3.07pl2
revision 1
categories lang
maintainers jpm@opendarwin.org
description Latest implementation of the Caml dialect of ML
@@ -27,7 +28,7 @@ configure.args --no-tk \
--tk-no-x11 \
--bindir ${prefix}/bin \
--libdir ${prefix}/lib/ocaml \
--mandir ${prefix}/share/man \
--mandir ${prefix}/share/man

build.type gnu
build.dir ${worksrcpath}
@@ -43,4 +44,8 @@ variant labltk {
lib:tk8.4:tk
configure.args-delete --no-tk \
--tk-no-x11
patchfiles patch-configure
post-patch {
reinplace "s|__PREFIX|${prefix}|g" ${worksrcpath}/configure
}
}
@@ -0,0 +1,33 @@
--- configure.old Thu Jan 8 01:29:08 2004
+++ configure Thu Jan 8 01:29:41 2004
@@ -1325,6 +1325,10 @@
tk_defs="-I/sw/include"
tcl_version=`sh ./runtest $tk_defs $tk_x11_include tclversion.c`
fi
+ if test -z "$tcl_version"; then
+ tk_defs="-I__PREFIX/include -I/System/Library/Frameworks/Tcl.framework/Versions/8.4/Headers/"
+ tcl_version=`sh ./runtest $tk_defs $tk_x11_include tclversion.c`
+ fi
if test -n "$tcl_version"; then
echo "tcl.h version $tcl_version found with \"$tk_defs\"."
case $tcl_version in
@@ -1376,6 +1380,9 @@
elif sh ./hasgot -L/sw/lib $tk_libs -ltcl$tclmaj.$tclmin $tkauxlibs \
Tcl_DoOneEvent
then tk_libs="-L/sw/lib -ltk$tkmaj.$tkmin -ltcl$tclmaj.$tclmin $dllib"
+ elif sh ./hasgot -L__PREFIX/lib $tk_libs -ltcl$tclmaj.$tclmin $tkauxlibs \
+ Tcl_DoOneEvent
+ then tk_libs="-L__PREFIX/lib -ltk$tkmaj.$tkmin -ltcl$tclmaj.$tclmin $dllib"
else
echo "Tcl library not found."
has_tk=false
@@ -1386,6 +1393,9 @@
echo "Tcl/Tk libraries found."
elif sh ./hasgot -L/sw/lib $tk_libs $tk_x11_libs $tkauxlibs Tk_SetGrid; then
tk_libs="-L/sw/lib $tk_libs"
+ echo "Tcl/Tk libraries found."
+ elif sh ./hasgot -L__PREFIX/lib $tk_libs $tk_x11_libs $tkauxlibs Tk_SetGrid; then
+ tk_libs="-L__PREFIX/lib $tk_libs"
echo "Tcl/Tk libraries found."
else
echo "Tcl library found."

0 comments on commit c93f967

Please sign in to comment.
You can’t perform that action at this time.