Porting pdfedit-0.3.1
Michael Pope
michael at dtcorp.com.au
Tue Oct 23 22:17:44 PDT 2007
I would like to port and application across and have read the porters
handbook, but I'm still having trouble porting this app to freebsd6.2.
The procedure I use to manually install pdfedit 0.3.1 under bsd is:
FreeBSD build
------------------------------------------------------------------------
Here is the short howto for PDFedit compilation and installation on FreeBSD 6.2
(Qt 3.38, Xorg 7.2). Thanks to Hao Chen.
# untar current sources (this was done for 0.3.1 version)
tar zxvf pdfedit-0.3.1.tar.bz2
cd pdfedit-0.3.1
setenv QTDIR /usr/local
setenv QMAKESPEC /usr/local/share/qt/mkspecs/freebsd-g++
setenv LOCALBASE /usr/local
%./configure -- CPPFLAGS="-I /usr/local/include" LDFLAG="-L /usr/local/include"
% cd src/xpdf
% ./configure --with-t1-library="${LOCALBASE}/lib" --with-t1-includes="${LOCALBASE}/include"
#make sure you see this:
#checking for T1_InitLib in -lt1... yes
#using t1 library
% cd ../..
Edit src/utils/Makefile INCPATH line and add '-I/usr/local/include' to the end.
% make
------------------------------------------------------------------------
I've tried to make my Makefile and have ended up with:
# New ports collection makefile for: pdfedit
#
PORTNAME= pdfedit
PORTVERSION= 0.3.1
PORTREVISION= 1
CATEGORIES= graphics print
MASTER_SITES= http://optusnet.dl.sourceforge.net/sourceforge/pdfedit/
MAINTAINER= michael at dtcorp.com.au
COMMENT= a pdf editor which allows you to annotate and save back
to a pdf.
BUILD_DEPENDS= freetype-config:${PORTSDIR}/print/freetype2
LIB_DEPENDS= t1.5:${PORTSDIR}/devel/t1lib \
freetype.9:${PORTSDIR}/print/freetype2
RUN_DEPENDS=
${LOCALBASE}/share/ghostscript/fonts/n021003l.pfb:${PORTSDIR}/print/gsfonts
USE_AUTOTOOLS= autoconf:261
CONFIGURE_TARGET= --build=${MACHINE_ARCH}-portbld-freebsd${OSREL}
CONFIGURE_ENV= QTDIR="${LOCALBASE}/usr/local" \
QMAKESPEC="${LOCALBASE}/share/qt/mkspecs/freebsd-g++" \
CPPFLAGS="-I${LOCALBASE}/include" \
LDFLAGS="-L${LOCALBASE}/lib"
INCPATH= -I/usr/local/include
CONFIGURE_ARGS= --with-t1-library="/usr/local/lib" \
--with-t1-includes="/usr/local/include"
MAN1= pdfedit.1
.include <bsd.port.mk>
So should I be making a patch file for the extra include I have to enter
into src/utils/Makefile?
If so how do I automate that patch for that file? Currently i've
created a little patch called 'patch-src-utils-Makefile' but every time
I run make it asks me which file I want to patch.
I don't think that second configure is happening in the src/xpdf
directory, where should I do this? in 'post-configure'?
Maybe I've just selected a hard one for my first porting experience. I
just started here because that's an application I use a lot and would
like it in the ports collection.
--
Michael
More information about the freebsd-ports
mailing list