# $Id: Portfile,v 1.2 2006/02/27 04:27:55 ben Exp $ set kdeadmin kde-admindir-3.4.3-2 PortSystem 1.0 name koffice version 1.4.2 categories kde maintainers ben@opendarwin.org takanori@opendarwin.org description KDE office suite. \ NB KDE sound does not work. \ ** This port needs testing ** platforms darwin master_sites kde:stable/${name}-${version}/src \ http://ranger.befunk.com/fink/:admin extract.suffix .tar.bz2 use_bzip2 yes distname ${name}-${version} distfiles ${distname}.tar.bz2 ${kdeadmin}.tar.bz2:admin depends_build port:autoconf \ port:automake depends_lib port:kdebase3 \ port:mysql4 \ port:ImageMagick # port:postgresql8 # libwpd-0.8 # wv2 checksums ${distname}.tar.bz2 md5 6b456fb7d54c84b11396b27a96ae0cf8 \ ${kdeadmin}.tar.bz2 md5 1dcacf64a5a196786f49b6c34f5a33d0 extract.only ${distname}.tar.bz2 post-extract { system "cd ${worksrcpath} && bzcat -dc ${distpath}/${kdeadmin}.tar.bz2 | tar xf -" } patchfiles koffice.patch patch { cd ${worksrcpath} foreach file $patchfiles { system "sed -e 's,@FINKPREFIX@,${prefix},g' ${portpath}/${filesdir}/${file} | patch -p1" } } post-patch { reinplace "s|lib/freetype219/||g" ${worksrcpath}/environment-helper.sh foreach file [glob ${worksrcpath}/admin/*] { reinplace "s|-O2|-Os|g" $file reinplace "s|doc/HTML|doc/kde|g" $file reinplace "s|/usr/share/doc/packages/qt3/html|${prefix}/share/doc/qt3/html|g" $file reinplace "s|HAVE_GCC_VISIBILITY=1|HAVE_GCC_VISIBILITY=0|g" $file reinplace "s|-fvisibility=hidden -fvisibility-inlines-hidden||g" $file } foreach file {CompileScript.sh InstallScript.sh} { file copy ${portpath}/${filesdir}/${file} ${worksrcpath} reinplace "s|%p|${prefix}|g" ${worksrcpath}/${file} reinplace "s|%N|${name}|g" ${worksrcpath}/${file} reinplace "s|%v|${version}|g" ${worksrcpath}/${file} reinplace "s|%r|${revision}|g" ${worksrcpath}/${file} reinplace "s|%c|${configure.args}|g" ${worksrcpath}/${file} reinplace "s|%d|${destroot}|g" ${worksrcpath}/${file} reinplace "s|%i|${destroot}${prefix}|g" ${worksrcpath}/${file} file attributes ${worksrcpath}/${file} -permissions 0755 } } configure.args --includedir=${prefix}/include --libdir=${prefix}/lib --prefix=${prefix} --with-qt-dir=${prefix} --with-qt-includes=${prefix}/include/qt3 --with-extra-libs=${prefix}/lib --with-extra-includes=${prefix}/include --enable-mt --with-pic --enable-rpath --enable-shared=yes --enable-static=no --mandir=${destroot}${prefix}/share/man --with-xinerama --with-pam --disable-final --enable-mysql --with-mysql-includes=${prefix}/include/mysql --with-mysql-libraries=${prefix}/lib --with-distribution='DarwinPorts/Mac OS X' --disable-dependency-tracking --without-arts # (libpqxx is missing.) # --enable-pgsql --with-pgsqlincdir=${prefix}/include/pgsql8 --with-pgsqllibdir=${prefix}/lib/pgsql8 --with-pqxxincdir=${prefix}/include --with-pqxxlibdir=${prefix}/lib configure {} build { system "cd ${worksrcpath} && ./CompileScript.sh" } destroot { system "cd ${worksrcpath} && ./InstallScript.sh" } post-destroot { xinstall -m 755 -d ${destroot}${prefix}/share/doc/${name} xinstall -m 644 -W ${worksrcpath} AUTHORS COPYING COPYING.LIB INSTALL README ${destroot}${prefix}/share/doc/${name} } platform darwin 6 { depends_lib-append lib:libdl:dlcompat }