X-Git-Url: http://lists.indexdata.dk/cgi-bin?a=blobdiff_plain;ds=sidebyside;f=src%2FMakefile;h=95edb1d3b2ea5de5ad7e9637585cbde56594e652;hb=4b3ff17987e6252e00de5c77bfa571aade866641;hp=bcb753d2ec1d485160726ad780d4b53f317b53d4;hpb=7722615c17cf1b36d1d2f25c6b60eadfc04653ee;p=mkws-moved-to-github.git diff --git a/src/Makefile b/src/Makefile index bcb753d..95edb1d 100644 --- a/src/Makefile +++ b/src/Makefile @@ -1,42 +1,40 @@ -###################################################################### -# Copyright (c) 2013-2014 IndexData ApS. http://indexdata.com -# - -############################## # select a jquery version -# #JQUERY_URL= http://code.jquery.com/jquery-2.0.3.min.js JQUERY_URL= http://code.jquery.com/jquery-1.10.0.min.js #JQUERY_URL= http://code.jquery.com/jquery-1.9.1.min.js -#JQUERY_URL= http://code.jquery.com/jquery-1.8.3.min.js -#JQUERY_URL= http://code.jquery.com/jquery-1.7.2.min.js JQUERY_UI_URL= http://code.jquery.com/ui/1.10.3/jquery-ui.js -#JQUERY_UI_URL= http://code.jquery.com/ui/1.8.0/jquery-ui.min.js JQUERY_JSON_URL= https://jquery-json.googlecode.com/files/jquery.json-2.4.js HANDLEBARS_URL= http://builds.handlebarsjs.com.s3.amazonaws.com/handlebars-v1.1.2.js PP2_URL= http://git.indexdata.com/?p=pazpar2.git;a=blob_plain;f=js/pz2.js;hb=HEAD VERSION = $(shell tr -d '\012' < VERSION) -MKWS_JS= mkws-complete.js +COMPONENTS = mkws-handlebars.js \ + mkws-core.js mkws-team.js mkws-widgets.js \ + mkws-widget-authname.js mkws-widget-log.js mkws-widget-record.js mkws-widget-image.js JQUERY_FILE := $(shell basename ${JQUERY_URL}) JQUERY_JSON_FILE := $(shell basename ${JQUERY_JSON_URL}) HANDLEBARS_FILE := $(shell basename ${HANDLEBARS_URL}) PP2_FILE = pz2.js -############################## -DOCS = README.html README.odt README.pdf \ - whitepaper.html whitepaper.odt whitepaper.pdf +INSTALLABLE = handlebars-v1.1.2.js \ + jquery-1.10.0.min.js jquery.json-2.4.js \ + pz2.js mkws.js mkws-jquery.js mkws-complete.js \ + mkws.min.js mkws-complete.min.js VERSION NEWS +INSTALLED = $(INSTALLABLE:%=../tools/htdocs/%) + +install: $(INSTALLED) -# Default rule when "make" is invoked without a target -**default**: ${MKWS_JS} mkws-js-min README.html whitepaper.html +uninstall: + rm -f $(INSTALLED) -all: ${MKWS_JS} mkws-js-min $(DOCS) +../tools/htdocs/%: % + rm -f $@ && cp -p $? $@ && chmod 444 $@ -docs: $(DOCS) +all: mkws.min.js mkws-complete.min.js -mkws-js ${MKWS_JS}: Makefile mkws.js ${JQUERY_FILE} ${JQUERY_JSON_FILE} ${HANDLEBARS_FILE} ${PP2_FILE} +mkws-js mkws-complete.js: Makefile mkws.js mkws-jquery.js ${JQUERY_FILE} ${JQUERY_JSON_FILE} ${HANDLEBARS_FILE} ${PP2_FILE} ( set -e; \ echo "/*! Copyright (c) 2013-2014 IndexData ApS. http://indexdata.com"; \ echo " Licence: GPL, http://www.indexdata.com/licences/gpl"; \ @@ -49,10 +47,9 @@ mkws-js ${MKWS_JS}: Makefile mkws.js ${JQUERY_FILE} ${JQUERY_JSON_FILE} ${HANDLE cat ${HANDLEBARS_FILE}; \ cat ${PP2_FILE}; \ cat mkws.js; \ - ) > ${MKWS_JS}.new - mv -f ${MKWS_JS}.new ${MKWS_JS} - -mkws-js-min: mkws.min.js mkws-complete.min.js + cat mkws-jquery.js; \ + ) > mkws-complete.js.new + mv -f mkws-complete.js.new mkws-complete.js %.min.js: %.js yui-compressor $? > $@.new @@ -61,8 +58,6 @@ mkws-js-min: mkws.min.js mkws-complete.min.js mkws-syntax-check: yui-compressor mkws.js >/dev/null -mkws-complete-syntax-check: mkws-js-min - ${JQUERY_FILE}: curl -sSf ${JQUERY_URL} -o $@.new perl -npe 's,sourceMappingURL=jquery.*map,,' $@.new > $@ @@ -91,46 +86,18 @@ release: mkws.js mkws-complete.js mkws.min.js mkws-complete.min.js echo "Made release $(VERSION)"; \ fi -# For a description of pandoc's markdown format, see: -# http://johnmacfarlane.net/pandoc/demo/example9/pandocs-markdown.html --> - -# for older pandoc (<1.9) run first: -# perl -i.bak -npe 's/"(Authors|Subjects)": "(.*?)"/"$1": "test"/' tools/htdocs/whitepaper.markdown -# -%.html: %.markdown - rm -f $@ - pandoc --standalone --toc -c mkws-doc.css $< | sed '/^