Commit 3cfe4bfa authored by Mike Gabriel's avatar Mike Gabriel

Drop nx-X11/programs/Xserver/hw/xfree86 except of four files symlinked to other…

Drop nx-X11/programs/Xserver/hw/xfree86 except of four files symlinked to other locations in the source tree at build time.
parent b590ce38
...@@ -21,6 +21,8 @@ nx-libs (2:3.5.0.29-0x2go1) UNRELEASED; urgency=medium ...@@ -21,6 +21,8 @@ nx-libs (2:3.5.0.29-0x2go1) UNRELEASED; urgency=medium
* Drop more unused code in nx-X11/programs/Xserver/hw/. Do this in * Drop more unused code in nx-X11/programs/Xserver/hw/. Do this in
roll-tarball.sh and in debian/rules alike. roll-tarball.sh and in debian/rules alike.
* Stop shipping unused / very old xterm code. * Stop shipping unused / very old xterm code.
* Drop nx-X11/programs/Xserver/hw/xfree86 except of four files symlinked
to other locations in the source tree at build time.
[ Horst Schirmeier ] [ Horst Schirmeier ]
* Update 320_nxagent_configurable-keystrokes.full.patch. Fix a typo that * Update 320_nxagent_configurable-keystrokes.full.patch. Fix a typo that
......
...@@ -31,6 +31,7 @@ usage() { ...@@ -31,6 +31,7 @@ usage() {
} }
PROJECT="nx-libs" PROJECT="nx-libs"
NULL=""
test -d .git || usage test -d .git || usage
test -f debian/Makefile.nx-libs || usage test -f debian/Makefile.nx-libs || usage
...@@ -133,16 +134,42 @@ mv -v debian/changelog doc/changelog ...@@ -133,16 +134,42 @@ mv -v debian/changelog doc/changelog
test -f Makefile || test -f debian/Makefile.nx-libs && cp -v debian/Makefile.nx-libs Makefile test -f Makefile || test -f debian/Makefile.nx-libs && cp -v debian/Makefile.nx-libs Makefile
test -f replace.sh || test -f debian/Makefile.replace.sh && cp -v debian/Makefile.replace.sh replace.sh test -f replace.sh || test -f debian/Makefile.replace.sh && cp -v debian/Makefile.replace.sh replace.sh
# remove folders that we do not want to roll into the tarball # remove folders that we do not want to roll into the tarball
rm -Rf ".pc/" rm -Rf ".pc/"
rm -Rf "debian/" rm -Rf "debian/"
# bundled libraries we do not need
#### bundled libraries we do not need
# first preserve a few files...
PRESERVE_CODE="
nx-X11/programs/Xserver/hw/xfree86/common/compiler.h \
nx-X11/programs/Xserver/hw/xfree86/os-support/xf86_ansic.h \
nx-X11/programs/Xserver/hw/xfree86/os-support/xf86_libc.h \
nx-X11/programs/Xserver/hw/xfree86/xf86Version.h \
${NULL}
"
mkdir -p .preserve/
for path in ${PRESERVE_CODE}; do
if [ ! -d $path ]; then
path_dirname=$(dirname "$path")
else
path_dirname="$path"
fi
mkdir -vp ".preserve/$path_dirname"
cp -av "$path" ".preserve/$path"
done
rm -Rf nx-X11/extras/{drm,expat,fontconfig,freetype2,fonts,ogl-sample,regex,rman,ttf2pt1,x86emu,zlib} rm -Rf nx-X11/extras/{drm,expat,fontconfig,freetype2,fonts,ogl-sample,regex,rman,ttf2pt1,x86emu,zlib}
rm -Rf nx-X11/lib/{expat,fontconfig,fontenc,font/FreeType,font/include/fontenc.h,freetype2,regex,zlib} rm -Rf nx-X11/lib/{expat,fontconfig,fontenc,font/FreeType,font/include/fontenc.h,freetype2,regex,zlib}
rm -Rf nx-X11/lib/{FS,ICE,SM,Xaw,Xft,Xt,Xmu,Xmuu} rm -Rf nx-X11/lib/{FS,ICE,SM,Xaw,Xft,Xt,Xmu,Xmuu}
rm -Rf nx-X11/programs/Xserver/hw/{darwin,dmx,kdrive,sun,sunLynx,vfb,xnest,xwin} rm -Rf nx-X11/programs/Xserver/hw/{darwin,dmx,kdrive,sun,sunLynx,vfb,xfree86,xnest,xwin}
rm -Rf nx-X11/programs/xterm rm -Rf nx-X11/programs/xterm
# re-create the to-be-preserved files
cp -a .preserve/* ./
rm -Rf .preserve/
# remove files, that we do not want in the tarballs (build cruft) # remove files, that we do not want in the tarballs (build cruft)
rm -Rf nx*/configure nx*/autom4te.cache* rm -Rf nx*/configure nx*/autom4te.cache*
......
...@@ -13,42 +13,49 @@ endif ...@@ -13,42 +13,49 @@ endif
CONFIGURE="./configure --prefix=/usr" LD_LIBRARY_PATH=`pwd`/debian/libnx-x11/usr/lib/nx/X11:$$LD_LIBRARY_PATH dh $@ --with quilt CONFIGURE="./configure --prefix=/usr" LD_LIBRARY_PATH=`pwd`/debian/libnx-x11/usr/lib/nx/X11:$$LD_LIBRARY_PATH dh $@ --with quilt
# before build, we will remove unused code / bundled libraries (keep this in sync with roll-tarball.sh) # before build, we will remove unused code / bundled libraries (keep this in sync with roll-tarball.sh)
UNUSED_CODE = nx-X11/extras/drm \ UNUSED_CODE = nx-X11/extras/drm/ \
nx-X11/extras/expat \ nx-X11/extras/expat/ \
nx-X11/extras/fontconfig \ nx-X11/extras/fontconfig/ \
nx-X11/extras/freetype2 \ nx-X11/extras/freetype2/ \
nx-X11/extras/fonts \ nx-X11/extras/fonts/ \
nx-X11/extras/ogl-sample \ nx-X11/extras/ogl-sample/ \
nx-X11/extras/regex \ nx-X11/extras/regex/ \
nx-X11/extras/rman \ nx-X11/extras/rman/ \
nx-X11/extras/ttf2pt1 \ nx-X11/extras/ttf2pt1/ \
nx-X11/extras/x86emu \ nx-X11/extras/x86emu/ \
nx-X11/extras/zlib \ nx-X11/extras/zlib/ \
nx-X11/lib/expat \ nx-X11/lib/expat/ \
nx-X11/lib/fontconfig \ nx-X11/lib/fontconfig/ \
nx-X11/lib/fontenc \ nx-X11/lib/fontenc/ \
nx-X11/lib/font/FreeType \ nx-X11/lib/font/FreeType/ \
nx-X11/lib/font/include/fontenc.h \ nx-X11/lib/font/include/fontenc.h \
nx-X11/lib/freetype2 \ nx-X11/lib/freetype2/ \
nx-X11/lib/regex \ nx-X11/lib/regex/ \
nx-X11/lib/zlib \ nx-X11/lib/zlib/ \
nx-X11/lib/FS \ nx-X11/lib/FS/ \
nx-X11/lib/ICE \ nx-X11/lib/ICE/ \
nx-X11/lib/SM \ nx-X11/lib/SM/ \
nx-X11/lib/Xaw \ nx-X11/lib/Xaw/ \
nx-X11/lib/Xft \ nx-X11/lib/Xft/ \
nx-X11/lib/Xt \ nx-X11/lib/Xt/ \
nx-X11/lib/Xmu \ nx-X11/lib/Xmu/ \
nx-X11/lib/Xmuu \ nx-X11/lib/Xmuu/ \
nx-X11/programs/Xserver/hw/darwin \ nx-X11/programs/Xserver/hw/darwin/ \
nx-X11/programs/Xserver/hw/dmx \ nx-X11/programs/Xserver/hw/dmx/ \
nx-X11/programs/Xserver/hw/kdrive \ nx-X11/programs/Xserver/hw/kdrive/ \
nx-X11/programs/Xserver/hw/sun \ nx-X11/programs/Xserver/hw/sun/ \
nx-X11/programs/Xserver/hw/sunLynx \ nx-X11/programs/Xserver/hw/sunLynx/ \
nx-X11/programs/Xserver/hw/vfb \ nx-X11/programs/Xserver/hw/vfb/ \
nx-X11/programs/Xserver/hw/xnest \ nx-X11/programs/Xserver/hw/xnest/ \
nx-X11/programs/Xserver/hw/xwin \ nx-X11/programs/Xserver/hw/xwin/ \
nx-X11/programs/xterm \ nx-X11/programs/Xserver/hw/xfree86/ \
nx-X11/programs/xterm/ \
$(NULL)
PRESERVE_CODE = nx-X11/programs/Xserver/hw/xfree86/common/compiler.h \
nx-X11/programs/Xserver/hw/xfree86/os-support/xf86_ansic.h \
nx-X11/programs/Xserver/hw/xfree86/os-support/xf86_libc.h \
nx-X11/programs/Xserver/hw/xfree86/xf86Version.h \
$(NULL) $(NULL)
override_dh_auto_clean: override_dh_auto_clean:
...@@ -62,6 +69,7 @@ override_dh_clean: ...@@ -62,6 +69,7 @@ override_dh_clean:
rm -f nx-X11/programs/nxauth/changelog rm -f nx-X11/programs/nxauth/changelog
rm -Rf replace.sh Makefile bin rgb VERSION.x2goagent etc/keystrokes.cfg rm -Rf replace.sh Makefile bin rgb VERSION.x2goagent etc/keystrokes.cfg
rm -f debian/libnx-x11.postinst rm -f debian/libnx-x11.postinst
rm -Rf .preserve/
if [ -f nxcomp/.VERSION.NoMachine ]; then mv nxcomp/.VERSION.NoMachine nxcomp/VERSION; fi if [ -f nxcomp/.VERSION.NoMachine ]; then mv nxcomp/.VERSION.NoMachine nxcomp/VERSION; fi
dh_clean dh_clean
...@@ -91,10 +99,18 @@ override_dh_auto_build: ...@@ -91,10 +99,18 @@ override_dh_auto_build:
# let's prep the libnx-x11.postinst script with the value of the build systems's DEB_BUILD_MULTIARCH variable # let's prep the libnx-x11.postinst script with the value of the build systems's DEB_BUILD_MULTIARCH variable
sed debian/libnx-x11.postinst.in -e 's/#DEB_BUILD_MULTIARCH#/$(DEB_BUILD_MULTIARCH)/' > debian/libnx-x11.postinst sed debian/libnx-x11.postinst.in -e 's/#DEB_BUILD_MULTIARCH#/$(DEB_BUILD_MULTIARCH)/' > debian/libnx-x11.postinst
# make a copy of code to be preserved for build
mkdir -p .preserve
for path in $(PRESERVE_CODE); do test -d $$path && mkdir -p .preserve/$$path || mkdir -p .preserve/$$(dirname $$path); cp -av $$path .preserve/$$path; done
# remove unused code / bundled libraries (see at the top of this file # remove unused code / bundled libraries (see at the top of this file
# for the exact list of files and folders # for the exact list of files and folders
rm -Rf $(UNUSED_CODE) rm -Rf $(UNUSED_CODE)
# copy to-be-preserved files back into code tree
cp -av .preserve/* .
rm -Rf .preserve/
LD_LIBRARY_PATH=`pwd`/debian/libnx-x11/usr/lib/nx/X11:$$LD_LIBRARY_PATH dh_auto_build --parallel LD_LIBRARY_PATH=`pwd`/debian/libnx-x11/usr/lib/nx/X11:$$LD_LIBRARY_PATH dh_auto_build --parallel
override_dh_strip: override_dh_strip:
......
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