#!/usr/bin/make -f # Uncomment this to turn on verbose mode. #export DH_VERBOSE=1 include /usr/share/GNUstep/debian/config.mk SHELL := /bin/bash d_app := $(CURDIR)/debian/projectcenter.app export DEB_LDFLAGS_MAINT_APPEND := -Wl,--no-undefined -Wl,--as-needed \ -Wl,-rpath,/usr/lib/projectcenter.app ifneq (,$(findstring noopt,$(DEB_BUILD_OPTIONS))) optim := debug=yes endif export DEB_BUILD_MAINT_OPTIONS=hardening=+all %: dh $@ override_dh_auto_build: $(MAKE) $(optim) messages=yes DO_LIB_LINK=yes GDB=/usr/bin/gdb \ $(shell dpkg-buildflags --export=cmdline) convert Images/ProjectCenter.tiff -resize 32x32 ProjectCenter.xpm override_dh_clean: dh_clean ProjectCenter.xpm override_dh_auto_install: # Install the private library in /usr/lib/projectcenter.app. $(MAKE) install DESTDIR=$(d_app) \ GNUSTEP_SYSTEM_LIBRARIES=/usr/lib/projectcenter.app rm $(d_app)$(GNUSTEP_SYSTEM_APPS)/*.app/Resources/*.desktop override_dh_link: gsdh_gnustep # We cannot symlink Resources straight away because it contains # arch-dependent executables. Previous versions installed bundles in # /usr/lib/GNUstep/Bundles/ProjectCenter, but as of 0.5.3 this is # broken because the Preferences were split to dynamically load # available modules, all of which reside in the app bundle's resources # dir. So we move only the images, to avoid lintian warnings. It # would be much more convoluted, complex, and fragile to move # every arch-independent file/dir to /usr/share/GNUstep. dh_installdirs usr/share/GNUstep/ProjectCenter.app for i in \ $(d_app)$(GNUSTEP_SYSTEM_APPS)/ProjectCenter.app/Resources/{,English.lproj/Info.gorm/}*.tiff; do \ mv $$i $(d_app)/usr/share/GNUstep/ProjectCenter.app/ \ && dh_link usr/share/GNUstep/ProjectCenter.app/$${i##*/} \ $(GNUSTEP_SYSTEM_APPS)/ProjectCenter.app/Resources/$${i##*/}; \ done for i in \ $(d_app)$(GNUSTEP_SYSTEM_APPS)/ProjectCenter.app/Resources/ProjectCenter.{debugger,editor}/Resources/*.{png,tiff}; do \ mv $$i $(d_app)/usr/share/GNUstep/ProjectCenter.app/ \ && dh_link usr/share/GNUstep/ProjectCenter.app/$${i##*/} \ $(GNUSTEP_SYSTEM_APPS)/ProjectCenter.app/Resources/$${i##*/}; \ done override_dh_makeshlibs: # Avoid lintian warnings for the library; it is installed as private. dh_makeshlibs --noscripts