+start-httpd:
+ $(PERL) sbin/standalone_httpd &
+
+start-server:
+ $(PERL) sbin/rt-server &
+
+
+SNAPSHOT=$(shell git describe --tags)
+THIRD_PARTY=devel/third-party/
+snapshot: build-snapshot build-third-party clearsign-snapshot clearsign-third-party snapshot-shasums
+
+build-snapshot:
+ git archive --prefix "$(SNAPSHOT)/" HEAD | tar -xf -
+ ( cd $(SNAPSHOT) && \
+ echo "$(SNAPSHOT)" > .tag && \
+ autoconf && \
+ INSTALL=./install-sh PERL=/usr/bin/perl ./configure \
+ --with-db-type=SQLite \
+ --enable-layout=relative \
+ --with-web-handler=standalone && \
+ rm -rf autom4te.cache \
+ config.status config.log config.pld \
+ )
+ tar -czf "$(SNAPSHOT).tar.gz" "$(SNAPSHOT)/"
+ rm -fr "$(SNAPSHOT)/"
+
+clearsign-snapshot:
+ gpg --armor --detach-sign "$(SNAPSHOT).tar.gz"
+
+build-third-party:
+ git archive --prefix "$(SNAPSHOT)/$(THIRD_PARTY)" HEAD:$(THIRD_PARTY) \
+ | gzip > "$(SNAPSHOT)-third-party-source.tar.gz"
+ rm -rf "$(SNAPSHOT)/$(THIRD_PARTY)"
+
+clearsign-third-party:
+ gpg --armor --detach-sign "$(SNAPSHOT)-third-party-source.tar.gz"
+
+snapshot-shasums:
+ sha1sum $(SNAPSHOT)*.tar.gz*
+
+vessel-import: build-snapshot
+ [ -d $(VESSEL) ] || (echo "VESSEL isn't a path to your shipwright vessel" && exit -1)
+ cp $(VESSEL)/scripts/RT/build.pl /tmp/build.pl
+ ./sbin/rt-test-dependencies --with-standalone --with-fastcgi --with-sqlite --list > /tmp/rt.yml
+ shipwright import file:$(SNAPSHOT).tar.gz \
+ --require-yml /tmp/rt.yml \
+ --build-script /tmp/build.pl \
+ --name RT \
+ --repository fs:$(VESSEL) \
+ --log-level=info \
+ --skip cpan-capitalization,cpan-mod_perl,cpan-Encode,cpan-PPI,cpan-Test-Exception-LessClever,cpan-Test-Manifest,cpan-Test-Object,cpan-Test-Pod,cpan-Test-Requires,cpan-Test-SubCalls,cpan-Test-cpan-Tester,cpan-Test-Warn --skip-all-recommends
+ mv $(VESSEL)/scripts/RT/build $(VESSEL)/scripts/RT/build.pl
+
+JSMIN_URL = http://download.bestpractical.com/mirror/jsmin-2013-03-29.c
+JSMIN_SHA = 67dc8d73a8878f88cdaeb1a86775872eae5c3077
+
+jsmin: jsmin-checkcc jsmin-fetch jsmin-verify jsmin-confirm jsmin-build jsmin-install
+ @echo ""
+ @echo "To configure RT to use jsmin, add the following line to $(DESTDIR)$(RT_ETC_PATH)/RT_SiteConfig.pm:"
+ @echo ""
+ @echo " Set(\$$JSMinPath, '$(DESTDIR)$(RT_BIN_PATH)/jsmin');"
+ @echo ""