From 249ea3b9fc0b7f41e579c5bb5a1a2c3b6eb08629 Mon Sep 17 00:00:00 2001 From: Bill Erickson Date: Fri, 14 Nov 2014 10:45:07 -0500 Subject: [PATCH] LP#1392759 developer/packager Makefile.install targets * Adds -developer target for installing packages only needed by developers installing from source. Currently, this is limited to packages needed for managing browser client dependencies, but others could be added later. * Adds -packager target for installing packages needed to build Evergreen release bundles. * Updates README install docs to reference these new targets. * Updates README install docs to remove requirements for installing libtool/automake/autoconf, since those packages will have been installed during the OpenSRF install (which is required). * NOTE: this does not include new Makefile.install targets for fedora Signed-off-by: Bill Erickson Signed-off-by: Ben Shum --- Open-ILS/src/extras/Makefile.install | 22 +++++++++++++ Open-ILS/src/extras/install/Makefile.common | 10 ++++++ .../src/extras/install/Makefile.debian-jessie | 29 ++++++++++++++++ .../src/extras/install/Makefile.debian-wheezy | 18 ++++++++++ .../extras/install/Makefile.ubuntu-precise | 18 ++++++++++ .../src/extras/install/Makefile.ubuntu-trusty | 29 ++++++++++++++++ docs/installation/server_installation.txt | 33 ++++++++++++++----- 7 files changed, 151 insertions(+), 8 deletions(-) diff --git a/Open-ILS/src/extras/Makefile.install b/Open-ILS/src/extras/Makefile.install index bb46f6dfc8..54c5460673 100644 --- a/Open-ILS/src/extras/Makefile.install +++ b/Open-ILS/src/extras/Makefile.install @@ -46,6 +46,10 @@ export LIBDBI=libdbi-0.8.3 export LIBDBI_DRIVERS=libdbi-drivers-0.8.3 export LIBDBI_HOST=http://open-ils.org/~denials/evergreen +# some OSes require a source install of NodeJS. +# NOTE: Deprecate me with wheezy / precise +export NODEJS_SOURCE_VERSION=v0.10.28 + # As this Makefile is designed to be used by a make process running as # root, this will avoid problems on some systems when tar extracts # files and tries to give them the same UID/GID as they have in their @@ -91,4 +95,22 @@ postgres-server-ubuntu-precise: postgres-server-fedora: @make -f $(DIR)/Makefile.fedora install_postgres_server +ubuntu-trusty-developer: + @make -f $(DIR)/Makefile.ubuntu-trusty install_developer +debian-jessie-developer: + @make -f $(DIR)/Makefile.debian-jessie install_developer +ubuntu-precise-developer: + @make -f $(DIR)/Makefile.ubuntu-precise install_developer +debian-wheezy-developer: + @make -f $(DIR)/Makefile.debian-wheezy install_developer + +ubuntu-trusty-packager: + @make -f $(DIR)/Makefile.ubuntu-trusty install_packager +debian-jessie-packager: + @make -f $(DIR)/Makefile.debian-jessie install_packager +ubuntu-precise-packager: + @make -f $(DIR)/Makefile.ubuntu-precise install_packager +debian-wheezy-packager: + @make -f $(DIR)/Makefile.debian-wheezy install_packager + # vim:noet:sw=4:ts=4: diff --git a/Open-ILS/src/extras/install/Makefile.common b/Open-ILS/src/extras/install/Makefile.common index efd52d35c9..d3bdd54ddc 100644 --- a/Open-ILS/src/extras/install/Makefile.common +++ b/Open-ILS/src/extras/install/Makefile.common @@ -27,6 +27,16 @@ install_libdbi: cd $(LIBDBI_DRIVERS) && ./configure \ --disable-docs --with-pgsql --enable-libdbi && make all install +# NOTE: Deprecate me with wheezy / precise +install_nodejs_from_source: + git clone https://github.com/joyent/node.git + cd node; \ + git checkout -b $(NODEJS_SOURCE_VERSION) $(NODEJS_SOURCE_VERSION); \ + ./configure && make && make install + npm update + npm install -g grunt-cli + npm install -g bower + clean: make -C $(LIBDBI) clean make -C $(LIBDBI_DRIVERS) clean diff --git a/Open-ILS/src/extras/install/Makefile.debian-jessie b/Open-ILS/src/extras/install/Makefile.debian-jessie index 8b8fd66bb9..a5294b4643 100644 --- a/Open-ILS/src/extras/install/Makefile.debian-jessie +++ b/Open-ILS/src/extras/install/Makefile.debian-jessie @@ -94,6 +94,24 @@ PGSQL_SERVER_DEBS_93 = \ postgresql-plperl-9.3 \ postgresql-server-dev-9.3 +# nodejs-legacy creates a symlink for /usr/bin/node -> /usr/bin/nodejs +# which is needed by our npm-installed packages +DEVELOPER_DEBS = \ + nodejs-legacy \ + npm + +PACKAGER_DEBS = \ + translate-toolkit \ + python-dev \ + python-levenshtein \ + python-polib \ + python-setuptools \ + python-simplejson \ + python-lxml \ + zip \ + unzip \ + nsis + all: make -f $(DIR)/Makefile.debian install_debs make -f $(DIR)/Makefile.debian test_for_libdbi_pkg @@ -106,6 +124,17 @@ all: install_postgres_server: make -f $(DIR)/Makefile.debian DEBS="$(PGSQL_SERVER_DEBS_93)" +# note: if/when grunt-cli and bower are available as +# packages, use the packaged versions instead. +install_developer: + make -f $(DIR)/Makefile.debian DEBS="$(DEVELOPER_DEBS)" + npm update + npm install -g grunt-cli + npm install -g bower + +install_packager: + make -f $(DIR)/Makefile.debian DEBS="$(PACKAGER_DEBS)" + clean: make -f $(DIR)/Makefile.common clean make -f $(DIR)/Makefile.debian clean diff --git a/Open-ILS/src/extras/install/Makefile.debian-wheezy b/Open-ILS/src/extras/install/Makefile.debian-wheezy index 5335aca21b..ba4df36832 100644 --- a/Open-ILS/src/extras/install/Makefile.debian-wheezy +++ b/Open-ILS/src/extras/install/Makefile.debian-wheezy @@ -94,6 +94,18 @@ PGSQL_SERVER_DEBS_91 = \ postgresql-plperl-9.1 \ postgresql-server-dev-9.1 +PACKAGER_DEBS = \ + translate-toolkit \ + python-dev \ + python-levenshtein \ + python-polib \ + python-setuptools \ + python-simplejson \ + python-lxml \ + zip \ + unzip \ + nsis + all: make -f $(DIR)/Makefile.debian install_debs make -f $(DIR)/Makefile.debian test_for_libdbi_pkg @@ -106,6 +118,12 @@ all: install_postgres_server: make -f $(DIR)/Makefile.debian DEBS="$(PGSQL_SERVER_DEBS_91)" +install_developer: + make -f $(DIR)/Makefile.common install_nodejs_from_source + +install_packager: + make -f $(DIR)/Makefile.debian DEBS="$(PACKAGER_DEBS)" + clean: make -f $(DIR)/Makefile.common clean make -f $(DIR)/Makefile.debian clean diff --git a/Open-ILS/src/extras/install/Makefile.ubuntu-precise b/Open-ILS/src/extras/install/Makefile.ubuntu-precise index b87ea13ccf..258e9db827 100644 --- a/Open-ILS/src/extras/install/Makefile.ubuntu-precise +++ b/Open-ILS/src/extras/install/Makefile.ubuntu-precise @@ -98,6 +98,18 @@ PGSQL_SERVER_DEBS_91 = \ postgresql-plperl-9.1 \ postgresql-server-dev-9.1 +PACKAGER_DEBS = \ + translate-toolkit \ + python-dev \ + python-levenshtein \ + python-polib \ + python-setuptools \ + python-simplejson \ + python-lxml \ + zip \ + unzip \ + nsis + all: make -f $(DIR)/Makefile.debian install_debs make -f $(DIR)/Makefile.debian test_for_libdbi_pkg @@ -109,6 +121,12 @@ all: install_postgres_server: make -f $(DIR)/Makefile.debian DEBS="$(PGSQL_SERVER_DEBS_91)" +install_developer: + make -f $(DIR)/Makefile.common install_nodejs_from_source + +install_packager: + make -f $(DIR)/Makefile.debian DEBS="$(PACKAGER_DEBS)" + clean: make -f $(DIR)/Makefile.common clean make -f $(DIR)/Makefile.debian clean diff --git a/Open-ILS/src/extras/install/Makefile.ubuntu-trusty b/Open-ILS/src/extras/install/Makefile.ubuntu-trusty index 7dbdd0bde4..992825c8a9 100644 --- a/Open-ILS/src/extras/install/Makefile.ubuntu-trusty +++ b/Open-ILS/src/extras/install/Makefile.ubuntu-trusty @@ -102,6 +102,24 @@ PGSQL_SERVER_DEBS_93 = \ postgresql-plperl-9.3 \ postgresql-server-dev-9.3 +# nodejs-legacy creates a symlink for /usr/bin/node -> /usr/bin/nodejs +# which is needed by our npm-installed packages +DEVELOPER_DEBS = \ + nodejs-legacy \ + npm + +PACKAGER_DEBS = \ + translate-toolkit \ + python-dev \ + python-levenshtein \ + python-polib \ + python-setuptools \ + python-simplejson \ + python-lxml \ + zip \ + unzip \ + nsis + all: make -f $(DIR)/Makefile.debian install_debs make -f $(DIR)/Makefile.debian test_for_libdbi_pkg @@ -113,6 +131,17 @@ all: install_postgres_server: make -f $(DIR)/Makefile.debian DEBS="$(PGSQL_SERVER_DEBS_93)" +# note: if/when grunt-cli and bower are available as +# packages, use the packaged versions instead. +install_developer: + make -f $(DIR)/Makefile.debian DEBS="$(DEVELOPER_DEBS)" + npm update + npm install -g grunt-cli + npm install -g bower + +install_packager: + make -f $(DIR)/Makefile.debian DEBS="$(PACKAGER_DEBS)" + clean: make -f $(DIR)/Makefile.common clean make -f $(DIR)/Makefile.debian clean diff --git a/docs/installation/server_installation.txt b/docs/installation/server_installation.txt index 138b1b6d44..3c095c6f66 100644 --- a/docs/installation/server_installation.txt +++ b/docs/installation/server_installation.txt @@ -40,14 +40,8 @@ Skip this section if you are using an official release tarball downloaded from http://evergreen-ils.org/downloads Developers working directly with the source code from the Git repository, -rather than an official release tarball, must install some extra packages -and perform one step before they can proceed with the `./configure` step. - -As the *root* Linux account, install the following packages: - - * autoconf - * automake - * libtool +rather than an official release tarball, must perform one step before they +can proceed with the `./configure` step. As the *user* Linux account, issue the following command in the Evergreen source directory to generate the configure script and Makefiles: @@ -112,6 +106,29 @@ echo "/usr/lib64/dbd" > /etc/ld.so.conf.d/eg.conf ldconfig ------------------------------------------------------------------------------ +6. OPTIONAL: Developer additions ++ +To perform certain developer tasks from a Git source code checkout, +additional packages may be required. As the *root* Linux account: ++ + * To install packages needed for retriving and managing web dependencies, + use the -developer Makefile.install target. Currently, + this is only needed for building and installing the (preview) browser + staff client. ++ +[source, bash] +------------------------------------------------------------------------------ +make -f Open-ILS/src/extras/Makefile.install -developer +------------------------------------------------------------------------------ ++ + * To install packages required for building Evergreen release bundles, use + the -packager Makefile.install target. ++ +[source, bash] +------------------------------------------------------------------------------ +make -f Open-ILS/src/extras/Makefile.install -packager +------------------------------------------------------------------------------ + Configuration and compilation instructions ------------------------------------------ -- 2.43.2