DIR = $(dir $(lastword $(MAKEFILE_LIST)))
+# 64-bit?
+JESSIE_64=$(shell uname -r | grep "amd64")
+
export DEB_PGSQL_COMMON_MODS = \
gcc \
libbusiness-isbn-perl \
libdatetime-set-perl\
libdatetime-timezone-perl\
libdbd-pg-perl\
- libemail-send-perl\
libemail-simple-perl\
libgd-graph3d-perl\
liblocale-maketext-lexicon-perl\
libuniversal-require-perl\
libunix-syslog-perl\
libyaz-dev\
- postgresql-client-9.3\
+ postgresql-client-9.4\
libsoap-lite-perl\
libbz2-dev\
libparse-recdescent-perl\
export CPAN_MODULES = \
Business::OnlinePayment::PayPal \
Template::Plugin::POSIX \
+ Email::Send \
Safe
export CPAN_MODULES_FORCE = \
Business::Stripe \
Class::DBI::Frozen::301
-PGSQL_SERVER_DEBS_93 = \
+PGSQL_SERVER_DEBS_94 = \
$(DEB_PGSQL_COMMON_MODS) \
- postgresql-9.3 \
- postgresql-contrib-9.3 \
- postgresql-plperl-9.3 \
- postgresql-server-dev-9.3
+ postgresql-9.4 \
+ postgresql-contrib-9.4 \
+ postgresql-plperl-9.4 \
+ postgresql-server-dev-9.4
+
+# Install libdbi and the postgres drivers
+# TODO: verify non-64 lib dir "x86-linux-gnu" is correct below
+install_libdbi_jessie:
+ if [ ! -d $(LIBDBI) ]; then wget $(LIBDBI_HOST)/$(LIBDBI).tar.gz; fi;
+ if [ ! -d $(LIBDBI_DRIVERS) ]; then wget $(LIBDBI_HOST)/$(LIBDBI_DRIVERS).tar.gz; fi;
+ tar -zxf $(LIBDBI).tar.gz
+ tar -zxf $(LIBDBI_DRIVERS).tar.gz
+ cd $(LIBDBI) && ./configure --disable-docs && make all install
+ if [ ! -z $(JESSIE_64) ]; then \
+ cd $(LIBDBI_DRIVERS) && ./configure \
+ --disable-docs --with-pgsql --enable-libdbi \
+ --with-pgsql-libdir=/usr/lib/x86_64-linux-gnu/ \
+ --with-pgsql-incdir=/usr/include/postgresql/ && make all install; \
+ else \
+ cd $(LIBDBI_DRIVERS) && ./configure \
+ --disable-docs --with-pgsql --enable-libdbi \
+ --with-pgsql-libdir=/usr/lib/x86-linux-gnu/ \
+ --with-pgsql-incdir=/usr/include/postgresql/&& make all install; \
+ fi;
all:
make -f $(DIR)/Makefile.debian install_debs
make -f $(DIR)/Makefile.debian test_for_libdbi_pkg
make -f $(DIR)/Makefile.common install_cpan
make -f $(DIR)/Makefile.common install_cpan_force
- make -f $(DIR)/Makefile.common install_libdbi
+ make -f $(DIR)/Makefile.common install_libdbi_jessie
make -f $(DIR)/Makefile.debian install_js_sm
make -f $(DIR)/Makefile.debian debian_sys_config
install_postgres_server:
- make -f $(DIR)/Makefile.debian DEBS="$(PGSQL_SERVER_DEBS_93)"
+ make -f $(DIR)/Makefile.debian DEBS="$(PGSQL_SERVER_DEBS_94)"
clean:
make -f $(DIR)/Makefile.common clean