]> www.wagner.pp.ru Git - oss/btcli.git/commitdiff
Added makefile to build Debian package
authorVictor Wagner <vitus@wagner.pp.ru>
Mon, 28 Jul 2008 07:50:56 +0000 (07:50 +0000)
committerVictor Wagner <vitus@wagner.pp.ru>
Mon, 28 Jul 2008 07:50:56 +0000 (07:50 +0000)
Makefile [new file with mode: 0644]
btpasskey/Makefile
packaging/btpasskey-debian/changelog
packaging/btpasskey-debian/control

diff --git a/Makefile b/Makefile
new file mode 100644 (file)
index 0000000..8f264eb
--- /dev/null
+++ b/Makefile
@@ -0,0 +1,27 @@
+BTPASS_VERSION=1.2
+BTPASS_PKG_VERSION=1
+ARCH:=$(shell dpkg-architecture -qDEB_BUILD_ARCH)
+export BTPASS_VERSION
+
+PKG=btpasskey_$(BTPASS_VERSION)-$(BTPASS_PKG_VERSION)_$(ARCH).deb
+ORIG=btpasskey_$(BTPASS_VERSION).orig.tar.gz
+BUILDDIR=btpasskey-$(BTPASS_VERSION)
+btpasskey: $(PKG)
+
+$(PKG): $(ORIG) $(BUILDDIR)/debian/rules
+       cd $(BUILDDIR); debuild
+
+$(BUILDDIR)/debian/rules: $(BUILDDIR)/btpasskey.c 
+       -mkdir $(BUILDDIR)/debian
+       -cp -p packaging/btpasskey-debian/* $(BUILDDIR)/debian
+       sed 's!prefix=/usr/local!prefix=/usr!' btpasskey/Makefile > $(BUILDDIR)/Makefile
+$(BUILDDIR)/btpasskey.c: btpasskey/btpasskey.c btpasskey/btpasskey.1 btpasskey/Makefile
+       -mkdir $(BUILDDIR)
+       cp -p $+ $(BUILDDIR)
+
+$(ORIG): $(BUILDDIR)/btpasskey.c
+       tar czf $@ $(BUILDDIR)
+
+clean:
+       rm -rf $(BUILDDIR) btpasskey_$(BTPASS_VERSION)*
+
index 21380db04e98b535798bacf3392240b4f82b7922..1e65a6b0aa2e5239a67485e0e623640f0e55b5a0 100644 (file)
@@ -1,8 +1,12 @@
 # this Makefile is for building btcli it depends on pkg-config libdbus-1-dev (and build-essential) packages 
+BTPASS_VERSION?=1.2
+prefix=/usr/local
 btpasskey: btpasskey.c
-       $(CC) `pkg-config --libs --cflags dbus-1`  -g -DDBUS_API_SUBJECT_TO_CHANGE -DVERSION="\"1.1\"" -o btpasskey btpasskey.c 
+       $(CC) `pkg-config --libs --cflags dbus-1`  -g -DDBUS_API_SUBJECT_TO_CHANGE -DVERSION="\"$(BTPASS_VERSION)\"" -o btpasskey btpasskey.c 
 
 install: btpasskey
-       install -m 755 -o root btpasskey /usr/bin 
-       install -m 644 -o root btpasskey.1 /usr/share/man/man1
+       install -m 755 -o root btpasskey $(DESTDIR)$(prefix)/bin 
+       install -m 644 -o root btpasskey.1 $(DESTDIR)$(prefix)/share/man/man1
 
+clean:
+       rm *.o btpasskey
index 84903051b5fd3f763c60cb8c73ba71ce77098671..eab83732f62da2f9656de60833b6b9aefc437489 100644 (file)
@@ -1,3 +1,9 @@
+btpasskey (1.2-1) unstable; urgency=low
+
+  * New upstream release
+
+ -- Victor Wagner <vitus@wagner.pp.ru>  Sun, 11 Nov 2007 22:22:00 +0300
+
 btpasskey (1.0-1) unstable; urgency=low
 
   * Initial release (Closes: #nnnn)  <nnnn is the bug number of your ITP>
index 6dabbedad529be9dec820f3ab3a4058f98ebba90..b662162e9c59763d62f51f99f97bfab583fd0a11 100644 (file)
@@ -1,13 +1,13 @@
 Source: btpasskey
-Section: unknown
+Section: admin
 Priority: extra
 Maintainer: Victor Wagner <vitus@wagner.pp.ru>
-Build-Depends: debhelper (>= 5), libdbus-1-dev, libbluetooth-dev
+Build-Depends: debhelper (>= 5), libdbus-1-dev
 Standards-Version: 3.7.2
 
 Package: btpasskey
 Architecture: any
-Depends: ${shlibs:Depends}, ${misc:Depends}
+Depends: ${shlibs:Depends}, ${misc:Depends}, bluez-utils
 Description: Command-line passkey agent for bluez linux stack
  btpasskey is small program which listens on D-BUS, and when passkey for
  pairing is requested, prints message on stdout and expects passkey to