~ubuntu-branches/ubuntu/utopic/gnustep-back/utopic

« back to all changes in this revision

Viewing changes to debian/rules

  • Committer: Package Import Robot
  • Author(s): Yavor Doganov
  • Date: 2014-07-07 16:00:20 UTC
  • mfrom: (4.1.7 sid)
  • Revision ID: package-import@ubuntu.com-20140707160020-0ukvke5ml6ibbezv
Tags: 0.24.0-2
* Upload to unstable; should finally fix the piuparts issue once
  mknfonts.tool is binNMUed (Closes: #663388).
* debian/compat: Bump to 9 to get .build-id debugging symbols.
* debian/control.m4 (Build-Depends): Require debhlper >= 9.
  (Description): Mention that the art backend is deprecated.
  (Suggests): Remove fonts-freefont-ttf as -common depends on it.
* debian/control: Regenerate.
* debian/rules (confflags): Define conditionally and pass --host to
  configure only if cross-compiling.

Show diffs side-by-side

added added

removed removed

Lines of Context:
8
8
##################### VERSION NUMBERS ###########################
9
9
 
10
10
# GNUstep Gui version :
11
 
v_gui   := 0.22
 
11
v_gui   := 0.24
12
12
 
13
13
# GNUstep Back version :
14
14
sov_back := $(shell . ./Version; echo $$GNUSTEP_BACK_MAJOR_VERSION.$$GNUSTEP_BACK_MINOR_VERSION)
16
16
 
17
17
#################################################################
18
18
 
19
 
# These are used for cross-compiling and for saving the configure script
20
 
# from having to guess our platform (since we know it already)
21
 
DEB_BUILD_GNU_TYPE  ?= $(shell dpkg-architecture -qDEB_BUILD_GNU_TYPE)
22
 
DEB_HOST_GNU_TYPE   ?= $(shell dpkg-architecture -qDEB_HOST_GNU_TYPE)
23
 
#DEB_HOST_ARCH          := $(shell dpkg-architecture -qDEB_HOST_ARCH)
 
19
ifeq ($(DEB_BUILD_GNU_TYPE), $(DEB_HOST_GNU_TYPE))
 
20
confflags := --build $(DEB_BUILD_GNU_TYPE)
 
21
else
 
22
confflags := --build $(DEB_BUILD_GNU_TYPE) --host $(DEB_HOST_GNU_TYPE)
 
23
endif
24
24
 
25
25
# package names
26
26
p_back          = gnustep-back$(sov_back)
27
27
p_art           = gnustep-back$(sov_back)-art
28
28
p_cairo         = gnustep-back$(sov_back)-cairo
29
29
p_common        = gnustep-back-common
30
 
p_gpbs          = gnustep-gpbs
31
30
 
32
31
# package temp dirs
33
32
d_back          = $(CURDIR)/debian/$(p_back)
34
33
d_art           = $(CURDIR)/debian/$(p_art)
35
34
d_cairo         = $(CURDIR)/debian/$(p_cairo)
36
35
d_common        = $(CURDIR)/debian/$(p_common)
37
 
d_gpbs          = $(CURDIR)/debian/$(p_gpbs)
38
36
 
39
37
# build dirs
40
38
b_art           = build-art
73
71
        @: # dummy configure, to make back.make, etc., for building docs
74
72
        dh_testdir
75
73
        ./configure \
76
 
          --build=$(DEB_BUILD_GNU_TYPE) \
77
 
          --host=$(DEB_HOST_GNU_TYPE) \
78
 
          --target=$(DEB_HOST_GNU_TYPE) \
 
74
          $(confflags) \
79
75
          --with-x \
80
76
          --enable-graphics=art
81
77
 
90
86
        cd $(b_art) && ln -s ../GNUmakefile* .
91
87
        cd $(b_art) && ../configure CPPFLAGS="$(CPPFLAGS)" \
92
88
          CFLAGS="$(CFLAGS)" OBJCFLAGS="$(CFLAGS)" LDFLAGS="$(LDFLAGS)" \
93
 
          --build=$(DEB_BUILD_GNU_TYPE) \
94
 
          --host=$(DEB_HOST_GNU_TYPE) \
95
 
          --target=$(DEB_HOST_GNU_TYPE) \
 
89
          $(confflags) \
96
90
          --with-x \
97
91
          --enable-graphics=art \
98
92
          --with-name=art
106
100
        ln -s ../Headers ../Version ../configure $(b_cairo)
107
101
        cd $(b_cairo) && ../configure CPPFLAGS="$(CPPFLAGS)" \
108
102
          CFLAGS="$(CFLAGS)" OBJCFLAGS="$(CFLAGS)" LDFLAGS="$(LDFLAGS)" \
109
 
          --build=$(DEB_BUILD_GNU_TYPE) \
110
 
          --host=$(DEB_HOST_GNU_TYPE) \
111
 
          --target=$(DEB_HOST_GNU_TYPE) \
 
103
          $(confflags) \
112
104
          --with-x \
113
105
          --enable-graphics=cairo \
114
106
          --with-name=cairo
124
116
 
125
117
        touch $@
126
118
 
127
 
build-arch: debian/build-art-stamp debian/build-cairo-stamp debian/build-indep-stamp
 
119
build-arch: debian/build-art-stamp debian/build-cairo-stamp
128
120
clean_files += debian/build-art-stamp debian/build-cairo-stamp
129
121
debian/build-art-stamp: debian/configure-art-stamp
130
122
        dh_testdir
145
137
install-indep: build-indep
146
138
        $(MAKE) -C Documentation install DESTDIR=$(d_common)
147
139
 
148
 
        dh_link -p$(p_common) \
149
 
          $(GNUSTEP_SYSTEM_DOC)/Developer usr/share/doc/$(p_common)/Developer
150
 
 
151
140
install-arch: build-arch pre-install install-art install-cairo
152
141
 
153
142
pre-install:
160
149
 
161
150
        cd $(b_art) && $(MAKE) install fonts=no DESTDIR=$(d_art)
162
151
 
163
 
        : # Allow it to be used as a default backend
 
152
# Allow it to be used as a default backend.
164
153
        dh_link -p$(p_art) \
165
154
          $(GNUSTEP_SYSTEM_LIBRARY)/Bundles/libgnustep-art-$(ifv_back).bundle/libgnustep-art-$(ifv_back) \
166
155
          $(GNUSTEP_SYSTEM_LIBRARY)/Bundles/libgnustep-art-$(ifv_back).bundle/libgnustep-back-$(ifv_back)
167
156
 
168
 
        : # Move gpbs to gpbs package
169
 
        dh_installdirs -p$(p_gpbs) $(GNUSTEP_SYSTEM_TOOLS)
170
 
        mv $(d_art)/$(GNUSTEP_SYSTEM_TOOLS)/gpbs $(d_gpbs)/$(GNUSTEP_SYSTEM_TOOLS)
 
157
# Move gpbs to the -common package.
 
158
        dh_installdirs -p$(p_common) $(GNUSTEP_SYSTEM_TOOLS)
 
159
        mv $(d_art)/$(GNUSTEP_SYSTEM_TOOLS)/gpbs $(d_common)/$(GNUSTEP_SYSTEM_TOOLS)
171
160
        rm -rf $(d_art)/$(GNUSTEP_SYSTEM_DOC_MAN) $(d_art)/usr/bin
172
161
 
173
162
install-cairo: debian/build-cairo-stamp
203
192
        dh_testdir -a
204
193
        dh_testroot -a
205
194
        dh_installchangelogs -a ChangeLog
206
 
        dh_installdocs -a Documentation/{ANNOUNCE,NEWS,README}
 
195
        dh_installdocs -a
207
196
        gsdh_gnustep -a
208
 
        dh_installman -p$(p_gpbs) Tools/gpbs.1
 
197
        dh_installman -p$(p_common) Tools/gpbs.1
209
198
        dh_link -a
210
199
        dh_strip -a --dbg-package=gnustep-back-dbg
211
200
 
224
213
        sed -e 's:@GNUSTEP_LIBRARY@:$(GNUSTEP_SYSTEM_LIBRARY):g' \
225
214
            -e 's:@IFVER@:$(ifv_back):g' \
226
215
            -e 's:@BACKEND@:cairo:g' \
227
 
            -e 's:@PRIORITY@:5:g' \
 
216
            -e 's:@PRIORITY@:15:g' \
228
217
            debian/gnustep-back.postinst.in > debian/gnustep-back$(sov_back)-cairo.postinst
229
218
 
230
219
        sed -e 's:@GNUSTEP_LIBRARY@:$(GNUSTEP_SYSTEM_LIBRARY):g' \
231
220
            -e 's:@IFVER@:$(ifv_back):g' \
232
221
            -e 's:@BACKEND@:cairo:g' \
233
 
            -e 's:@PRIORITY@:5:g' \
 
222
            -e 's:@PRIORITY@:15:g' \
234
223
            debian/gnustep-back.prerm.in > debian/gnustep-back$(sov_back)-cairo.prerm
235
224
 
236
225
        dh_compress -a
238
227
        dh_makeshlibs -a -V
239
228
        dh_installdeb -a
240
229
 
241
 
        @: # override shlibs deps for gnustep-gui to avoid circular dependencies
 
230
# Override shlibs deps for gnustep-gui to avoid circular dependencies.
242
231
        echo "libgnustep-gui $(sov_back) libgnustep-gui$(sov_back) (>= $(v_gui)), gnustep-gui-runtime (>= $(v_gui))" > debian/shlibs.local
243
232
        dh_shlibdeps -a \
244
233
                -l$(d_back)/$(GNUSTEP_SYSTEM_LIBRARIES)