/usr/share/cdbs/1/rules/gnustep.mk is in gnustep-make 2.6.2-2.1ubuntu1.
This file is owned by root:root, with mode 0o644.
The actual contents of the file can be viewed below.
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 214 215 216 217 218 219 220 221 222 223 224 | # -*- mode: makefile; coding: utf-8 -*-
# Variables used by this file:
# DEB_GS_FRAMEWORKS
# A list of the frameworks to install.
# DEB_GS_APPLICATIONS
# A list of the frameworks to install.
# DEB_GS_LIBRARIES
# A list of the frameworks to install.
# DEB_GS_LCNAME_<Component>
# The name of a package, lower case (defaults to "<Component> | y/A-Z/a-z/").
# DEB_GS_APPLICATION_PKG_NAME_<Application>
# The name of the framework dependency package (defaults to
# <lcname>.app).
# DEB_GS_INTERFACE_VERSION_<Component>
# The interface version (soname) of a framework or library (defaults to "0").
# DEB_GS_CURRENT_VERSION_NAME_<Framework>
# The current version name of the framework (defaults to <soname>).
# DEB_GS_LIBPKG_NAME_<Component>
# The name of the library package (defaults to lib<lcname><soname>).
# DEB_GS_DEVPKG_NAME_<Component>
# The name of the development package (defaults to <libpackage>-dev).
# DEB_GS_FRAMEWORK_PKG_NAME_<Framework>
# The name of the framework dependency package (defaults to
# <lcname>.framework).
# DEB_GS_AUTO_LINTIAN_OVERRIDES
# DEB_GS_AUTO_LINTIAN_OVERRIDES_<Component>
# Use a default set of lintian overrides
# DEB_GS_AUTO_DH_INSTALL
# DEB_GS_AUTO_DH_INSTALL_<Component>
# Use a default set of install files
ifndef _cdbs_bootstrap
_cdbs_scripts_path ?= /usr/lib/cdbs
_cdbs_rules_path ?= /usr/share/cdbs/1/rules
_cdbs_class_path ?= /usr/share/cdbs/1/class
endif
include $(_cdbs_rules_path)/debhelper.mk
__gs_set_default_value = $(if $($(1)),,$(eval $(1) = $(2)))
# GNUstep settings
_gs_debian_dir = /usr/share/GNUstep/debian
include $(_gs_debian_dir)/config.mk
GS_FRAMEWORKS_DIR = $(GNUSTEP_SYSTEM_LIBRARY)/Frameworks
DEB_DH_INSTALL_SOURCEDIR = $(DEB_DESTDIR)
$(patsubst %,binary-install/%,$(DEB_PACKAGES)) :: binary-install/%:
gsdh_gnustep -p$(cdbs_curpkg)
dh_link -p$(cdbs_curpkg)
# convenience variables
__gs_curcomponent = $(filter-out %/,$(subst /,/ ,$@))
__gs_cur_framework_pkg=$(DEB_GS_FRAMEWORK_PKG_NAME_$(__gs_curcomponent))
__gs_cur_apppkg=$(DEB_GS_APPLICATION_PKG_NAME_$(__gs_curcomponent))
__gs_cur_libpkg=$(DEB_GS_LIBPKG_NAME_$(__gs_curcomponent))
__gs_cur_devpkg=$(DEB_GS_DEVPKG_NAME_$(__gs_curcomponent))
__gs_cur_appdir=debian/$(__gs_cur_apppkg)
__gs_cur_libdir=debian/$(__gs_cur_libpkg)
__gs_cur_devdir=debian/$(__gs_cur_devpkg)
__gs_cur_ver=$(DEB_GS_CURRENT_VERSION_NAME_$(__gs_curcomponent))
#####
# Applications:
#####
define __gs_application_set_default_values
$(call __gs_set_default_value,DEB_GS_LCNAME_$(1),$(shell echo $(1) | tr [A-Z] [a-z]))
$(call __gs_set_default_value,DEB_GS_APPLICATION_PKG_NAME_$(1),$(DEB_GS_LCNAME_$(1)).app)
endef
$(foreach application,$(DEB_GS_APPLICATIONS),$(eval $(call __gs_application_set_default_values,$(application))))
clean:: $(patsubst %,gs-clean/%,$(DEB_GS_APPLICATIONS))
define __gs_application_rm_dh_install
rm -f debian/$(__gs_cur_apppkg).install
endef
$(patsubst %,gs-clean/%,$(DEB_GS_APPLICATIONS)) :: gs-clean/%:
# remove automatically generated .install files
$(if $(DEB_GS_AUTO_DH_INSTALL)$(DEB_GS_AUTO_DH_INSTALL_$(__gs_curcomponent)),$(__gs_application_rm_dh_install))
common-install-prehook-arch:: $(patsubst %,gs-pre-install/%,$(DEB_GS_APPLICATIONS))
define __gs_application_update_dh_install
sed -e "s:@GNUSTEP_SYSTEM_APPS@:$(GNUSTEP_SYSTEM_APPS):g" \
-e "s:@GNUSTEP_SYSTEM_TOOLS@:$(GNUSTEP_SYSTEM_TOOLS):g" \
-e "s/@APPLICATION@/$(__gs_curcomponent)/g" \
< $(_gs_debian_dir)/application.install.in \
> debian/$(__gs_cur_apppkg).install
endef
$(patsubst %,gs-pre-install/%,$(DEB_GS_APPLICATIONS)) :: gs-pre-install/%:
# generate lintian warning overrides
$(if $(DEB_GS_AUTO_LINTIAN_OVERRIDES)$(DEB_GS_AUTO_LINTIAN_OVERRIDES_$(__gs_curcomponent)),$(warning DEB_GS_AUTO_LINTIAN_OVERRIDES for applications has been deprecated.))
# generate the install files
$(if $(DEB_GS_AUTO_DH_INSTALL)$(DEB_GS_AUTO_DH_INSTALL_$(__gs_curcomponent)),$(__gs_application_update_dh_install))
# wrapper script
# dh_installdirs -p$(__gs_cur_apppkg) usr/bin
# dh_link -p$(__gs_cur_apppkg) $(GS_MAKE_DIR)/gnustep-app-wrapper usr/bin/$(__gs_curcomponent)
#####
# Frameworks:
#####
define __gs_framework_set_default_values
$(call __gs_set_default_value,DEB_GS_LCNAME_$(1),$(shell echo $(1) | tr [A-Z] [a-z]))
$(call __gs_set_default_value,DEB_GS_INTERFACE_VERSION_$(1),0)
$(call __gs_set_default_value,DEB_GS_CURRENT_VERSION_NAME_$(1),$(DEB_GS_INTERFACE_VERSION_$(1)))
$(call __gs_set_default_value,DEB_GS_LIBPKG_NAME_$(1),lib$(DEB_GS_LCNAME_$(1))$(DEB_GS_INTERFACE_VERSION_$(1)))
$(call __gs_set_default_value,DEB_GS_DEVPKG_NAME_$(1),$(DEB_GS_LIBPKG_NAME_$(1))-dev)
$(call __gs_set_default_value,DEB_GS_FRAMEWORK_PKG_NAME_$(1),$(DEB_GS_LCNAME_$(1)).framework)
endef
$(foreach framework,$(DEB_GS_FRAMEWORKS),$(eval $(call __gs_framework_set_default_values,$(framework))))
__gs_frameworks_dev_packages = $(foreach framework,$(DEB_GS_FRAMEWORKS),$(DEB_GS_DEVPKG_NAME_$(framework)))
clean:: $(patsubst %,gs-clean/%,$(DEB_GS_FRAMEWORKS))
define __gs_framework_rm_dh_install
rm -f debian/$(__gs_cur_libpkg).install
rm -f debian/$(__gs_cur_devpkg).install
endef
$(patsubst %,gs-clean/%,$(DEB_GS_FRAMEWORKS)) :: gs-clean/%:
# remove automatically generated .install files
$(if $(DEB_GS_AUTO_DH_INSTALL)$(DEB_GS_AUTO_DH_INSTALL_$(__gs_curcomponent)),$(__gs_framework_rm_dh_install))
common-install-prehook-arch:: $(patsubst %,gs-pre-install/%,$(DEB_GS_FRAMEWORKS))
define __gs_framework_update_lintian_overrides
dh_installdirs -p$(__gs_cur_libpkg) usr/share/lintian/overrides
sed -e "s/@PACKAGE@/$(__gs_cur_libpkg)/g" \
< $(_gs_debian_dir)/frameworklib.overrides.in \
> $(__gs_cur_libdir)/usr/share/lintian/overrides/$(__gs_cur_libpkg)
endef
define __gs_framework_update_dh_install
sed -e "s:@GNUSTEP_SYSTEM_LIBRARIES@:$(GNUSTEP_SYSTEM_LIBRARIES):g" \
-e "s:@GNUSTEP_SYSTEM_LIBRARY@:$(GNUSTEP_SYSTEM_LIBRARY):g" \
-e "s:@GNUSTEP_SYSTEM_HEADERS@:$(GNUSTEP_SYSTEM_HEADERS):g" \
-e "s/@FRAMEWORK@/$(__gs_curcomponent)/g; s/@FRAMEWORKVER@/$(__gs_cur_ver)/g" \
< $(_gs_debian_dir)/frameworklib.install.in \
> debian/$(__gs_cur_libpkg).install
sed -e "s:@GNUSTEP_SYSTEM_LIBRARIES@:$(GNUSTEP_SYSTEM_LIBRARIES):g" \
-e "s:@GNUSTEP_SYSTEM_LIBRARY@:$(GNUSTEP_SYSTEM_LIBRARY):g" \
-e "s:@GNUSTEP_SYSTEM_HEADERS@:$(GNUSTEP_SYSTEM_HEADERS):g" \
-e "s/@FRAMEWORK@/$(__gs_curcomponent)/g; s/@FRAMEWORKVER@/$(__gs_cur_ver)/g" \
< $(_gs_debian_dir)/frameworkdev.install.in \
> debian/$(__gs_cur_devpkg).install
endef
$(patsubst %,gs-pre-install/%,$(DEB_GS_FRAMEWORKS)) :: gs-pre-install/%:
# generate lintian warning overrides
$(if $(DEB_GS_AUTO_LINTIAN_OVERRIDES)$(DEB_GS_AUTO_LINTIAN_OVERRIDES_$(__gs_curcomponent)),$(__gs_framework_update_lintian_overrides))
# generate the install files
$(if $(DEB_GS_AUTO_DH_INSTALL)$(DEB_GS_AUTO_DH_INSTALL_$(__gs_curcomponent)),$(__gs_framework_update_dh_install))
$(patsubst %,binary-install/%,$(__gs_frameworks_dev_packages)) :: binary-install/%:
# The "Current" symlink should only be in the lib package, and not in the dev
# package, but we need it for gsdh_gnustep to do the right thing. We can
# remove it after gsdh_gnustep is run.
rm -f debian/$(cdbs_curpkg)/$(GS_FRAMEWORKS_DIR)/*.framework/Versions/Current
#####
# Libraries
#####
define __gs_library_set_default_values
$(call __gs_set_default_value,DEB_GS_LCNAME_$(1),$(shell echo $(1) | tr [A-Z] [a-z]))
$(call __gs_set_default_value,DEB_GS_CURRENT_VERSION_NAME_$(1),A)
$(call __gs_set_default_value,DEB_GS_INTERFACE_VERSION_$(1),0)
$(call __gs_set_default_value,DEB_GS_LIBPKG_NAME_$(1),lib$(DEB_GS_LCNAME_$(1))$(DEB_GS_INTERFACE_VERSION_$(1)))
$(call __gs_set_default_value,DEB_GS_DEVPKG_NAME_$(1),$(DEB_GS_LIBPKG_NAME_$(1))-dev)
endef
$(foreach library,$(DEB_GS_LIBRARIES),$(eval $(call __gs_library_set_default_values,$(library))))
clean:: $(patsubst %,gs-clean/%,$(DEB_GS_LIBRARIES))
define __gs_library_rm_dh_install
rm -f debian/$(__gs_cur_libpkg).install
rm -f debian/$(__gs_cur_devpkg).install
endef
$(patsubst %,gs-clean/%,$(DEB_GS_LIBRARIES)) :: gs-clean/%:
# remove automatically generated .install files
$(if $(DEB_GS_AUTO_DH_INSTALL)$(DEB_GS_AUTO_DH_INSTALL_$(__gs_curcomponent)),$(__gs_library_rm_dh_install))
common-install-prehook-arch:: $(patsubst %,gs-pre-install/%,$(DEB_GS_LIBRARIES))
define __gs_library_update_dh_install
sed -e "s:@GNUSTEP_SYSTEM_LIBRARIES@:$(GNUSTEP_SYSTEM_LIBRARIES):g" \
-e "s/@LIBRARY@/$(__gs_curcomponent)/g" \
< $(_gs_debian_dir)/lib.install.in \
> debian/$(__gs_cur_libpkg).install
sed -e "s:@GNUSTEP_SYSTEM_LIBRARIES@:$(GNUSTEP_SYSTEM_LIBRARIES):g" \
-e "s:@GNUSTEP_SYSTEM_HEADERS@:$(GNUSTEP_SYSTEM_HEADERS):g" \
-e "s/@LIBRARY@/$(__gs_curcomponent)/g" \
< $(_gs_debian_dir)/libdev.install.in \
> debian/$(__gs_cur_devpkg).install
endef
$(patsubst %,gs-pre-install/%,$(DEB_GS_LIBRARIES)) :: gs-pre-install/%:
# generate the install files
$(if $(DEB_GS_AUTO_DH_INSTALL)$(DEB_GS_AUTO_DH_INSTALL_$(__gs_curcomponent)),$(__gs_library_update_dh_install))
|