summarylogtreecommitdiffstats
path: root/Makefile
diff options
context:
space:
mode:
authorKyle Manna2015-07-10 08:12:13 -0700
committerKyle Manna2015-07-10 08:26:37 -0700
commit32dd1127b5c281c7826c42244dd0a7949121fdf6 (patch)
tree19addd823e4305d196d0bcb288cae8b7c5d44f6a /Makefile
downloadaur-32dd1127b5c281c7826c42244dd0a7949121fdf6.tar.gz
aur: Prepare for AUR package
* This copied from the upstream repository and unfortunately history is lost as every commit needs to include a .SRCINFO file. * Add .SRCINFO to Makefile * Update .gitignore to ignore src tarballs
Diffstat (limited to 'Makefile')
-rw-r--r--Makefile30
1 files changed, 30 insertions, 0 deletions
diff --git a/Makefile b/Makefile
new file mode 100644
index 000000000000..30089ce1572f
--- /dev/null
+++ b/Makefile
@@ -0,0 +1,30 @@
+PKGNAME = $(shell grep ^pkgname PKGBUILD | sed -e 's:.*=::')
+PKGVER = $(shell grep ^pkgver PKGBUILD | sed -e 's:.*=::')
+PKGREL = $(shell grep ^pkgrel PKGBUILD | sed -e 's:.*=::')
+PKGARCH = $(shell grep ^arch PKGBUILD | sed -e 's:.*=::')
+
+PKG = $(PKGNAME)-$(PKGVER)-$(PKGREL)-$(PKGARCH).pkg.tar.xz
+PKG_SRC = $(PKGNAME)-$(PKGVER)-$(PKGREL).src.tar.gz
+
+DEPS = digitalocean-synchronize \
+ digitalocean-synchronize.service \
+ digitalocean-synchronize.install \
+ PKGBUILD \
+ Makefile
+
+install.pkg.sh: $(PKG)
+ @cat $(subst .pkg,,$@) > $@
+ @echo -e '\ncat <<EMBEDDED\n\n!!!!digitalocean-synchronize.pkg.tar.xz' >> $@
+ @base64 $< >> $@
+ @echo -e '!!!!\n\nEMBEDDED' >> $@
+
+ $(info Build complete!)
+ $(info Output file: $@)
+
+$(PKG): $(DEPS)
+ updpkgsums
+ mksrcinfo
+ makepkg -fc
+
+clean:
+ rm -f $(PKG) install.pkg.sh