|
1
by Fabien Tassin
* Initial release based on WebRunner 0.07 SVN 20070925r7025 |
1 |
#!/usr/bin/make -f
|
2 |
||
|
84
by Fabien Tassin
* New packaging using cdbs and the new xulapp build-system |
3 |
# These are used for cross-compiling and for saving the configure script
|
4 |
# from having to guess our platform (since we know it already)
|
|
5 |
DEB_HOST_GNU_TYPE ?= $(shell dpkg-architecture -qDEB_HOST_GNU_TYPE) |
|
6 |
DEB_BUILD_GNU_TYPE ?= $(shell dpkg-architecture -qDEB_BUILD_GNU_TYPE) |
|
7 |
DEB_BUILD_ARCH ?= $(shell dpkg-architecture -qDEB_BUILD_ARCH) |
|
8 |
||
|
125
by Micah Gersten
* fix LP: #504524 - migrate from mozilla-devscripts to in package mozclient |
9 |
DEBIAN_NAME = prism |
|
128
by Micah Gersten
* Update from xulrunner-1.9.1 to xulrunner-1.9.2 |
10 |
DEBIAN_XUL_VER := $(shell xulrunner-1.9.2 --gre-version) |
|
84
by Fabien Tassin
* New packaging using cdbs and the new xulapp build-system |
11 |
DEBIAN_XUL_DEV := /usr/lib/xulrunner-devel-$(DEBIAN_XUL_VER) |
12 |
DEBIAN_PRISM_VER = $(shell grep ^MOZ_APP_VERSION= prism/confvars.sh | cut -d= -f2) |
|
13 |
DEBIAN_PRISM_DIR = usr/lib/prism-$(DEBIAN_PRISM_VER) |
|
14 |
||
15 |
DEB_AUTO_UPDATE_AUTOCONF = 2.13 |
|
16 |
||
|
125
by Micah Gersten
* fix LP: #504524 - migrate from mozilla-devscripts to in package mozclient |
17 |
MOZCLIENT_PROJECTNAME := $(DEBIAN_NAME) |
18 |
MOZCLIENT_PROJECTDIR := $(CURDIR)/debian/mozclient |
|
|
94
by Fabien Tassin
* Add the refractor extension in the main prism package. This requires |
19 |
MOZ_XPI_BUILD_COMMAND := $(NULL) |
20 |
||
|
84
by Fabien Tassin
* New packaging using cdbs and the new xulapp build-system |
21 |
include /usr/share/cdbs/1/rules/patchsys-quilt.mk |
22 |
include /usr/share/cdbs/1/rules/debhelper.mk |
|
23 |
include /usr/share/cdbs/1/class/autotools.mk |
|
|
125
by Micah Gersten
* fix LP: #504524 - migrate from mozilla-devscripts to in package mozclient |
24 |
include $(CURDIR)/debian/mozclient/$(DEBIAN_NAME).mk |
|
94
by Fabien Tassin
* Add the refractor extension in the main prism package. This requires |
25 |
include /usr/share/mozilla-devscripts/xpi.mk |
|
10
by Fabien Tassin
* Add support for quilt |
26 |
|
|
84
by Fabien Tassin
* New packaging using cdbs and the new xulapp build-system |
27 |
DEB_CONFIGURE_USER_FLAGS = \ |
28 |
--with-libxul-sdk=$(DEBIAN_XUL_DEV) \ |
|
29 |
--enable-application=prism \ |
|
|
117
by Micah Gersten
[ Micah Gersten ] |
30 |
--with-system-libxul \ |
|
87
by Fabien Tassin
* Build with --with-system-nspr/nss, this is now necessary as upstream |
31 |
--with-system-nspr \ |
32 |
--with-system-nss \ |
|
|
84
by Fabien Tassin
* New packaging using cdbs and the new xulapp build-system |
33 |
--disable-debug \ |
34 |
--disable-crashreporter \ |
|
35 |
--with-distribution-id=com.ubuntu \ |
|
36 |
$(NULL) |
|
37 |
||
|
3
by Fabien Tassin
* Improve WebApps icons and add Gmail |
38 |
WEBAPPS = \ |
|
65
by Fabien Tassin
* Quote elements of WEBAPPS to avoid bogus ';' introduces in the |
39 |
"facebook@facebook@Facebook@http://www.facebook.com/@GTK;Network;" \
|
|
84
by Fabien Tassin
* New packaging using cdbs and the new xulapp build-system |
40 |
"google-analytics@ganalytics@Google~Analytics@http://analytics.google.com/@GTK;Network;" \
|
41 |
"google-calendar@gcalendar@Google~Calendar@https://www.google.com/calendar@GTK;Office;Calendar;" \
|
|
42 |
"google-docs@gdocs@Google~Docs@https://docs.google.com/@GTK;Office;Spreadsheet;WordProcessor;" \
|
|
43 |
"google-mail@gmail@Google~Mail~\(GMail\)@https://mail.google.com/@GTK;Network;Email;" \
|
|
44 |
"google-reader@greader@Google~Reader@https://www.google.com/reader@GTK;Network;News;" \
|
|
45 |
"google-groups@groups@Google~Groups@http://groups.google.com/groups/favorites@GTK;Network;News;" \
|
|
46 |
"google-talk@gtalk@Google~Talk@http://talkgadget.google.com/talkgadget/popout@GTK;Network;InstantMessaging;" \
|
|
|
65
by Fabien Tassin
* Quote elements of WEBAPPS to avoid bogus ';' introduces in the |
47 |
"twitter@twitter@twitter@http://www.twitter.com/@GTK;Network;" \
|
|
3
by Fabien Tassin
* Improve WebApps icons and add Gmail |
48 |
$(NULL) |
49 |
||
|
84
by Fabien Tassin
* New packaging using cdbs and the new xulapp build-system |
50 |
ALL_WEBAPPS = $(shell echo $(WEBAPPS) | sed -e 's/\([^@]*\)@[^ ]*\( *\)/\1\2/g') |
51 |
||
|
130
by Micah Gersten
* Add clean target to rules to clean up for the changes for xulrunner 1.9.2 |
52 |
clean:: |
53 |
rm -rf testing tools |
|
54 |
||
|
117
by Micah Gersten
[ Micah Gersten ] |
55 |
build/prism:: |
|
107
by Alexander Sack
* fix build breakage, by copying the refractor.xpi to top level dir; adjust MOZ_XPI_FILE |
56 |
cp -f dist/xpi-stage/refractor.xpi . |
57 |
||
|
84
by Fabien Tassin
* New packaging using cdbs and the new xulapp build-system |
58 |
binary-install/prism:: |
59 |
mv debian/tmp/usr/bin/prism debian/tmp/usr/bin/prism-bin |
|
60 |
install -m 755 debian/prism.sh debian/tmp/usr/bin/prism |
|
61 |
dh_install -pprism debian/tmp/usr/bin |
|
62 |
||
|
109
by Alexander Sack
* ship prism-addons/extensions dir to fix dangling symlink |
63 |
dh_installdirs -pprism usr/lib/prism-addons/extensions |
|
84
by Fabien Tassin
* New packaging using cdbs and the new xulapp build-system |
64 |
dh_link -pprism usr/lib/prism-addons/extensions $(DEBIAN_PRISM_DIR)/extensions |
|
114
by Sasa Bodiroza
* In debian/rules: |
65 |
dh_link -pprism $(DEBIAN_PRISM_DIR) /usr/share/prism/prism |
|
33
by Fabien Tassin
* Remove MimeType from WebApp desktop files, except from the main prism |
66 |
# Icons |
|
84
by Fabien Tassin
* New packaging using cdbs and the new xulapp build-system |
67 |
install -m 644 debian/tmp/$(DEBIAN_PRISM_DIR)/chrome/icons/default/install-shortcut48.png \ |
68 |
debian/tmp/$(DEBIAN_PRISM_DIR)/chrome/icons/default/app.png |
|
69 |
install -d -m 755 debian/tmp/usr/share/pixmaps |
|
70 |
install -m 644 debian/tmp/$(DEBIAN_PRISM_DIR)/chrome/icons/default/install-shortcut48.png \ |
|
71 |
debian/tmp/usr/share/pixmaps/prism.png |
|
72 |
dh_install -pprism debian/tmp/usr/share/pixmaps/prism.png |
|
|
80
by Fabien Tassin
* New upstream snapshot: 0.9+svn20080403r11903 |
73 |
for size in 48 ; do \ |
|
45
by Fabien Tassin
* Use install instead of mkdir/cp |
74 |
install -d -m 755 debian/tmp/usr/share/icons/gnome/$${size}x$${size}/mimetypes ; \ |
|
84
by Fabien Tassin
* New packaging using cdbs and the new xulapp build-system |
75 |
install -m 644 debian/tmp/$(DEBIAN_PRISM_DIR)/chrome/icons/default/install-shortcut$$size.png \ |
76 |
debian/tmp/usr/share/icons/gnome/$${size}x$${size}/mimetypes/gnome-mime-application-vnd.mozilla.webapp.png ; \ |
|
|
33
by Fabien Tassin
* Remove MimeType from WebApp desktop files, except from the main prism |
77 |
done
|
|
84
by Fabien Tassin
* New packaging using cdbs and the new xulapp build-system |
78 |
dh_install -pprism debian/tmp/usr/share/icons |
79 |
||
80 |
touch debian/prism/$(DEBIAN_PRISM_DIR)/.autoreg |
|
81 |
||
82 |
$(patsubst %,build/prism-%,$(ALL_WEBAPPS)):: WEBAPP = $(subst build/prism-,,$@) |
|
83 |
$(patsubst %,build/prism-%,$(ALL_WEBAPPS)):: LINE = $(filter "$(WEBAPP)%",$(WEBAPPS)) |
|
84 |
$(patsubst %,build/prism-%,$(ALL_WEBAPPS)):: APP = $(firstword $(subst @, ,$(subst "$(WEBAPP)@,,$(LINE)))) |
|
85 |
$(patsubst %,build/prism-%,$(ALL_WEBAPPS)):: |
|
86 |
install -d -m 755 debian/tmp/usr/share/prism/apps |
|
87 |
install -m 644 prism/install/profiles/$(APP).webapp debian/tmp/usr/share/prism/apps |
|
88 |
install -d -m 755 debian/tmp/usr/share/applications |
|
89 |
install -m 644 debian/prism-$(WEBAPP).desktop debian/tmp/usr/share/applications |
|
90 |
# Fetch the xpm icon from the webapp and turn it into a png for the desktop file |
|
91 |
cd debian && unzip tmp/usr/share/prism/apps/$(APP).webapp $(APP).xpm || test $$? = 11 |
|
92 |
if [ -e debian/$(APP).xpm ] ; then \ |
|
93 |
convert debian/$(APP).xpm debian/$(APP).png ; \ |
|
94 |
( cd debian ; zip tmp/usr/share/prism/apps/$(APP).webapp $(APP).png ) ; \ |
|
95 |
mv debian/$(APP).png debian/prism-$(WEBAPP).png ; \ |
|
96 |
rm -f debian/$(APP).xpm ; \ |
|
97 |
else \
|
|
98 |
cp dist/bin/chrome/icons/default/install-shortcut48.png debian/prism-$(WEBAPP).png ; \ |
|
99 |
fi
|
|
|
45
by Fabien Tassin
* Use install instead of mkdir/cp |
100 |
install -d -m 755 debian/tmp/usr/share/pixmaps |
|
84
by Fabien Tassin
* New packaging using cdbs and the new xulapp build-system |
101 |
install -m 644 debian/prism-$(WEBAPP).png debian/tmp/usr/share/pixmaps |
102 |
# Fix webapp.ini if there's no 'name' field |
|
103 |
cd debian && unzip tmp/usr/share/prism/apps/$(APP).webapp webapp.ini |
|
104 |
if [ -e debian/webapp.ini ] && [ `grep -c ^name= debian/webapp.ini` -eq 0 ] ; then \ |
|
105 |
perl -i -pe 's/^(id=.*)/$$1\nname=$(APP)/' debian/webapp.ini ; \ |
|
106 |
( cd debian ; zip -u tmp/usr/share/prism/apps/$(APP).webapp webapp.ini ) ; \ |
|
107 |
rm -f debian/webapp.ini ; \ |
|
108 |
fi
|
|
|
85
by Fabien Tassin
* Patch webapps to include to ship an override.ini file allowing each webapp |
109 |
# Add an override.ini file if it's missing |
110 |
cd debian && unzip tmp/usr/share/prism/apps/$(APP).webapp override.ini || test $$? = 11 |
|
111 |
if [ ! -e debian/override.ini ] ; then \ |
|
112 |
echo "[App]\nVendor=Prism\nName=$(APP)" > debian/override.ini ; \ |
|
113 |
( cd debian ; zip -u tmp/usr/share/prism/apps/$(APP).webapp override.ini ) ; \ |
|
114 |
rm -f debian/override.ini ; \ |
|
115 |
fi
|
|
|
93
by Fabien Tassin
* Clean-up png files created at build time |
116 |
|
117 |
clean:: |
|
118 |
rm -f debian/prism-*.png |
|
|
107
by Alexander Sack
* fix build breakage, by copying the refractor.xpi to top level dir; adjust MOZ_XPI_FILE |
119 |
rm -f refractor.xpi |
|
129
by Micah Gersten
* Have make clean delete .so files as well |
120 |
find -type f \( -name '*.a' -o -name '*.o' -o -name '*.xpt' -o -name Makefile -o -name '*.so' \) -delete |
|
119.1.1
by Benjamin Drung
Clean the package properly in the clean target (LP: #460466). |
121 |
rm -rf _leaktest |
122 |
rm -rf prism/components/public/.deps prism/components/public/_xpidlgen |
|
123 |
rm -rf prism/components/src/.deps |