pkgname=multisync
pkgver=0.80
pkgrel=1
pkgdesc="A free modular program to synchronize calendars,
addressbooks and other PIM data"
url="http://www.multisync.org"
depends=('esd' 'openssl' 'gtk2' 'libgnomeui')
conflicts=()
backup=()
install=
source=(http://heanet.dl.sourceforge.net/sourceforge/multisync/multisync-0.80-1.tar.gz)
md5sums=('f1b1ff5665d7de82b2a2948752b818c7')
build() {
cd $startdir/src/$pkgname-$pkgver
./autogen.sh --prefix=/usr
make || return 1
make DESTDIR=$startdir/pkg install
}
Building one of the plugins, evolution_sync, I ran into some trouble.
I'm using this PKGBUILD (following red_over_blue's advice to keep it simple at first)
pkgname=evolution_sync
pkgver=0.80
pkgrel=1
pkgdesc="Ximian Evolution synchronization, supporting calendar, ToDos and contacts for Multisync"
url="http://www.multisync.org"
depends=()
conflicts=()
backup=()
install=
source=(http://heanet.dl.sourceforge.net/sourceforge/multisync/multisync-0.80-1.tar.gz)
build() {
cd $startdir/src/multisync-0.80/plugins/evolution_sync
./autogen.sh --prefix=/usr --with-evo-libs=/opt/gnome/lib/evolution/1.4
make || return 1
make DESTDIR=$startdir/pkg install
}
It goes to the correct dir (a subdir in the multisync source pkg) and configures and starts make. It ends on this:
make all-recursive
make[1]: Entering directory `/home/hcman/sources/pkgs/evolution_sync/src/multisync-0.80/plugins/evolution_sync'
Making all in libversit
make[2]: Entering directory `/home/hcman/sources/pkgs/evolution_sync/src/multisync-0.80/plugins/evolution_sync/libversit'
if /bin/sh ../libtool --mode=compile gcc -DHAVE_CONFIG_H -I. -I. -I.. -DORBIT2=1 -pthread -I/opt/gnome/include/evolution-1.4 -I/opt/gnome/include/gconf/2 -I/opt/gnome/include/libbonobo-2.0 -I/opt/gnome/include/gal-2.0 -I/opt/gnome/include/libgnome-2.0 -I/opt/gnome/include/orbit-2.0 -I/opt/gnome/include/bonobo-activation-2.0 -I/opt/gnome/include/libglade-2.0 -I/opt/gnome/include/libgnomeprint-2.2 -I/opt/gnome/include/gnome-vfs-2.0 -I/opt/gnome/lib/gnome-vfs-2.0/include -I/opt/gnome/include/libgnomeui-2.0 -I/opt/gnome/include/libgnomecanvas-2.0 -I/opt/gnome/include/libbonoboui-2.0 -I/usr/include/glib-2.0 -I/usr/lib/glib-2.0/include -I/usr/include/gtk-2.0 -I/usr/include/libxml2 -I/usr/lib/gtk-2.0/include -I/usr/include/atk-1.0 -I/usr/include/pango-1.0 -I/usr/X11R6/include -I/usr/X11R6/include/freetype2 -I/usr/include/libart-2.0 -g -O2 -MT vcc.lo -MD -MP -MF ".deps/vcc.Tpo"
-c -o vcc.lo `test -f 'vcc.c' || echo './'`vcc.c;
then mv -f ".deps/vcc.Tpo" ".deps/vcc.Plo";
else rm -f ".deps/vcc.Tpo"; exit 1;
fi
../libtool: ../libtool: No such file or directory
make[2]: *** [vcc.lo] Error 1
make[2]: Leaving directory `/home/hcman/sources/pkgs/evolution_sync/src/multisync-0.80/plugins/evolution_sync/libversit'
make[1]: *** [all-recursive] Error 1
make[1]: Leaving directory `/home/hcman/sources/pkgs/evolution_sync/src/multisync-0.80/plugins/evolution_sync'
make: *** [all] Error 2
When I run a regular ./configure, make it gives me the same thing so I'm thinking (hoping) it's not my PKGBUILD this time... :-)
Does it have something to with libtool since it complains it cannot find that?
HC
]]>When I figure out the dependencies and make sure it builds/installs/works well I will upload it.
I'm working on one of the plugins now.
Is it customary to build plugins as seperate packages?
HC
]]>hcman,
I just looked at your PKGBUILD again, and there is no need to create that directory at all. You are getting the error I posted about because of the following line in your PKGBUILD, which is not necessary:
mv $startdir/pkg/usr/sbin $startdir/pkg
When trying to make a package, it is usually easiest to keep things as simple as possibel at first, following the directions given in the INSTALL file that (hopefully) comes with the package.
Also, another tip, try to use DESTDIR during the "make install" portion, as it is more robust that prefix.
You can also get the md5sum for the package by running "makepkg -g" and it will print the md5sum line that you should include in the PKGBUILD.
Finally, there is a utility in Arch called namcap that you can run on your package once it is done. It can help you determine what dependencies you need to include in the PKGBUILD.
Once your package is built, you can look at what files it will provide by examining the filelist file that is created in the same directory as the PKGBUILD.
Here is a PKGBUILD that I made so that you can see how I would have done it. I'm not claiming it's perfect, but it's a start.
pkgname=multisync
pkgver=0.80
pkgrel=1
pkgdesc="A free modular program to synchronize calendars,
addressbooks and other PIM data"
url="http://www.multisync.org"
depends=()
conflicts=()
backup=()
install=
source=(http://heanet.dl.sourceforge.net/sourceforge/multisync/multisync-0.80-1.tar.gz)
md5sums=('f1b1ff5665d7de82b2a2948752b818c7')
build() {
cd $startdir/src/$pkgname-$pkgver
./autogen.sh --prefix=/usr
make || return 1
make DESTDIR=$startdir/pkg install
}
Also, I notice you're writing modules.conf to /etc (when the package is installed). Most likely this is a bad thing... cause modules.conf is owned by modutils and your package isn't allowed to steal it.
]]>It's late, so I'll just help you with one of those errors
mv: cannot stat `/home/hcman/sources/pkgs/multisync/pkg/usr/sbin': No such file or directory
Sometime when you try to install the pkg to $startdir/pkg, the install script cannot make the directories it needs. That error is saying that it can't find the /home/hcman/sources/pkgs/multisync/pkg/usr/sbin directory.
Just add the following somewhere near the start of the build() function:
mkdir $startdir/pkg/usr/sbin -p
source=(http://heanet.dl.sourceforge.net/sourceforge/multisync/multisync-0.80-1.tar.gz)
build() {
cd $startdir/src/$pkgname-$pkgver
./autogen.sh --prefix=/usr
make || return 1
make prefix=$startdir/pkg/usr install
mv $startdir/pkg/usr/sbin $startdir/pkg
mkdir -p $startdir/pkg/etc
cp ../modules.conf $startdir/pkg/etc
}
_______________________________________________________________________________________
Note: the pkgdesc line is actually complete (my eterm window was too small).
Makepkg ends on this:
_________________________________________________________________________________________
if test -f $includefile; then
/bin/install -c -m 644 $includefile /home/hcman/sources/pkgs/multisync/pkg/usr/include/multisync;
fi
done
fi
mkdir -p -- /home/hcman/sources/pkgs/multisync/pkg/usr/include/multisync
rm -f /home/hcman/sources/pkgs/multisync/pkg/usr/include/multisync/*~
MultiSync syncengine installed.
*****************************************************
** Now enter the plugins/ directory and build the *
** sync plugins you need. MultiSync will not be *
** able to do anything without these plugins. *
*****************************************************
make[2]: Leaving directory `/home/hcman/sources/pkgs/multisync/src/multisync-0.80'
make[1]: Leaving directory `/home/hcman/sources/pkgs/multisync/src/multisync-0.80'
mv: cannot stat `/home/hcman/sources/pkgs/multisync/pkg/usr/sbin': No such file or directory
cp: cannot stat `../modules.conf': No such file or directory
==> Build Failed. Aborting...
________________________________________________________________________________________
Any tips?
HC
]]>