debian swirl logo

Back to the packages list console-data

#!/usr/bin/make -f

include /usr/share/cdbs/1/rules/debhelper.mk

# Automatically controls patching at build time:
include /usr/share/cdbs/1/class/autotools.mk

# All the small .udebs that get built
EXTRA_UDEB_PKGS    = 	console-keymaps-mac	\
			console-keymaps-sun	\
			console-keymaps-acorn	\
			console-keymaps-atari	\
			console-keymaps-amiga	\
			console-keymaps-usb	\
			console-keymaps-dec
OPTIONAL_UDEB_PKGS = console-keymaps-at
UDEB_PKGS= ${OPTIONAL_UDEB_PKGS} ${EXTRA_UDEB_PKGS}

DEB_CONFIGURE_EXTRA_FLAGS := --with-main_compressor=gzip

# DEB_DESTDIR = $(CURDIR)/build-tree

clean::
		rm -rf debian/console-data.config debian/console-data.templates debian/sort-tmp debian/locales debian/substvars

install/console-data::
	make install DESTDIR= $(CURDIR)/debian/tmp
	make install DESTDIR= $(CURDIR)/debian/console-data
	# Remove useless empty directory
		rmdir $(CURDIR)/debian/console-data/usr/share/videomodes

		chmod +x debian/gen-acorn-keymaps
		debian/gen-acorn-keymaps

        # For convenience of programs that want a list of supported keymaps
			chmod u+x $(CURDIR)/debian/list-keymaps.pl
		$(CURDIR)/debian/list-keymaps.pl $(CURDIR)/debian/console-data.keymaps > $(CURDIR)/debian/console-data/usr/share/console/lists/console-data.keymap-list

		dh_consoledata -i
	# Needed for ubiquity
		for f in $(CURDIR)/debian/console-keymaps-*.templates; do \
		         echo >> $(CURDIR)/debian/console-data.templates ; \
		         cat $$f >> $(CURDIR)/debian/console-data.templates ; \
		done

		for PO in $(CURDIR)/debian/po/*.po; do \
		L= "$$(basename $$PO .po)"; \
			install -d $(CURDIR)/debian/console-data/usr/share/locale/$$L/LC_MESSAGES; \
			msgfmt -o $(CURDIR)/debian/console-data/usr/share/locale/$$L/LC_MESSAGES/console-data.mo $$PO; \
		done

binary-predeb/console-data::
	# Sort keymaps (including in translations)
	# MUST be after dh_installdebconf
		sh debian/sort-keymaps


common-binary-post-install-indep::
		chmod +x debian/trim_keymaps.sh
		for P in ${UDEB_PKGS}; do                                                               \
                ./debian/trim_keymaps.sh $(CURDIR)/debian/$${P} ;                               \
		done

Builds:

console-data
keymaps, fonts, charset maps, fallback tables for console-tools
console-keymaps-acorn
keymaps for acorn risc-pc keyboards
console-keymaps-amiga
keymaps for amiga keyboards
console-keymaps-atari
keymaps for atari keyboards
console-keymaps-at
keymaps for pc-style (ps/2 and at) keyboards
console-keymaps-dec
keymaps for dec keyboards
console-keymaps-mac
keymaps for apple keyboards
console-keymaps-sun
keymaps for sun keyboards
console-keymaps-usb
keymaps for usb keyboards