]> Dogcows Code - chaz/yoink/commitdiff
archiving support for releases
authorCharles McGarvey <chazmcgarvey@brokenzipper.com>
Sun, 13 Jun 2010 00:55:04 +0000 (18:55 -0600)
committerCharles McGarvey <chazmcgarvey@brokenzipper.com>
Sun, 13 Jun 2010 00:55:04 +0000 (18:55 -0600)
Makefile
configure
data/Makefile.am [deleted file]

index 9eba2a037ea5613c622b7563800645252c8baa96..caf10e3daf15bdb421f14dba85d0536f7948c48e 100644 (file)
--- a/Makefile
+++ b/Makefile
@@ -4,7 +4,7 @@
 # Use this file with make to compile and install Yoink.
 #
 # This makefile supports these targets:
-#   all, install, clean, cleandist, run, debug
+#   all, install, clean, distclean, run, debug, dist, dist-gzip, dist-bzip2
 #
 # This build system incorporates the ideas written by Emile van Bergen:
 # http://www.xs4all.nl/~evbergen/nonrecursive-make.html
@@ -24,8 +24,7 @@ have_config := $(wildcard config.mk)
 ifneq ($(strip $(have_config)),)
 include config.mk
 else
-no_config:
-       $(error You must run the configure script before you can make anything)
+$(error You must run the configure script before you can make anything)
 endif
 
 
@@ -188,6 +187,17 @@ uninstall:
                $(call remove_silencer,$(call DO_RM,$(DESTDIR)$(datadir)$$base)); \
        done
 
+.PHONY: dist-bzip2
+dist-bzip2:
+       $(SHELL_LINE_PREFIX)git archive HEAD --prefix='$(TARNAME)/' | bzip2 > "$(TARNAME).tar.bz2"
+
+.PHONY: dist-gzip
+dist-gzip:
+       $(SHELL_LINE_PREFIX)git archive HEAD --prefix='$(TARNAME)/' | gzip > "$(TARNAME).tar.gz"
+
+.PHONY: dist
+dist: dist-bzip2
+
 
 #
 # Prevent make from removing any build targets.
index 5ba38b90f5651064230d9d16d32a6cb9ddc68991..8c88e5bbb72917cce7472d6dcb48151e57e1dc2d 100755 (executable)
--- a/configure
+++ b/configure
@@ -6,7 +6,6 @@
 --
 
 project                = "Yoink"
-package                = project:lower()
 version                = "0.1"
 bugreport      = "chaz@dogcows.com"
 
@@ -187,6 +186,9 @@ do
 
        -- Define the dependent values.
        
+       package = project:lower()
+       tarname = package.."-"..version
+
        if not host then host = ReadCommand("tools/config.guess") end
        alt_host = ReadCommand("tools/config.sub "..host)
 
@@ -456,7 +458,7 @@ end
 
 do
        -- Determine and define the git revision.
-       local head = ReadCommand("git log -n1 --date=short --pretty=format:\"%h (%ad)\"")
+       local head = ReadCommand("git describe master")
        config.YOINK_GITHEAD = head
 end
 
@@ -467,6 +469,8 @@ config.PACKAGE_VERSION              = version
 config.PACKAGE_STRING          = project.." "..version
 config.PACKAGE_BUGREPORT       = bugreport
 
+define.PACKAGE                         = project
+define.TARNAME                         = tarname
 define.TARGET                          = host
 define.PLATFORM                                = platform
 define.CC                                      = CC
diff --git a/data/Makefile.am b/data/Makefile.am
deleted file mode 100644 (file)
index 80718f7..0000000
+++ /dev/null
@@ -1,9 +0,0 @@
-
-nobase_dist_pkgdata_DATA = @DATA_FILES@
-
-appsdir=$(datadir)/applications
-dist_apps_DATA = yoink.desktop
-
-pixmapdir=$(datadir)/pixmaps
-dist_pixmap_DATA = yoink.png
-
This page took 0.031321 seconds and 4 git commands to generate.