You are not logged in.
Please review and don't hesitate to point out every mistake I must've made. Had to patch 2 files (just added #includes) according to http://gcc.gnu.org/gcc-4.3/porting_to.html for it to compile.
(I had to copy the example configuration files manually, is there a less ugly way to do it?)
PKGBUILD
# Contributor: Diego Gaustein <_firstname_@_lastname_.com.ar>
pkgname=syncevolution
pkgver=0.7
pkgrel=1
pkgdesc="Synchronize personal information management (PIM) via SyncML"
arch=('i686')
url="http://www.estamos.de/projects/SyncML/"
license=('GPL')
depends=('curl' 'evolution-data-server')
source=(http://www.estamos.de/download/$pkgname/sources/$pkgname-$pkgver.tar.gz \
gcc43_headers.diff)
md5sums=('e2ecb9fdcb4d61276d73385e4a303179'
'72479d450adcc096ba0fe8055c342fff')
options=('!emptydirs')
build() {
cd $startdir/src/$pkgname-$pkgver
patch -p0 < ../gcc43_headers.diff || exit 1
./configure --prefix=/usr || exit 1
make || exit 1
make DESTDIR="$pkgdir" install || exit 1
install -dm755 "$pkgdir"/etc/skel/syncevolution
cp -R etc/funambol "$pkgdir"/etc/skel/syncevolution
cp -R etc/scheduleworld "$pkgdir"/etc/skel/syncevolution
cp etc/*.txt "$pkgdir"/etc/skel/syncevolution
}
gcc43_headers.diff
--- src/EvolutionSyncClient.cpp.orig 2008-05-21 05:42:01.000000000 -0300
+++ src/EvolutionSyncClient.cpp 2008-05-21 05:45:38.000000000 -0300
@@ -39,6 +39,9 @@
#include <dirent.h>
#include <errno.h>
+#include <algorithm>
+
+
SourceList *EvolutionSyncClient::m_sourceListPtr;
EvolutionSyncClient::EvolutionSyncClient(const string &server,
--- src/syncevolution.cpp.orig 2008-05-21 05:41:40.000000000 -0300
+++ src/syncevolution.cpp 2008-05-21 05:36:16.000000000 -0300
@@ -19,7 +19,7 @@
#include <config.h>
#include <stddef.h>
-
+#include <memory>
#include <base/Log.h>
#include <posix/base/posixlog.h>
#include <spds/spdsutils.h>
Cheers.
Last edited by Diego Gaustein (2008-05-22 01:11:50)
Offline
Your PKGBUILD is a great first effort! I mainly have very minor comments below.
It would have been much easier to just post the PKGBUILD here so we did have to download it.
Anyway, you can remove empty fields (makedepends). It would be good if you named your patch something informative, e.g. gcc43-header-fix.diff. I would have done the "make install" before installing the extra config files. I see you are copying whole directories, so I suppose using cp is fine. Just remember where possible, you should use install instead, as that way you can make sure you get the right permissions.
Offline
Your PKGBUILD is a great first effort!
Thanks
It would have been much easier to just post the PKGBUILD here so we did have to download it.
It seems the forums don't have a way to upload files, but I guess I could post the PKGBUILD and the patch. Is /usr/share/syncevolution the right place to put example config files? (they are skeletons to copy to each user's home dir and modify)
I updated my first post
Last edited by Diego Gaustein (2008-05-21 19:40:39)
Offline
I would say the /etc/skel/ is the right place to copy the example config files to.
Offline
I would say the /etc/skel/ is the right place to copy the example config files to.
I didn't think about that. Thanks.
Offline
I just noticed, you need to have the patch in the "source" array. Then you will only need one set of ../ because it will get linked to your source directory.
Offline
Thanks. I forgot the patch file has to be in listed in source=() when uploading to ABS. I've updated my first post. Do you see anything else or is it OK to upload to ABS?
Cheers.
Offline
That looks good to go into the AUR to me.
In the quest for perfection, I will just add some incredibly minor cosmetic comments. Instead of putting the "-R" at the end of the "cp" lines, use "cp -R". I just makes things a bit clearer. Instead of "mkdir" you can use "install -dm755" to ensure the permissions get set right. And finally, you mix the use of $startdir/pkg and $pkgdir.
Offline
That looks good to go into the AUR to me.
In the quest for perfection, I will just add some incredibly minor cosmetic comments. Instead of putting the "-R" at the end of the "cp" lines, use "cp -R". I just makes things a bit clearer. Instead of "mkdir" you can use "install -dm755" to ensure the permissions get set right. And finally, you mix the use of $startdir/pkg and $pkgdir.
Done, done and done. I'd forgotten about permissions and the existence of $pkgdir.
Offline
I couldn't find this in the AUR. Is it in there? Before I found your PKGBUILD I tried to use the binary from SyncEvolution's web site but it would not work. Since I could not find this or any other PKGBUILD I just used the code you posted in this thread to make the package. It compiled and installed O.K. though it gives me a segmentation fault when I run it.
Last edited by chris256 (2008-07-01 01:25:51)
Offline
I couldn't find this in the AUR. Is it in there? Before I found your PKGBUILD I tried to use the binary from SyncEvolution's web site but it would not work. Since I could not find this or any other PKGBUILD I just used the code you posted in this thread to make the package. It compiled and installed O.K. though it gives me a segmentation fault when I run it.
I didn't post it since I ended up not using it, and I didn't test it enough. Sorry to hear it's segfaulting, but I've no idea what it can be.
Cheers.
Offline
... I see you are copying whole directories, so I suppose using cp is fine. Just remember where possible, you should use install instead, as that way you can make sure you get the right permissions.
A simple for-find does directory install really simple
for file in $(find DIR/ -max-depth 1 -type f); do install -T -m 0644 $file $startdir/pkg/$file ;done
Offline
BTW, I rebuilt from your PKGBUILD and it works fine now. I think it was segfaulting last time because of some nuances with my confg files that I retained from the same program with another distro. I re-did the config files using the skel files from your package and all is well now. Thanks.
Offline