The Java Script librar pz2.js is now available as a separate package.
This was done becuase pz2.js is a architecture independent package and
because it may exist without pazpar2 itself which may run on a different
host.
--- /dev/null
+Alias /pazpar2 /usr/share/pazpar2
+
+
ProxyPass /pazpar2/search.pz2 http://localhost:8004/search.pz2
-Alias /pazpar2 /usr/share/pazpar2/
-
-
service which, by default, makes Pazpar2 operate as HTTP server on port
8004.
+Package: pazpar2-js
+Architecture: all
+Depends: apache2.2-common
+Description: Java Script utilities
+ Pazpar2 is a high-performance, user interface-independent, data
+ model-independent metasearching middleware featuring merging, relevance
+ ranking, record sorting, and faceted results.
+ .
+ This package includes the Java Script library pz2.js. It also adds an
+ Alias for Apache2 so that this library and other demo portals are
+ available.
+
Package: pazpar2-doc
Section: doc
Architecture: all
Package: pazpar2-test1
Architecture: all
-Depends: pazpar2, pazpar2-apache2
+Depends: pazpar2-apache2, pazpar2-js
Description: Pazpar2 portal test1
Pazpar2 is a high-performance, user interface-independent, data
model-independent metasearching middleware featuring merging, relevance
Package: pazpar2-jsdemo
Architecture: all
-Depends: pazpar2, pazpar2-apache2
+Depends: pazpar2-apache2, pazpar2-js
Description: Pazpar2 demo using the pz2.js library
Pazpar2 is a high-performance, user interface-independent, data
model-independent metasearching middleware featuring merging, relevance
--- /dev/null
+usr/share/pazpar2/js
+etc/pazpar2
--- /dev/null
+#!/bin/sh
+set -e
+
+if [ "$1" != "configure" ]; then
+ exit 0
+fi
+
+reload_apache()
+{
+ if apache2ctl configtest 2>/dev/null; then
+ invoke-rc.d apache2 force-reload || true
+ else
+ echo "Your apache2 configuration is broken, so we're not restarting it for you."
+ fi
+}
+
+if [ -e /etc/apache2/apache2.conf ]; then
+ if [ -d /etc/apache2/conf.d ]; then
+ ln -sf /etc/pazpar2/ap2pazpar2-js.cfg /etc/apache2/conf.d/pazpar2-js
+ fi
+
+ reload_apache
+fi
+exit 0
--- /dev/null
+#!/bin/sh -e
+
+case "$1" in
+ purge|remove)
+ WEBSERVERS="apache2"
+ for apache in $WEBSERVERS; do
+ if [ -f "/etc/$apache/conf.d/pazpar2-js" ]; then
+ echo "Removing pazpar2-js configuration file for $apache.."
+ rm -f /etc/$apache/conf.d/pazpar2-js
+ if [ -f "/var/run/$apache.pid" ]; then
+ invoke-rc.d $apache reload
+ fi
+ fi
+ done
+ ;;
+ upgrade|failed-upgrade|abort-install|abort-upgrade|disappear)
+ ;;
+
+ *)
+ echo "postrm called with unknown argument \`$1'" >&2
+ exit 1
+esac
+
+
+
+# dh_installdeb will replace this with shell code automatically
+# generated by other debhelper scripts.
+
+#DEBHELPER#
+
+exit 0
+
cp www/jsdemo/*.html $(CURDIR)/debian/pazpar2-jsdemo/usr/share/pazpar2/jsdemo/
cp www/jsdemo/*.js $(CURDIR)/debian/pazpar2-jsdemo/usr/share/pazpar2/jsdemo/
cp www/jsdemo/*.gif $(CURDIR)/debian/pazpar2-jsdemo/usr/share/pazpar2/jsdemo/
+ cp www/jsdemo/*.css $(CURDIR)/debian/pazpar2-jsdemo/usr/share/pazpar2/jsdemo/
+ # pazpar2-js package
+ cp $(CURDIR)/debian/ap2pazpar2-js.cfg $(CURDIR)/debian/pazpar2-js/etc/pazpar2
+ mv $(CURDIR)/debian/pazpar2/usr/share/pazpar2/js/pz2.js $(CURDIR)/debian/pazpar2-js/usr/share/pazpar2/js/
+
+ # rest
+
dh_installchangelogs NEWS
dh_installdocs
dh_installexamples