On 25. april 2014 12:51, Patrick Ohly wrote:
Hello Ove!

In the following commit you changed the rule for syncevo-webdav-lookup:

commit ff97574d7026a008efa79bdc8a46c7fc6688d218
Author: Ove Kåven <[email protected]>
Date:   Sat Aug 11 12:11:30 2012 +0200

     Fixed broken rule for creating syncevo-webdav-lookup.

  src/backends/webdav/syncevo-webdav-lookup:
$(srcdir)/src/backends/webdav/syncevo-webdav-lookup.sh
         $(AM_V_GEN)rm -f $@ ; \
-       ln -s $< $@
+       cd src/backends/webdav && ln -s $(notdir $<) $(notdir $@)

I noticed recently that this broke out-of-tree compilation, causing
syncevolution.org binaries to not have the script anymore.

Do you remember why the rule was broken for you?

Well, it should be obvious. If you do something like

ln -s src/backends/webdav/syncevo-webdav-lookup.sh src/backends/webdav/syncevo-webdav-lookup

then you're going to end up with a symlink in src/backends/webdav which, relative to the current directory, would resolve to

src/backends/webdav/src/backends/webdav/syncevo-webdav-lookup.sh

which doesn't exist, i.e., you've just created a dangling symlink. (And out-of-tree shouldn't matter. For in-tree builds, srcdir is supposed to be ".", for out-of-tree builds it would be ".." or something. Both cases would create a broken symlink.)

So no, your change would not fix the issue.

In Debian's "debhelper" package, there's a "dh_link" that can be used by packagers to avoid such surprises (dh_link calculates the correct relative path to use for the symlink before invoking ln). Sadly, that script is, of course, only available on Debian and Ubuntu.

Anyway, I'm not sure what exactly you're trying to achieve by creating this symlink? If this was for out-of-tree builds, couldn't you just, say, copy the file?

Also, I'm not sure what problems Guido ran into. Which Maemo version? Although I haven't tried compiling syncevolution 1.4 on Fremantle yet, I didn't have any builddir issues with syncevolution 1.3, at least not when I used the newest version of automake available for Fremantle (automake 1.10.1), instead of the SDK default (automake 1.8.5). (That's why I had the autogen-maemo.sh script, to force use of the best autotools versions on Fremantle.)

_______________________________________________
SyncEvolution mailing list
[email protected]
https://lists.syncevolution.org/mailman/listinfo/syncevolution

Reply via email to