[open-ils-commits] r19809 - trunk/Open-ILS/src/extras (dbs)

svn at svn.open-ils.org svn at svn.open-ils.org
Fri Mar 18 13:50:23 EDT 2011


Author: dbs
Date: 2011-03-18 13:50:19 -0400 (Fri, 18 Mar 2011)
New Revision: 19809

Modified:
   trunk/Open-ILS/src/extras/Makefile.install
Log:
Test for an installed libdbi0 package and bail on Ubuntu and Debian

This isn't a problem on Fedora, where we use the packaged version of libdbi,
but the older version of libdbi0 and possibly the compile options on Ubuntu
Lucid has been demonstrated to be a barrier to successfully installing
Evergreen.


Modified: trunk/Open-ILS/src/extras/Makefile.install
===================================================================
--- trunk/Open-ILS/src/extras/Makefile.install	2011-03-18 16:52:00 UTC (rev 19808)
+++ trunk/Open-ILS/src/extras/Makefile.install	2011-03-18 17:50:19 UTC (rev 19809)
@@ -277,13 +277,13 @@
 debian-squeeze: squeeze generic_debian
 lenny: install_pgsql_client_debs_83 install_extra_debs
 squeeze: install_pgsql_client_debs_84  install_extra_debs_squeeze
-generic_debian:  install_debs install debian_sys_config install_cpan_force
+generic_debian:  install_debs test_for_libdbi_pkg install debian_sys_config install_cpan_force
 
 ubuntu-hardy: hardy generic_ubuntu
 ubuntu-lucid: lucid generic_ubuntu
 hardy: install_pgsql_client_debs_82 install_yaz install_cpan_marc install_extra_encode
 lucid: install_pgsql_client_debs_84 install_extra_debs
-generic_ubuntu: install_debs install debian_sys_config install_cpan_more install_cpan_safe install_cpan_force
+generic_ubuntu: install_debs test_for_libdbi_pkg install debian_sys_config install_cpan_more install_cpan_safe install_cpan_force
 
 # - COMMON TARGETS ---------------------------------------------------------
 
@@ -344,6 +344,20 @@
 	fi;
 	cd $(LIBJS_PERL) && perl Makefile.PL -E4X -JS_THREADSAFE && make && make test && make install
 
+# On Ubuntu and possibly Debian, the libdbi0 package prevents the 
+# compiled-from-source version from being used and breaks the install.
+# This package might get installed depending on the install-time choices
+# for the distro. Test for its existence; if it's there, throw an error
+# message and exit.
+test_for_libdbi_pkg:
+		@if [ "$$(apt-cache policy libdbi0 | grep Installed | grep none | wc -l)" -eq 0 ]; then \
+				echo "*** Detected locally installed libdbi0 package; you must remove this"; \
+				echo "*** with a command like 'aptitude remove libdbi0' before proceeding"; \
+				echo "*** to successfully install Evergreen."; \
+				echo; \
+				echo "*** Note: this may break other applications on your system."; \
+				exit 0; \
+		fi;
 
 # Install libdbi and the postgres drivers
 install_libdbi:



More information about the open-ils-commits mailing list