Commit ca430878 authored by Mike Gabriel's avatar Mike Gabriel

Drop bin wrappers for nxagent and nxproxy, directly install nxproxy and nxagent to BINDIR.

Fixes ArcticaProject/nx-libs#546.
parent 05cf54af
......@@ -23,7 +23,7 @@ SHLIBDIR ?= $(LIBDIR)
NXLIBDIR ?= $(SHLIBDIR)/nx
USRLIBDIR ?= $(NXLIBDIR)/X11
INCLUDEDIR ?= $(PREFIX)/include
CONFIGURE ?= ./configure --prefix=$(DESTDIR)$(PREFIX) --libexecdir=$(NXLIBDIR)/bin
CONFIGURE ?= ./configure --prefix=$(DESTDIR)$(PREFIX)
# use Xfont2 if available in the build env
FONT_DEFINES ?= $(shell pkg-config --modversion xfont2 1>/dev/null 2>/dev/null && echo "-DHAS_XFONT2")
......@@ -75,8 +75,6 @@ NX_XTRANS_HEADERS = \
rm -Rf nx-X11/extras/Mesa/.pc/; \
rm -f nx-X11/config/cf/nxversion.def; \
rm -f nx-X11/config/cf/date.def; \
rm -f bin/nxagent; \
rm -f bin/nxproxy; \
${MAKE} clean-env; \
fi
......@@ -168,30 +166,24 @@ install-lite:
# install nxcomp library
$(MAKE) -C nxcomp install
# install nxproxy wrapper script
$(INSTALL_DIR) $(DESTDIR)$(BINDIR)
sed -e 's|@@NXLIBDIR@@|$(NXLIBDIR)|g' bin/nxproxy.in > bin/nxproxy
$(INSTALL_PROGRAM) bin/nxproxy $(DESTDIR)$(BINDIR)
# install the nxproxy executable and its man page
$(MAKE) -C nxproxy install
install-full:
# install nxagent wrapper script
$(INSTALL_DIR) $(DESTDIR)$(BINDIR)
sed -e 's|@@NXLIBDIR@@|$(NXLIBDIR)|g' bin/nxagent.in > bin/nxagent
$(INSTALL_PROGRAM) bin/nxagent $(DESTDIR)$(BINDIR)
$(MAKE) -C nxcompshad install
$(INSTALL_DIR) $(DESTDIR)$(BINDIR)/bin
$(INSTALL_PROGRAM) nx-X11/programs/Xserver/nxagent $(DESTDIR)$(BINDIR)
$(INSTALL_DIR) $(DESTDIR)$(PREFIX)/share/pixmaps
$(INSTALL_FILE) nx-X11/programs/Xserver/hw/nxagent/nxagent.xpm $(DESTDIR)$(PREFIX)/share/pixmaps
$(INSTALL_DIR) $(DESTDIR)$(PREFIX)/share/nx
$(INSTALL_FILE) nx-X11/programs/Xserver/Xext/SecurityPolicy $(DESTDIR)$(PREFIX)/share/nx
# FIXME: Drop this symlink for 3.6.0. Requires that third party frameworks like X2Go have become aware of this...
$(INSTALL_DIR) $(DESTDIR)$(NXLIBDIR)/bin
$(INSTALL_PROGRAM) nx-X11/programs/Xserver/nxagent $(DESTDIR)$(NXLIBDIR)/bin
$(INSTALL_SYMLINK) $(BINDIR)/nxagent $(DESTDIR)$(NXLIBDIR)/bin/nxagent
$(INSTALL_DIR) $(DESTDIR)$(PREFIX)/share/man/man1/
$(INSTALL_FILE) nx-X11/programs/Xserver/hw/nxagent/man/nxagent.1 $(DESTDIR)$(PREFIX)/share/man/man1/
......@@ -243,28 +235,19 @@ uninstall:
uninstall-lite:
if test -f nxcomp/Makefile; then ${MAKE} -C nxcomp $@; fi
if test -f nxproxy/Makefile; then ${MAKE} -C nxproxy $@; fi
# uninstall nproxy wrapper script
$(RM_FILE) $(DESTDIR)$(BINDIR)/nxproxy
# FIXME: don't use uninstall rule in nxproxy/Makefile.in, let's do
# it on our own for now...
$(RM_FILE) $(DESTDIR)$(NXLIBDIR)/bin/nxproxy
$(RM_DIR) $(DESTDIR)$(NXLIBDIR)/bin/
$(RM_FILE) $(DESTDIR)$(PREFIX)/share/man/man1/*.1
$(RM_FILE) $(DESTDIR)$(PREFIX)/share/nx/VERSION.nxproxy
$(RM_DIR) $(DESTDIR)$(PREFIX)/share/nx/
uninstall-full:
for f in nxagent; do \
$(RM_FILE) $(DESTDIR)$(BINDIR)/$$f; done
if test -f nxcompshad/Makefile; then ${MAKE} -C nxcompshad $@; fi
if test -f nx-X11/lib/Makefile; then ${MAKE} -C nx-X11/lib $@; fi
$(RM_FILE) $(DESTDIR)$(BINDIR)/nxagent
$(RM_FILE) $(DESTDIR)$(PREFIX)/share/nx/VERSION.nxagent
$(RM_DIR) $(DESTDIR)$(PREFIX)/share/nx/
if test -d nx-X11; then \
if test -f nxcompshad/Makefile; then ${MAKE} -C nxcompshad $@; fi; \
if test -f nx-X11/Makefile; then \
if test -d $(NXLIBDIR); then rm -rf $(NXLIBDIR); fi; \
if test -d $(INCLUDEDIR)/nx; then rm -rf $(INCLUDEDIR)/nx; fi; \
fi; \
fi
if test -d $(DESTDIR)$(NXLIBDIR); then rm -rf $(DESTDIR)$(NXLIBDIR); fi
if test -d $(DESTDIR)$(INCLUDEDIR)/nx; then rm -rf $(DESTDIR)$(INCLUDEDIR)/nx; fi
#!/bin/bash
# Copyright (C) 2012 Mike Gabriel <mike.gabriel@das-netzwerkteam.de>
#
# This program is free software: you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
# the Free Software Foundation, either version 3 of the License, or
# (at your option) any later version.
#
# This program is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU General Public License for more details.
#
# You should have received a copy of the GNU General Public License
# along with this program. If not, see http://www.gnu.org/licenses/.
NX_LIBDIR=@@NXLIBDIR@@
# make sure nxagent starts properly with pam_tmpdir.so being in use
NX_TEMP=${NX_TEMP:-/tmp}
export NX_TEMP
exec $NX_LIBDIR/bin/${NXAPP:-"nxagent"} "$@"
#!/bin/bash
# Copyright (C) 2012 Mike Gabriel <mike.gabriel@das-netzwerkteam.de>
#
# This program is free software: you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
# the Free Software Foundation, either version 3 of the License, or
# (at your option) any later version.
#
# This program is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU General Public License for more details.
#
# You should have received a copy of the GNU General Public License
# along with this program. If not, see http://www.gnu.org/licenses/.
NX_LIBDIR=@@NXLIBDIR@@
# make sure nxagent starts properly with pam_tmpdir.so being in use
NX_TEMP=${NX_TEMP:-/tmp}
export NX_TEMP
exec $NX_LIBDIR/bin/${NXAPP:="nxproxy"} "$@"
etc/nxagent/keystrokes.cfg
usr/share/nx/VERSION.nxagent
usr/share/man/man1/nxagent.1*
usr/lib/*/nx/bin/nxagent
usr/lib/*/nx/X11/
usr/bin/nxagent
usr/share/pixmaps/nxagent.xpm
etc/nxagent/nxagent.keyboard
# FIXME: compatibility symlink, drop for 3.6.0 release
usr/lib/*/nx/bin/nxagent
usr/lib/*/nx/bin/nxproxy
usr/bin/nxproxy
usr/share/man/man1/nxproxy.1*
usr/share/nx/VERSION.nxproxy
......@@ -769,7 +769,7 @@ FCHOWN_DEFINES = -DHAS_FCHOWN
#ifndef BinDir
#ifdef ProjectRoot
#define BinDir Concat(ProjectRoot,/lib/nx/bin)
#define BinDir Concat(ProjectRoot,/bin)
#else
#define BinDir /usr/bin/X11
#endif
......
......@@ -367,10 +367,6 @@ This package provides the NX proxy (client) binary.
rm -Rf nx*/configure nx*/autom4te.cache*
# Install into /usr
sed -i -e 's,/usr/local,/usr,' nx-X11/config/cf/site.def
# Use multilib dirs
# We're installing binaries into %%{_libdir}/nx/bin rather than %%{_libexedir}/nx
# because upstream expects libraries and binaries in the same directory
sed -i -e 's,/lib/nx,/%{_lib}/nx,' nx-X11/config/cf/X11.tmpl
# Fix FSF address
find -name LICENSE | xargs sed -i \
-e 's/59 Temple Place/51 Franklin Street/' -e 's/Suite 330/Fifth Floor/' \
......@@ -575,6 +571,7 @@ rm -r %{buildroot}%{_includedir}/nx-X11/Xtrans
%config(noreplace) %{_sysconfdir}/nxagent/nxagent.keyboard
%doc doc/nxagent/README.keystrokes
%{_bindir}/nxagent
# FIXME: compatibility symlink to BINDIR/nxagent, remove for 3.6.0
%dir %{_libdir}/nx/bin
%{_libdir}/nx/bin/nxagent
%dir %{_libdir}/nx/X11
......@@ -590,8 +587,6 @@ rm -r %{buildroot}%{_includedir}/nx-X11/Xtrans
%doc doc/nxproxy/README-VALGRIND
%{_bindir}/nxproxy
%{_datadir}/man/man1/nxproxy.1*
%dir %{_libdir}/nx/bin
%{_libdir}/nx/bin/nxproxy
%dir %{_datadir}/nx
%{_datadir}/nx/VERSION.nxproxy
......
NULL =
nxexecdir = $(libexecdir)
nxexecdir = $(bindir)
nxexec_PROGRAMS = nxproxy
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment