From owner-freebsd-ports@FreeBSD.ORG Mon Sep 19 16:58:06 2005 Return-Path: X-Original-To: freebsd-ports@freebsd.org Delivered-To: freebsd-ports@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id BAB0716A420 for ; Mon, 19 Sep 2005 16:58:06 +0000 (GMT) (envelope-from patrick_dkt@yahoo.com.hk) Received: from web54302.mail.yahoo.com (web54302.mail.yahoo.com [206.190.49.112]) by mx1.FreeBSD.org (Postfix) with SMTP id 0F24E43D46 for ; Mon, 19 Sep 2005 16:58:05 +0000 (GMT) (envelope-from patrick_dkt@yahoo.com.hk) Received: (qmail 28961 invoked by uid 60001); 19 Sep 2005 16:58:05 -0000 DomainKey-Signature: a=rsa-sha1; q=dns; c=nofws; s=s1024; d=yahoo.com.hk; h=Message-ID:Received:Date:From:Subject:To:Cc:In-Reply-To:MIME-Version:Content-Type:Content-Transfer-Encoding; b=nEeGJnRT4ejB0L1Aaepz0wENcYRBcDZfppixkiLwQOigwCJGpCa9T11T8g2cfM0vpJ8HlKACRmSE4bpLwEAjATwWwC4cI9OKg6ODpAZbeBCLVvSZLr1fLUVbPZgCdA1qVI7fEwaAzWxZKrBXdkMcGaZ6gxZcWcUvi07YBcH6ZNo= ; Message-ID: <20050919165805.28959.qmail@web54302.mail.yahoo.com> Received: from [222.166.160.92] by web54302.mail.yahoo.com via HTTP; Mon, 19 Sep 2005 09:58:05 PDT Date: Mon, 19 Sep 2005 09:58:05 -0700 (PDT) From: Patrick Dung To: Gerald Pfeifer In-Reply-To: MIME-Version: 1.0 Content-Type: text/plain; charset=iso-8859-1 Content-Transfer-Encoding: 8bit Cc: ssteward@AccessPDF.com, Jim Trigg , freebsd-ports@freebsd.org Subject: Re: Request gcc 34 port build gcj X-BeenThere: freebsd-ports@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Porting software to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 19 Sep 2005 16:58:06 -0000 Hi I have noticed that file at the end of August. I have email a proposed solution to pdftk's author. Below is my mail to the author/ Note that I can 'fix' pdftk to build with gcj41 but the resulting binary core dump. BTW, from author's web site: http://www.pdfhacks.com/pdftk/#build You see that: I build pdftk using gcc/gcj/libgcj versions 3.3.4. So I think gcj34 is the best thing to compile pdftk. Patrick > Hi Sid Steward > > When I was trying to compile pdftk 1.2.1 with gcj41 in FreeBSD, I have > discovered something. > > 1. There is a compile error in itext's pdf/codecs/PngImage.java about > the ICC profile. I have seen you have comment out > import com.lowagie.text.ImgRaw > > After enabling this line, I can complie this class with gcj41. > > 2. Makefile.Base include convert.a static lib (from your source). > Makefile.Generic has include -lgcj. > When compiling pdftk binary and linking all the libraries, it said > duplicate defination or something. Comment out the convert.a line in > Makefile.Base won't have that error. > > 3. It has linking problem with libiconv, I don't know it's FreeBSD OS > problem, FreeBSD's gcc 41 problem or pdftk problem. This problem is not > seen in pdftk with gcj 3.x. > Then I use the static library of libiconv instead of the shared lib to > make it compile the pdftk binary. > > 4. The resulting pdftk binary cannot be run. It will have core dump. > Signal 6. Seems problem with FreeBSD's libpthread. > > I hope this will help in your new version of pdftk. > > Regards > Patrick --- Gerald Pfeifer wrote: > On Sat, 17 Sep 2005, Patrick Dung wrote: > > I think the problem should also appear in Linux with pdftk and gcj > 4.1 > > because the problem is related to itext that comes with pdftk and > > gcj41. > > That's a good point. I'm attaching the respective two files from the > current SUSE tree (one patch and the RPM spec file) which uses GCC > 4.0. > > Does this help? Otherwise, looking at Fedora sources might be > interesting. > > Gerald> diff -Naur > pdftk-1.12.orig/java_libs/com/lowagie/text/pdf/codec/PngImage.java > pdftk-1.12/java_libs/com/lowagie/text/pdf/codec/PngImage.java > --- > pdftk-1.12.orig/java_libs/com/lowagie/text/pdf/codec/PngImage.java > 2004-05-27 00:06:12.000000000 +0200 > +++ pdftk-1.12/java_libs/com/lowagie/text/pdf/codec/PngImage.java > 2005-08-22 12:08:55.000000000 +0200 > @@ -93,7 +93,7 @@ > > import com.lowagie.text.ExceptionConverter; > import com.lowagie.text.Image; > -//SID import com.lowagie.text.ImgRaw; > +import com.lowagie.text.ImgRaw; > import com.lowagie.text.pdf.ByteBuffer; > import com.lowagie.text.pdf.PdfArray; > import com.lowagie.text.pdf.PdfDictionary; > > # > # spec file for package pdftk (Version 1.12) > # > # Copyright (c) 2005 SUSE LINUX Products GmbH, Nuernberg, Germany. > # This file and all modifications and additions to the pristine > # package are under the same license as the package itself. > # > # Please submit bugfixes or comments via http://www.suse.de/feedback/ > # > > # neededforbuild gcc-java gpp libgcj libgcj-devel libgpp > > BuildRequires: aaa_base acl attr bash bind-utils bison bzip2 > coreutils cpio cpp cracklib cvs cyrus-sasl db devs diffutils > e2fsprogs file filesystem fillup findutils flex gawk gdbm-devel > gettext-devel glibc glibc-devel glibc-locale gpm grep groff gzip info > insserv klogd less libacl libattr libcom_err libgcc libnscd > libselinux libstdc++ libxcrypt libzio m4 make man mktemp > module-init-tools ncurses ncurses-devel net-tools netcfg > openldap2-client openssl pam pam-modules patch permissions popt > procinfo procps psmisc pwdutils rcs readline sed strace sysvinit tar > tcpd texinfo timezone unzip util-linux vim zlib zlib-devel autoconf > automake binutils gcc gcc-c++ gcc-java gdbm gettext libgcj > libgcj-devel libstdc++-devel libtool perl rpm > > Name: pdftk > Summary: The PDF Toolkit > Version: 1.12 > Release: 4 > License: GPL > URL: http://www.accesspdf.com/pdftk/ > Source0: %{name}-%{version}.tar.bz2 > Patch0: %{name}-%{version}.patch > Group: Productivity/Publishing/PDF > BuildRoot: %{_tmppath}/%{name}-%{version}-build > Requires: libgcj > > %description > Pdftk is a command-line tool for manipulating PDF documents. Use it > to > merge, split PDF pages into a new document, decrypt input as > necessary > (password required), encrypt output as desired, fill PDF forms with > FDF > data, flatten forms, apply a background watermark, repair a corrupted > PDF (where possible), and many others. > > > > Authors: > -------- > Sid Steward > > %prep > %setup -q > %patch0 -p1 > > %build > %{suse_update_config -fl} > unset CLASSPATH && cd pdftk && make -f Makefile.RedHat && cd - > > %install > rm -rf $RPM_BUILD_ROOT > mkdir -p $RPM_BUILD_ROOT/%{_bindir} > mkdir -p $RPM_BUILD_ROOT/%{_mandir}/man1 > install -m 0755 pdftk/pdftk $RPM_BUILD_ROOT/%{_bindir}/pdftk > install -m 0644 debian/pdftk.1 > $RPM_BUILD_ROOT/%{_mandir}/man1/pdftk.1 > gzip $RPM_BUILD_ROOT/%{_mandir}/man1/pdftk.1 > > %clean > rm -rf $RPM_BUILD_ROOT > > %files > %defattr(-,root,root) > %doc pdftk.1.html pdftk.1.notes pdftk.1.txt > %{_bindir}/* > %{_mandir}/man1/* > > %changelog -n pdftk > * Mon Aug 22 2005 - skh@suse.de > - Fix build. > * Wed Jan 26 2005 - ke@suse.de > - New package proposed by Thomas Schraitle; version 1.12. > > _______________________________________________ > freebsd-ports@freebsd.org mailing list > http://lists.freebsd.org/mailman/listinfo/freebsd-ports > To unsubscribe, send any mail to "freebsd-ports-unsubscribe@freebsd.org" __________________________________ Yahoo! Mail - PC Magazine Editors' Choice 2005 http://mail.yahoo.com