1 diff -Naur blueprobe.orig/Makefile blueprobe/Makefile
2 --- blueprobe.orig/Makefile 2007-02-10 16:23:12.158675487 +0200
3 +++ blueprobe/Makefile 2007-02-10 16:27:53.906731396 +0200
14 ifeq ($(CVSBUILD),yes)
22 diff -Naur blueprobe.orig/Makefile.dpkg_ipkg blueprobe/Makefile.dpkg_ipkg
23 --- blueprobe.orig/Makefile.dpkg_ipkg 1970-01-01 02:00:00.000000000 +0200
24 +++ blueprobe/Makefile.dpkg_ipkg 2007-02-10 16:28:13.211831530 +0200
26 +## Please read the README in this directory to see how to use this
29 +# Let's use whatever clean target the specific app provides
31 +CONTROL = `if test -e familiar/control1; then echo control1; else echo control; fi`
33 +# URL to source tarball
34 +SOURCE = http://gpe.linuxtogo.org/download/source/$(PACKAGE)-$(VERSION).tar.gz
36 +# can change this to e.g. /var/tmp/deb
39 +ifeq ($(CVSBUILD),yes)
40 +LIBGPEWIDGET_PC = libgpewidget-uninstalled
41 +PC_EXTRA=PKG_CONFIG_PATH=../../base/libgpewidget
43 +LIBGPEWIDGET_PC = libgpewidget
46 +ifeq ($(IN_LIBGPEWIDGET),)
47 +GPECFLAGS = $(shell $(PC_EXTRA) pkg-config --cflags $(LIBGPEWIDGET_PC))
48 +GPELIBS = $(shell $(PC_EXTRA) pkg-config --libs $(LIBGPEWIDGET_PC))
51 +GTKCFLAGS = $(shell pkg-config --cflags gtk+-2.0)
52 +GTKLIBS = $(shell pkg-config --libs gtk+-2.0)
54 +STANDARD_CPPFLAGS = -D_GNU_SOURCE -DPACKAGE=\"$(PACKAGE)\" -DPREFIX=\"$(PREFIX)\" -DPACKAGE_LOCALE_DIR=\"$(PREFIX)/share/locale\"
55 +STANDARD_CFLAGS = -MD -Wall
61 +CFLAGS += -Os -fomit-frame-pointer
64 +dist: check-source clean dist-prep
65 + rm -rf ../$(PACKAGE)-$(VERSION)
66 + mkdir ../$(PACKAGE)-$(VERSION)
67 + ( tar cf - --exclude "*/CVS" --exclude CVS --exclude "*~" --exclude "#*#" --exclude "debian" --exclude ".*" --exclude "*.ipk" --exclude "*.ipk.*" --exclude "*.mo" --exclude "*.batch" --exclude "translation-ipkgs.txt" * ) | (cd ../$(PACKAGE)-$(VERSION); tar xf -)
68 + ( if [ -f linguas ]; then LINGUAS=`cat linguas`; PATCH_LINGUAS="s:^LINGUAS =.*:LINGUAS = $${LINGUAS}:"; fi; cd ../$(PACKAGE)-$(VERSION) && mkdir build && cp $(BUILD)/Makefile.dpkg_ipkg $(BUILD)/Makefile.translation build/ && sed "s:^CVSBUILD =.*:CVSBUILD = no:;s:^DEBUG =.*:DEBUG = no:;s:Makefile.translation-auto-linguas:Makefile.translation:;$${PATCH_LINGUAS}" < Makefile > Makefile.new && mv Makefile.new Makefile )
69 + ( cd .. ; tar cf - $(PACKAGE)-$(VERSION) | gzip -9 >$(PACKAGE)-$(VERSION).tar.gz )
70 + rm -rf ../$(PACKAGE)-$(VERSION)
74 + scp ../$(PACKAGE)-$(VERSION).tar.gz $(USER)@linuxtogo.org:/media/data/projects/gpe/source/
79 +# empty, can be filled in Makefile.translation
81 +install: install-program install-mo
84 + rm -rf familiar/dist familiar/dist.list
89 + @if [ -f familiar/$(CONTROL) ] && ! grep -q '^Source:' familiar/$(CONTROL); then echo -e "\nNo Source: field in control file. Aborting.\n"; exit 1; fi
91 +ipkg: check-source ipkg-prep clean
92 + rm -rf familiar/dist
93 + mkdir -p familiar/dist/CONTROL
94 + sed 's:VERSION:$(VERSION):;s$$SOURCE$$$(SOURCE)$$' < familiar/$(CONTROL) > familiar/dist/CONTROL/control
95 + if test -e familiar/conffiles; then install -m 644 familiar/conffiles familiar/dist/CONTROL; fi
96 + if test -e familiar/preinst; then install familiar/preinst familiar/dist/CONTROL; fi
97 + if test -e familiar/postinst; then install familiar/postinst familiar/dist/CONTROL; fi
98 + if test -e familiar/prerm; then install familiar/prerm familiar/dist/CONTROL; fi
99 + if test -e familiar/postrm; then install familiar/postrm familiar/dist/CONTROL; fi
100 + $(MAKE) DESTDIR=`pwd`/familiar/dist PREFIX=/usr prefix=/usr DEBUG=no install-program
101 + rm -rf familiar/dist.list
102 + ipkg-build -o 0 -g 0 familiar/dist | sed 's/^Packaged .*into //; t 1; d; : 1; s:.*/::' >> familiar/dist.list
103 + if [ "x$(LINGUAS)" != "x" ]; then make translation-ipkg; tr ' ' '\n' < translation-ipkgs.txt >> familiar/dist.list; fi
104 + md5sum `cat familiar/dist.list` > $(PACKAGE)_$(VERSION).batch
105 + rm -rf familiar/dist familiar/dist.list
109 + mkdir -p $(DEB_PATH)
110 + ( olddir=`pwd`; cd $(DEB_PATH); rm -rf $(PACKAGE)-$(VERSION); ln -s $$olddir/../$(PACKAGE)-$(VERSION).tar.gz $(PACKAGE)_$(VERSION).orig.tar.gz ; tar xzf $(PACKAGE)_$(VERSION).orig.tar.gz )
111 + mkdir -p $(DEB_PATH)/$(PACKAGE)-$(VERSION)/debian
112 + for i in debian/*; do if test -f $$i; then cp $$i $(DEB_PATH)/$(PACKAGE)-$(VERSION)/debian/; fi; done
114 +CVSTAG := $(shell echo $(PACKAGE)-$(VERSION) | tr [a-z.] [A-Z_])
116 + @printf '-------------------------------------------------------------------------------\n'
117 + @printf "If this becomes a package release, please add a CVS tag.\n"
118 + @printf "You can use 'make tag' for that, it will execute\n"
119 + @printf " cvs tag %s\n" $(CVSTAG)
120 + @printf "Please upload a tarball (created with 'make dist') to\n"
121 + @printf " ftp://ftp.handhelds.org/pub/projects/gpe/\n"
122 + @printf " (handhelds.org:~ftp/pub/projects/gpe/source)\n"
123 + @printf "You can use 'make dist-upload' to do that.\n"
124 + @printf "You are currently known as USER %s.\n" $(USER)
125 + @printf '-------------------------------------------------------------------------------\n'
131 + cvs tag -F $(CVSTAG)
133 +source: tag dist-upload
136 + sed 's:PREFIX:$(PREFIX):;s:BUILDDIR:$(shell pwd):;s:VERSION:$(VERSION):' < $< > $@
139 + $(CC) $(CFLAGS) $(CPPFLAGS) $(PACKAGE_CFLAGS) $(PACKAGE_CPPFLAGS) -c $< -o $@
140 diff -Naur blueprobe.orig/Makefile.translation blueprobe/Makefile.translation
141 --- blueprobe.orig/Makefile.translation 1970-01-01 02:00:00.000000000 +0200
142 +++ blueprobe/Makefile.translation 2007-02-10 16:28:17.996104169 +0200
144 +.SUFFIXES: .mo .po .pot .po8
146 +CONTROL = `if test -e familiar/control1; then echo control1; else echo control; fi`
148 +# use ipkg-build or ipkg-deb-build
149 +IPKG_BUILD := ipkg-build
151 +TRANSLATION_SITE := http://www.iro.umontreal.ca/~gnutra/maint
157 +ifeq ($(BINPACKAGE),)
158 +BINPACKAGE := $(PACKAGE)
161 +mo-files = $(patsubst %,$(DIR_PO)/%.mo,$(LINGUAS))
162 +po-files = $(patsubst %,$(DIR_PO)/%.po,$(LINGUAS))
164 +ifeq ($(shell if [ -f $(PACKAGE).desktop.in ]; then echo present; fi;),present)
165 +desktop-files += $(PACKAGE).desktop
168 +ifneq ($(EXTRA_DESKTOPS),)
169 +desktop-files += $(patsubst %.desktop.in,%.desktop,$(EXTRA_DESKTOPS))
174 +all-desktop: $(desktop-files)
177 + if [ "$(ENABLE_NLS)" != "no" ]; then \
178 + if [ "x$(LINGUAS)" != "x" ]; then \
179 + for i in $(LINGUAS); do mkdir -p $(DESTDIR)$(PREFIX)/share/locale/$$i/LC_MESSAGES; install -m 644 $(DIR_PO)/$$i.mo $(DESTDIR)$(PREFIX)/share/locale/$$i/LC_MESSAGES/$(PACKAGE).mo; done \
184 + if [ "$(ENABLE_NLS)" != "no" ]; then \
189 + CTYPE=`grep "^\"Content-Type:" $< | sed 's/^.*charset=//;s/\\\\.*//'`; sed "s/\(Content-Type: .*=\)$$CTYPE/\1UTF-8/" < $< | iconv -f $${CTYPE} -t UTF-8 >$@
191 +update-po: $(po-files) extract-po
193 +dist-prep: update-po freshen-po
196 +ifeq ($(CVSBUILD),yes)
197 +ipkg-prep: freshen-po
203 + ( SOURCES="$(SOURCES)"; for DESK in $(PACKAGE).desktop.in $(EXTRA_DESKTOPS); do if [ -f $$DESK ]; then intltool-extract --type=gettext/ini $$DESK; SOURCES="$$SOURCES $${DESK}.h"; fi; done; if [ "x$$SOURCES" != "x" ]; then xgettext --add-comments=TRANSLATORS: -k_ -kN_ -o $(DIR_PO)/$(PACKAGE).pot.new $$SOURCES; fi )
204 + if [ -f $(DIR_PO)/$(PACKAGE).pot.new ]; then if cmp -s $(DIR_PO)/$(PACKAGE).pot.new $(PACKAGE).pot; then rm $(DIR_PO)/$(PACKAGE).pot.new; else mv $(DIR_PO)/$(PACKAGE).pot.new $(DIR_PO)/$(PACKAGE).pot; fi; fi
206 +clean: clean-po clean-dist-translation
209 + rm -rf $(DIR_PO)/*.mo
210 + for i in $(desktop-files); do if [ -f $$i.in ]; then rm -f $$i; rm -f $$i.in.h; fi; done
212 +%.desktop: %.desktop.in $(patsubst %,$(DIR_PO)/%.po,$(LINGUAS))
213 + intltool-merge -u -d $(DIR_PO) $< $@
218 + cd tmp-po; for LANG in $(LINGUAS); do wget $(TRANSLATION_SITE)/$(PACKAGE)/$$LANG.po; done
219 + for LANG in $(LINGUAS); do if [ ! -f $(DIR_PO)/$$LANG.po ] || ! cmp -s $(DIR_PO)/$$LANG.po tmp-po/$$LANG.po ; then mv tmp-po/$$LANG.po $(DIR_PO)/$$LANG.po; echo "Updated $$LANG translation"; fi; done
222 +# ------------------------------------------------------------------------
224 +MAINTAINER = $(shell grep 'Maintainer: ' familiar/$(CONTROL) | cut -d ' ' -f 2-)
230 +transdist := familiar/dist-translation
231 +templates := $(BUILD)/familiar
232 +ipkglist := translation-ipkgs.txt
234 +clean-dist-translation:
235 + rm -rf $(transdist) $(ipkglist)
237 +real-translation-package: all-mo
238 + rm -rf $(transdist) $(ipkglist)
239 + for LINGUA in $(LINGUAS); do \
240 + i=$$(echo $$LINGUA | tr '[A-Z_]' '[a-z+]'); \
241 + mkdir -p $(transdist)/$$i/CONTROL; \
242 + mkdir -p $(transdist)/$$i$(PREFIX)/share/locale/$$LINGUA/LC_MESSAGES; \
243 + install -m 644 po/$$LINGUA.mo $(transdist)/$$i$(PREFIX)/share/locale/$$LINGUA/LC_MESSAGES/$(PACKAGE).mo; \
244 + sed -e "s/<maintainer>/$(MAINTAINER)/;s/<package>/$(BINPACKAGE)/;s/<version>/$(VERSION)/;s/<language>/$$i/;s!<source>!$(SOURCE)!" $(templates)/control.translation > $(transdist)/$$i/CONTROL/control; \
245 + install $(templates)/postinst.translation $(transdist)/$$i/CONTROL/postinst; \
246 + $(IPKG_BUILD) -g 0 -o 0 $(transdist)/$$i | sed 's/^Packaged .*into //; t 1; d; : 1; s:.*/::' >> $(ipkglist); \
250 + make PREFIX=/usr real-translation-package