install: Add 'fat-install' target
authorKeith Packard <keithp@keithp.com>
Sat, 12 Aug 2017 05:37:07 +0000 (01:37 -0400)
committerKeith Packard <keithp@keithp.com>
Sat, 12 Aug 2017 22:27:38 +0000 (18:27 -0400)
This uses the existing --with-fat-dir option and instead of installing
everything to that directory, creates a normal ikiwiki hierarchy of
files including .mdwn files, whacked release notes html files and all
of the appropriate packages.

One stop shopping for adding the release to the web site.

Attempted to update Releasing file to match.

Signed-off-by: Keith Packard <keithp@keithp.com>
Makefile.am
Releasing
altosui/Makefile.am
altosui/mdwn.tmpl [new file with mode: 0644]
configure.ac
micropeak/Makefile.am
micropeak/mdwn.tmpl [new file with mode: 0644]
telegps/Makefile.am
telegps/mdwn.tmpl [new file with mode: 0644]

index 2fdbd10..cac02c6 100644 (file)
@@ -18,6 +18,13 @@ ChangeLog:
 
 dist-hook: ChangeLog
 
+if FATINSTALL
+fat-install: fat
+       cd altosui && $(MAKE) fat-install
+       cd telegps && $(MAKE) fat-install
+       cd micropeak && $(MAKE) fat-install
+endif
+
 fat:
        cd src && $(MAKE) all
        cd doc && $(MAKE) all
index cb92b1e..5780f3c 100644 (file)
--- a/Releasing
+++ b/Releasing
@@ -7,6 +7,26 @@ Adding a product to the release
 
        Add the firmware to altosui/altos-windows.nsi.in
 
+       Add the firmware to telegps/Makefile.am
+
+       Add the firmware to telegps/telegps-windows.nsi.in
+
+       Add the firmware to Releasing
+
+These are Keith's notes on how to do a release
+
+       - update the version and date in configure.ac if Bdale hasn't already
+
+       - make sure there is a doc/release-notes-<version>.inc
+
+       - make sure doc/release-notes.inc points at that
+
+       - make sure doc/Makefile points at that too
+
+       - make sure that doc/altusmetrum-docinfo.xml has the right copyright 
+         year, and add release to the revision history at the front (release 
+         notes will be pulled in by release-notes.inc)
+
 These are Bdale's notes on how to do a release.
 
        - make sure build environment is up to date
@@ -72,10 +92,12 @@ These are Bdale's notes on how to do a release.
        make distclean
 
        ./autogen.sh --enable-multi-arch \
-               --with-fat-dir=/home/bdale/web/altusmetrum/AltOS/releases
+               --with-fat-dir=/home/bdale/web/altusmetrum/
        make && make fat
 
-               this pushes packages for each platform to web site
+               this pushes packages for each platform and application
+               to web site, including auto-generated mdwn files and
+               release notes in html format.
 
        # store a stable copy of ARM binaries for production use
        cp src/chaoskey-v1.0/{*.elf,*.ihx} \
@@ -110,22 +132,15 @@ These are Bdale's notes on how to do a release.
        - copy the relevant release notes .html file from doc/ to 
            /home/bdale/web/altusmetrum/AltOS/releases/<rev>
 
-       (cd ~/web/altusmetrum/AltOS/releases/<rev> ; rm *.tar.bz2)
-
-       - create /home/bdale/web/altusmetrum/MicroPeak/releases/<rev>,
-         and move the MicroPeak installers from AltOS/releases to there
-               
-       - create /home/bdale/web/altusmetrum/TeleGPS/releases/<rev>,
-         and move the TeleGPS installers from AltOS/releases to there
-               
-       - go edit ~/web/altusmetrum/AltOS/releases/<rev>.mdwn, 
-         /home/bdale/web/altusmetrum/MicroPeak/releases/<rev>.mdwn, and
-         /home/bdale/web/altusmetrum/TeleGPS/releases/<rev>.mdwn
-
-               - make sure the Windows stuff is like 1-4-1, not 1.4.1!
+       - Push new release to web site
 
+       make fat-install
        (cd doc ; make publish)
 
+       (cd ~/web/altusmetrum/ && git add AltOS/releases
+       TeleGPS/releases MicroPeak/releases && git commit -m'Release
+       <rev>' && git push origin master)
+
                this pushes fresh documents to the web site
 
        sudo debian/rules clean
index 31ec06b..53762ae 100644 (file)
@@ -171,6 +171,8 @@ LINUX_DIST=Altos-Linux-$(VERSION).tar.bz2
 LINUX_SH=Altos-Linux-$(VERSION).sh
 MACOSX_DIST=Altos-Mac-$(VERSION).dmg
 WINDOWS_DIST=Altos-Windows-$(VERSION_DASH).exe
+MDWN=$(VERSION).mdwn
+MDWNTMPL=mdwn.tmpl
 
 FAT_FILES=$(FATJAR) $(ALTOSLIB_CLASS) $(ALTOSUILIB_CLASS) $(FREETTS_CLASS) $(JFREECHART_CLASS) $(JCOMMON_CLASS)
 
@@ -185,14 +187,14 @@ MACOSX_EXTRA=$(FIRMWARE)
 
 WINDOWS_FILES=$(FAT_FILES) $(FIRMWARE) altos.dll altos64.dll $(top_srcdir)/altusmetrum.inf $(top_srcdir)/altusmetrum.cat $(WINDOWS_ICONS)
 
-all-local: classes/altosui $(JAR) altosui altosui-test altosui-jdb
+all-local: classes/altosui $(JAR) altosui altosui-test altosui-jdb $(MDWN)
 
 clean-local:
        -rm -rf classes $(JAR) $(FATJAR) \
                Altos-Linux-*.tar.bz2 Altos-Linux-*.sh Altos-Mac-*.dmg Altos-Windows-*.exe \
                windows altoslib_*.jar altosuilib_*.jar $(FREETTS_CLASS) \
                $(JFREECHART_CLASS) $(JCOMMON_CLASS) $(LIBALTOS) Manifest.txt Manifest-fat.txt altos-windows.log altos-windows.nsi \
-               altosui altosui-test altosui-jdb macosx linux *.desktop
+               altosui altosui-test altosui-jdb macosx linux *.desktop $(MDWN)
 
 EXTRA_DIST = $(desktop_file).in
 
@@ -202,18 +204,17 @@ $(desktop_file): $(desktop_file).in
 
 if FATINSTALL
 
-FATTARGET=$(FATDIR)/$(VERSION)
+FATTARGET=$(FATDIR)/AltOS/releases/$(VERSION)
 
-LINUX_DIST_TARGET=$(FATTARGET)/$(LINUX_DIST)
 LINUX_SH_TARGET=$(FATTARGET)/$(LINUX_SH)
 MACOSX_DIST_TARGET=$(FATTARGET)/$(MACOSX_DIST)
 WINDOWS_DIST_TARGET=$(FATTARGET)/$(WINDOWS_DIST)
+MDWN_TARGET=$(FATDIR)/AltOS/releases/$(MDWN)
+RELNOTES=release-notes-$(VERSION).html
+RELNOTES_SRC=$(top_builddir)/doc/$(RELNOTES)
+RELNOTES_TARGET=$(FATTARGET)/$(RELNOTES)
 
-fat: $(LINUX_DIST_TARGET) $(LINUX_SH_TARGET) $(MACOSX_DIST_TARGET) $(WINDOWS_DIST_TARGET)
-
-$(LINUX_DIST_TARGET): $(LINUX_DIST)
-       mkdir -p $(FATTARGET)
-       cp -p $< $@
+fat-install: fat $(LINUX_SH_TARGET) $(MACOSX_DIST_TARGET) $(WINDOWS_DIST_TARGET) $(MDWN_TARGET) $(RELNOTES_TARGET)
 
 $(LINUX_SH_TARGET): $(LINUX_SH)
        mkdir -p $(FATTARGET)
@@ -227,10 +228,21 @@ $(WINDOWS_DIST_TARGET): $(WINDOWS_DIST)
        mkdir -p $(FATTARGET)
        cp -p $< $@
 
-else
-fat: $(LINUX_DIST) $(LINUX_SH) $(MACOSX_DIST) $(WINDOWS_DIST)
+$(MDWN_TARGET): $(MDWN)
+       mkdir -p $(FATTARGET)
+       cp -p $< $@
+
+$(RELNOTES_TARGET): $(RELNOTES_SRC)
+       mkdir -p $(FATTARGET)
+       sh $(top_srcdir)/doc/install-html -d $(FATTARGET) $(RELNOTES_SRC)
+
 endif
 
+$(MDWN): $(MDWNTMPL)
+       sed -e 's/%version%/$(VERSION)/g' -e 's/%version_dash%/$(VERSION_DASH)/g' $(MDWNTMPL) > $@
+
+fat: $(LINUX_DIST) $(LINUX_SH) $(MACOSX_DIST) $(WINDOWS_DIST)
+
 altosuidir=$(datadir)/java
 
 install-altosuiJAVA: altosui.jar
diff --git a/altosui/mdwn.tmpl b/altosui/mdwn.tmpl
new file mode 100644 (file)
index 0000000..b64825a
--- /dev/null
@@ -0,0 +1,7 @@
+[[!inline pages="./%version%/release-notes-%version%.html" rss="no" raw="yes" ]]
+
+- Available Files:
+       - [Windows Installer](/AltOS/releases/%version%/Altos-Windows-%version_dash%.exe)
+       - [Mac OS X Package](/AltOS/releases/%version%/Altos-Mac-%version%.dmg)
+       - [Linux](/AltOS/releases/%version%/Altos-Linux-%version%.sh)
+       - [Source Snapshot](http://git.gag.com/?p=fw/altos;a=snapshot;h=refs/tags/%version%;sf=tgz)
index f4509b4..ec221df 100644 (file)
@@ -165,7 +165,7 @@ AM_CONDITIONAL([ANDROID_RELEASE], [test x$ANDROID_RELEASE = xyes])
 AC_SUBST(ANDROID_SDK)
 
 AC_ARG_WITH(fat-dir, AS_HELP_STRING([--with-fat-dir=PATH],
-           [Set the directory to install the 'fat' distribution files to (defaults to not installing)]),
+           [Set the directory to install the 'fat-install' distribution files to (defaults to no such target)]),
            [FATDIR=$withval], [FATDIR=none])
 
 AM_CONDITIONAL(FATINSTALL, [test "x$FATDIR" != "xnone"])
index 52b6235..6f674b1 100644 (file)
@@ -95,7 +95,7 @@ desktopdir = $(datadir)/applications
 desktop_file = altusmetrum-micropeak.desktop
 desktop_SCRIPTS = $(desktop_file)
 
-all-local: micropeak-test micropeak-jdb $(JAR)
+all-local: micropeak-test micropeak-jdb $(JAR) $(MDWN)
 
 clean-local:
        -rm -rf classes $(JAR) $(FATJAR) \
@@ -103,7 +103,7 @@ clean-local:
                altoslib_*.jar altosuilib_*.jar \
                $(JFREECHART_CLASS) $(JCOMMON_CLASS) $(LIBALTOS) Manifest.txt Manifest-fat.txt \
                micropeak micropeak-test micropeak-jdb macosx linux windows micropeak-windows.log \
-               micropeak-windows.nsi *.desktop
+               micropeak-windows.nsi *.desktop $(MDWN)
 
 EXTRA_DIST = $(desktop_file).in
 
@@ -115,6 +115,8 @@ LINUX_DIST=MicroPeak-Linux-$(VERSION).tar.bz2
 LINUX_SH=MicroPeak-Linux-$(VERSION).sh
 MACOSX_DIST=MicroPeak-Mac-$(VERSION).dmg
 WINDOWS_DIST=MicroPeak-Windows-$(VERSION_DASH).exe
+MDWN=$(VERSION).mdwn
+MDWNTMPL=mdwn.tmpl
 
 MICROPEAK_DOC=$(top_srcdir)/doc/micropeak.pdf
 
@@ -153,18 +155,17 @@ WINDOWS_FILES=$(FAT_FILES) altos.dll altos64.dll $(DOC) $(WINDOWS_ICONS) $(WINDO
 
 if FATINSTALL
 
-FATTARGET=$(FATDIR)/$(VERSION)
+FATTARGET=$(FATDIR)/MicroPeak/releases/$(VERSION)
 
-LINUX_DIST_TARGET=$(FATTARGET)/$(LINUX_DIST)
 LINUX_SH_TARGET=$(FATTARGET)/$(LINUX_SH)
 MACOSX_DIST_TARGET=$(FATTARGET)/$(MACOSX_DIST)
 WINDOWS_DIST_TARGET=$(FATTARGET)/$(WINDOWS_DIST)
+MDWN_TARGET=$(FATDIR)/MicroPeak/releases/$(MDWN)
+RELNOTES=release-notes-$(VERSION).html
+RELNOTES_SRC=$(top_builddir)/doc/$(RELNOTES)
+RELNOTES_TARGET=$(FATTARGET)/$(RELNOTES)
 
-fat: $(LINUX_DIST_TARGET) $(LINUX_SH_TARGET) $(MACOSX_DIST_TARGET) $(WINDOWS_DIST_TARGET)
-
-$(LINUX_DIST_TARGET): $(LINUX_DIST)
-       mkdir -p $(FATTARGET)
-       cp -p $< $@
+fat-install: $(LINUX_SH_TARGET) $(MACOSX_DIST_TARGET) $(WINDOWS_DIST_TARGET) $(MDWN_TARGET) $(RELNOTES_TARGET)
 
 $(LINUX_SH_TARGET): $(LINUX_SH)
        mkdir -p $(FATTARGET)
@@ -178,10 +179,22 @@ $(WINDOWS_DIST_TARGET): $(WINDOWS_DIST)
        mkdir -p $(FATTARGET)
        cp -p $< $@
 
-else
-fat: $(LINUX_DIST) $(LINUX_SH) $(MACOSX_DIST) $(WINDOWS_DIST)
+$(MDWN_TARGET): $(MDWN)
+       mkdir -p $(FATTARGET)
+       cp -p $< $@
+
+$(RELNOTES_TARGET): $(RELNOTES_SRC)
+       mkdir -p $(FATTARGET)
+       sh $(top_srcdir)/doc/install-html -d $(FATTARGET) $(RELNOTES_SRC)
+
 endif
 
+$(MDWN): $(MDWNTMPL)
+       sed -e 's/%version%/$(VERSION)/g' -e 's/%version_dash%/$(VERSION_DASH)/g' $(MDWNTMPL) > $@
+
+fat: $(LINUX_DIST) $(LINUX_SH) $(MACOSX_DIST) $(WINDOWS_DIST)
+
+
 micropeak: Makefile
        echo "#!/bin/sh" > $@
        echo 'exec java  -Djava.library.path="$(altoslibdir)" -jar "$(micropeakdir)/micropeak.jar" "$$@"' >> $@
diff --git a/micropeak/mdwn.tmpl b/micropeak/mdwn.tmpl
new file mode 100644 (file)
index 0000000..232dde5
--- /dev/null
@@ -0,0 +1,7 @@
+[[!inline pages="./%version%/release-notes-%version%.html" rss="no" raw="yes" ]]
+
+- Available Files:
+       - [Windows Installer](/MicroPeak/releases/%version%/MicroPeak-Windows-%version_dash%.exe)
+       - [Mac OS X Package](/MicroPeak/releases/%version%/MicroPeak-Mac-%version%.dmg)
+       - [Linux](/MicroPeak/releases/%version%/MicroPeak-Linux-%version%.sh)
+       - [Source Snapshot](http://git.gag.com/?p=fw/altos;a=snapshot;h=refs/tags/%version%;sf=tgz)
index bd69bd5..a1c4a0a 100644 (file)
@@ -120,7 +120,7 @@ desktopdir = $(datadir)/applications
 desktop_file = altusmetrum-telegps.desktop
 desktop_SCRIPTS = $(desktop_file)
 
-all-local: telegps-test telegps-jdb $(JAR)
+all-local: telegps-test telegps-jdb $(JAR) $(MDWN)
 
 clean-local:
        -rm -rf classes $(JAR) $(FATJAR) \
@@ -128,7 +128,7 @@ clean-local:
                altoslib_*.jar altosuilib_*.jar \
                $(JFREECHART_CLASS) $(JCOMMON_CLASS) $(FREETTS_CLASS) $(LIBALTOS) Manifest.txt Manifest-fat.txt \
                telegps telegps-test telegps-jdb macosx linux windows telegps-windows.log \
-               telegps-windows.nsi *.desktop
+               telegps-windows.nsi *.desktop $(MDWN)
 
 EXTRA_DIST = $(desktop_file).in
 
@@ -140,6 +140,8 @@ LINUX_DIST=TeleGPS-Linux-$(VERSION).tar.bz2
 LINUX_SH=TeleGPS-Linux-$(VERSION).sh
 MACOSX_DIST=TeleGPS-Mac-$(VERSION).dmg
 WINDOWS_DIST=TeleGPS-Windows-$(VERSION_DASH).exe
+MDWN=$(VERSION).mdwn
+MDWNTMPL=mdwn.tmpl
 
 TELEGPS_DOC=$(top_srcdir)/doc/telegps.pdf
 
@@ -159,18 +161,17 @@ WINDOWS_FILES=$(FAT_FILES) altos.dll altos64.dll $(top_srcdir)/altusmetrum.inf $
 
 if FATINSTALL
 
-FATTARGET=$(FATDIR)/$(VERSION)
+FATTARGET=$(FATDIR)/TeleGPS/releases/$(VERSION)
 
-LINUX_DIST_TARGET=$(FATTARGET)/$(LINUX_DIST)
 LINUX_SH_TARGET=$(FATTARGET)/$(LINUX_SH)
 MACOSX_DIST_TARGET=$(FATTARGET)/$(MACOSX_DIST)
 WINDOWS_DIST_TARGET=$(FATTARGET)/$(WINDOWS_DIST)
+MDWN_TARGET=$(FATDIR)/TeleGPS/releases/$(MDWN)
+RELNOTES=release-notes-$(VERSION).html
+RELNOTES_SRC=$(top_builddir)/doc/$(RELNOTES)
+RELNOTES_TARGET=$(FATTARGET)/$(RELNOTES)
 
-fat: $(LINUX_DIST_TARGET) $(LINUX_SH_TARGET) $(MACOSX_DIST_TARGET) $(WINDOWS_DIST_TARGET)
-
-$(LINUX_DIST_TARGET): $(LINUX_DIST)
-       mkdir -p $(FATTARGET)
-       cp -p $< $@
+fat-install: $(LINUX_SH_TARGET) $(MACOSX_DIST_TARGET) $(WINDOWS_DIST_TARGET) $(MDWN_TARGET) $(RELNOTES_TARGET)
 
 $(LINUX_SH_TARGET): $(LINUX_SH)
        mkdir -p $(FATTARGET)
@@ -184,10 +185,22 @@ $(WINDOWS_DIST_TARGET): $(WINDOWS_DIST)
        mkdir -p $(FATTARGET)
        cp -p $< $@
 
-else
-fat: $(LINUX_DIST) $(LINUX_SH) $(MACOSX_DIST) $(WINDOWS_DIST)
+$(MDWN_TARGET): $(MDWN)
+       mkdir -p $(FATTARGET)
+       cp -p $< $@
+
+$(RELNOTES_TARGET): $(RELNOTES_SRC)
+       mkdir -p $(FATTARGET)
+       sh $(top_srcdir)/doc/install-html -d $(FATTARGET) $(RELNOTES_SRC)
+
 endif
 
+$(MDWN): $(MDWNTMPL)
+       sed -e 's/%version%/$(VERSION)/g' -e 's/%version_dash%/$(VERSION_DASH)/g' $(MDWNTMPL) > $@
+
+fat: $(LINUX_DIST) $(LINUX_SH) $(MACOSX_DIST) $(WINDOWS_DIST)
+
+
 telegps: Makefile
        echo "#!/bin/sh" > $@
        echo 'exec java  -Djava.library.path="$(altoslibdir)" -jar "$(telegpsdir)/telegps.jar" "$$@"' >> $@
diff --git a/telegps/mdwn.tmpl b/telegps/mdwn.tmpl
new file mode 100644 (file)
index 0000000..05b3e40
--- /dev/null
@@ -0,0 +1,7 @@
+[[!inline pages="./%version%/release-notes-%version%.html" rss="no" raw="yes" ]]
+
+- Available Files:
+       - [Windows Installer](/TeleGPS/releases/%version%/TeleGPS-Windows-%version_dash%.exe)
+       - [Mac OS X Package](/TeleGPS/releases/%version%/TeleGPS-Mac-%version%.dmg)
+       - [Linux](/TeleGPS/releases/%version%/TeleGPS-Linux-%version%.sh)
+       - [Source Snapshot](http://git.gag.com/?p=fw/altos;a=snapshot;h=refs/tags/%version%;sf=tgz)