~ubuntu-branches/ubuntu/quantal/x11-xserver-utils/quantal

« back to all changes in this revision

Viewing changes to debian/xsfbs/xsfbs.mk

  • Committer: Bazaar Package Importer
  • Author(s): Robert Hooker
  • Date: 2010-08-09 10:24:12 UTC
  • mfrom: (5.1.2 sid)
  • Revision ID: james.westby@ubuntu.com-20100809102412-3j7ifv5scdrd5f8m
Tags: 7.5+2ubuntu1
* Merge from debian unstable. Remaining Ubuntu changes:
  - 101_xset_spellfix.patch: Spelling fix in help docs.

Show diffs side-by-side

added added

removed removed

Lines of Context:
110
110
.PHONY: prepare
111
111
stampdir_targets+=prepare
112
112
prepare: $(STAMP_DIR)/prepare
113
 
$(STAMP_DIR)/prepare: $(STAMP_DIR)/log $(STAMP_DIR)/genscripts
 
113
$(STAMP_DIR)/prepare: $(STAMP_DIR)/logdir $(STAMP_DIR)/genscripts
114
114
        >$@
115
115
 
116
 
.PHONY: log
117
 
stampdir_targets+=log
118
 
log: $(STAMP_DIR)/log
119
 
$(STAMP_DIR)/log: $(STAMP_DIR)/stampdir
 
116
.PHONY: logdir
 
117
stampdir_targets+=logdir
 
118
logdir: $(STAMP_DIR)/logdir
 
119
$(STAMP_DIR)/logdir: $(STAMP_DIR)/stampdir
120
120
        mkdir -p $(STAMP_DIR)/log
 
121
        >$@
121
122
 
122
123
# Apply all patches to the upstream source.
123
124
.PHONY: patch
145
146
 
146
147
# Revert all patches to the upstream source.
147
148
.PHONY: unpatch
148
 
unpatch: $(STAMP_DIR)/log
 
149
unpatch: $(STAMP_DIR)/logdir
149
150
        rm -f $(STAMP_DIR)/patch
150
151
        @echo -n "Unapplying patches..."; \
151
152
        if $(QUILT) applied >/dev/null 2>/dev/null; then \
176
177
xsfclean: cleanscripts unpatch
177
178
        dh_testdir
178
179
        rm -rf .pc
179
 
        rm -rf $(STAMP_DIR) $(SOURCE_DIR)
180
 
        rm -rf imports
181
 
        dh_clean debian/shlibs.local \
182
 
                 debian/po/pothead
183
 
 
184
 
# Generate the debconf templates POT file header.
185
 
debian/po/pothead: debian/po/pothead.in
186
 
        sed -e 's/SOURCE_VERSION/$(SOURCE_VERSION)/' \
187
 
          -e 's/DATE/$(shell date "+%F %X%z"/)' <$< >$@
188
 
 
189
 
# Update POT and PO files.
190
 
.PHONY: updatepo
191
 
updatepo: debian/po/pothead
192
 
        debian/scripts/debconf-updatepo --pot-header=pothead --verbose
 
180
        rm -rf $(STAMP_DIR)
 
181
        dh_clean
193
182
 
194
183
# Remove files from the upstream source tree that we don't need, or which have
195
184
# licensing problems.  It must be run before creating the .orig.tar.gz.
252
241
              | sed -e '/^#INCLUDE_SHELL_LIB#$$/d' >>$$MAINTSCRIPT.tmp; \
253
242
            sed -e 's/@SOURCE_VERSION@/$(SOURCE_VERSION)/' \
254
243
                -e 's/@OFFICIAL_BUILD@/$(OFFICIAL_BUILD)/' \
255
 
                -e 's/@DEFAULT_DCRESOLUTIONS@/$(DEFAULT_DCRESOLUTIONS)/' \
256
244
              <$$MAINTSCRIPT.tmp >$$MAINTSCRIPT; \
257
245
            rm $$MAINTSCRIPT.tmp; \
258
246
          fi; \
265
253
        #                                    debian/*.prerm
266
254
        >$@
267
255
 
268
 
# Generate the shlibs.local file.
269
 
debian/shlibs.local:
270
 
        cat debian/*.shlibs >$@
 
256
# Compute dependencies for drivers
 
257
#
 
258
VIDEODEP = $(shell cat /usr/share/xserver-xorg/videodrvdep 2>/dev/null)
 
259
INPUTDEP = $(shell cat /usr/share/xserver-xorg/xinputdep 2>/dev/null)
271
260
 
272
 
SERVERMINVERS = $(shell cat /usr/share/xserver-xorg/serverminver 2>/dev/null)
 
261
# these two can be removed post-squeeze
273
262
VIDEOABI = $(shell cat /usr/share/xserver-xorg/videoabiver 2>/dev/null)
274
263
INPUTABI = $(shell cat /usr/share/xserver-xorg/inputabiver 2>/dev/null)
275
 
SERVER_DEPENDS = xserver-xorg-core (>= $(SERVERMINVERS))
276
 
VIDDRIVER_PROVIDES = xserver-xorg-video-$(VIDEOABI)
277
 
INPDRIVER_PROVIDES = xserver-xorg-input-$(INPUTABI)
 
264
VIDDRIVER_PROVIDES = xserver-xorg-video-$(VIDEOABI), xorg-driver-video
 
265
INPDRIVER_PROVIDES = xserver-xorg-input-$(INPUTABI), xorg-driver-input
 
266
 
278
267
ifeq ($(PACKAGE),)
279
268
PACKAGE=$(shell awk '/^Package:/ { print $$2; exit }' < debian/control)
280
269
endif
281
270
 
282
271
.PHONY: serverabi
283
272
serverabi: install
284
 
ifeq ($(SERVERMINVERS),)
285
 
        @echo error: xserver-xorg-dev needs to be installed
 
273
ifeq ($(VIDEODEP),)
 
274
        @echo 'error: xserver-xorg-dev >= 1.7.6.901 needs to be installed'
286
275
        @exit 1
287
276
else
288
 
        echo "xserver:Depends=$(SERVER_DEPENDS)" >> debian/$(PACKAGE).substvars
 
277
        echo "xviddriver:Depends=$(VIDEODEP)" >> debian/$(PACKAGE).substvars
 
278
        echo "xinpdriver:Depends=$(INPUTDEP)" >> debian/$(PACKAGE).substvars
 
279
        # the following is there for compatibility...
289
280
        echo "xviddriver:Provides=$(VIDDRIVER_PROVIDES)" >> debian/$(PACKAGE).substvars
290
281
        echo "xinpdriver:Provides=$(INPDRIVER_PROVIDES)" >> debian/$(PACKAGE).substvars
 
282
        echo "xserver:Depends=$(VIDEODEP), $(INPUTDEP)" >> debian/$(PACKAGE).substvars
291
283
endif
292
284
 
293
285
# vim:set noet ai sts=8 sw=8 tw=0: