blob: 380d0d21b88adbf5ccb77b5ffdf42f01532ffb72 [file] [log] [blame]
Thomas Jarosch06023f32011-02-08 22:09:36 +00001#!/usr/bin/make -f
2
3CONFIGURE_OPTIONS := --platform=M --lcdwidth=800 --lcdheight=480 --target=application --ram=8 --rbdir=/.rockbox --type=N
4DESKTOP_DIR := `pkg-config --variable=desktopentrydir osso-af-settings`
5
6export DH_VERBOSE=1
7
8builddir:
9 test -d builddir || mkdir -p builddir
10
11builddir/Makefile: builddir
12 cd builddir && test -f Makefile || ../tools/configure $(CONFIGURE_OPTIONS)
13
14build: build-stamp
15
16build-stamp: builddir/Makefile
17 dh_testdir
18 cd builddir && $(MAKE)
19 touch $@
20
21clean:
22 dh_testdir
23 dh_testroot
24 rm -f build-stamp
25 rm -rf builddir
26 dh_clean
27install: build
28 dh_testdir
29 dh_testroot
30 dh_clean -k
31 dh_installdirs
32
33 cd builddir && $(MAKE) PREFIX=$(CURDIR)/debian/rockbox/opt/rockbox fullinstall
34
35 # Install icon and .desktop file
36 mkdir -p $(CURDIR)/debian/rockbox/usr/share/icons/hicolor/64x64/apps
37 cp -f debian/maemo/rockbox.png $(CURDIR)/debian/rockbox/usr/share/icons/hicolor/64x64/apps
38 mkdir -p $(CURDIR)/debian/rockbox$(DESKTOP_DIR)
39 cp -f debian/maemo/rockbox.desktop $(CURDIR)/debian/rockbox$(DESKTOP_DIR)
40
41 # Ignore built in sounds
42 mkdir -p $(CURDIR)/debian/rockbox/usr/share/sounds
43 touch $(CURDIR)/debian/rockbox/usr/share/sounds/database.ignore
44
45# Build architecture-independent files here.
46binary-indep:
47# We have nothing to do by default.
48
49# Build architecture-dependent files here.
50binary-arch: build install
51 dh_testdir
52 dh_testroot
53 dh_installdocs
54 dh_installexamples
55 dh_installman
56 dh_link
57 dh_strip --dbg-package=rockbox-dbg
58 dh_compress
59 dh_fixperms
60 dh_installdeb
61 dh_shlibdeps
62 dh_gencontrol
63 dh_md5sums
64 dh_builddeb
65
66binary: binary-indep binary-arch
67.PHONY: build clean binary-indep binary-arch binary install configure