# $Id$ PortSystem 1.0 name itk version 3.3 revision 2 categories x11 tk maintainers nomaintainer description \[incr Tk\] A.K.A. \"itk\". Object oriented extension to Tk. long_description ${description} homepage http://incrtcl.sourceforge.net/itk/itk.html platforms darwin master_sites sourceforge:incrtcl:itk \ sourceforge:tcl:tcl distname ${name}${version} # Set tclv and md5 checksum to the current MacPorts Tcl port version, though port doesn't # break if they aren't in sync. set tclv 8.4.14 distfiles ${distname}.tar.gz:itk \ tcl${tclv}-src.tar.gz:tcl checksums ${name}${version}.tar.gz md5 a97c17f3cfa5e377f43073c653c501b5 \ tcl${tclv}-src.tar.gz md5 51c6bf74d3ffdb0bd866ecdac6ff6460 depends_build port:tk port:itcl build.args CPPFLAGS=-I${prefix}/include worksrcdir ${name}${version} set tclconfig ${prefix}/lib configure.env TCLROOT=${prefix} configure.cflags -I${workpath}/tcl${tclv}/generic configure.ldflags-append "-ltcl -L/usr/X11R6/lib -lX11" configure.args --with-tcl=${tclconfig} \ --with-itcl=${prefix}/lib/itcl3.3 \ --with-tk=${prefix}/lib platform darwin 7 { global tclconfig set tclconfig /System/Library/Frameworks/Tcl.framework } post-patch { reinplace "s|@itk_LIB_SPEC@|-L${prefix}/lib -litk|g" \ ${worksrcpath}/itkConfig.sh.in reinplace "s|@ITK_BUILD_LIB_SPEC@|-L${prefix}/lib -litk|g" \ ${worksrcpath}/itkConfig.sh.in reinplace "s|\"@PKG_LIB_FILE@\"|.. @PKG_LIB_FILE@|g" \ ${worksrcpath}/pkgIndex.tcl.in } destroot { set _d ${destroot}${prefix} set _w ${worksrcpath} file mkdir -p ${_d}/lib/itk3.3 xinstall -m 755 ${_w}/itkConfig.sh ${_d}/lib/itk3.3 foreach x [glob ${worksrcpath}/library/*] { file copy -force $x ${_d}/lib/itk3.3 } file copy -force ${_w}/pkgIndex.tcl ${_d}/lib/itk3.3 file copy -force ${_w}/libitk3.3.dylib ${_d}/lib file mkdir -p ${_d}/include foreach x {itk.h itkDecls.h } { file copy -force ${_w}/generic/$x ${_d}/include } foreach x [glob ${_w}/doc/*.n] { file copy -force $x ${_d}/share/man/mann file delete -force ${_d}/share/man/mann/Toplevel.n } }