Subject: nx-libs installs into wrong location

From: Jan Engelhardt <[email-masked]>
Date: Thu, 7 Mar 2013 18:25:24 +0100 (CET)

Package: nx-libs
Version: 3.5.0.17

Installation is done using

make install \
        INSTALL_DIR="install -dm0755" \
        INSTALL_FILE="install -pm0644" \
        INSTALL_PROGRAM="install -pm0755" \
        DESTDIR="/var/tmp/whatever" PREFIX="/usr" \
        NXLIBDIR="/usr/lib64/nx" X2GOLIBDIR="/usr/lib/x2go"

And at the end of the day, rpm notices the following broken link:

[  126s] ERROR: link target doesn't exist (neither in build root nor in
installed sys...
[  126s]   /usr/lib/x2go/bin/x2goagent -> /usr/lib/nx/bin/nxagent

This is because the top-level Makefile does a rather dumb command:

        cd $(DESTDIR)$(X2GOLIBDIR)/bin/ && ln -sf ../../nx/bin/nxagent 
x2goagent

so it creates a pointer to a non-existing target.