seperating the CGI install from the DB bootstrapping
authormiker <miker@dcc99617-32d9-48b4-a31d-7c20da2025e4>
Wed, 7 Sep 2005 16:03:08 +0000 (16:03 +0000)
committermiker <miker@dcc99617-32d9-48b4-a31d-7c20da2025e4>
Wed, 7 Sep 2005 16:03:08 +0000 (16:03 +0000)
git-svn-id: svn://svn.open-ils.org/ILS/trunk@1811 dcc99617-32d9-48b4-a31d-7c20da2025e4

Open-ILS/src/Makefile
Open-ILS/src/cgi-bin/circ-rules.cgi
Open-ILS/src/cgi-bin/copy_statuses.cgi
Open-ILS/src/cgi-bin/lib-setup.cgi
Open-ILS/src/cgi-bin/org_unit_types.cgi
Open-ILS/src/cgi-bin/perms-setup.cgi
Open-ILS/src/cgi-bin/usr_group-setup.cgi
install.sh

index 700a747..0564e29 100644 (file)
@@ -7,7 +7,7 @@ export CFLAGS                   = -g -Wall -O2 -fPIC -I$(LIBXML2_HEADERS) -I$(APACHE2_HEADERS) \
 all: mod_xmltools mod_ils_rest_gateway
 
 
-install:       perl-install web-install string-templates-install storage-bootstrap xsl-install
+install:       perl-install web-install string-templates-install storage-bootstrap cgi-bootstrap xsl-install
 
 web-install:   webcore-install autojs-install  mod_xmltools-install mod_ils_rest_gateway-install
 
@@ -65,10 +65,16 @@ perl-install:
 
 # -----------------------------------------------------------------------------------
 
-storage-bootstrap:
+cgi-bootstrap:
        @echo "Installing cgi's to $(CGIDIR)"
+       mkdir -p $(TMP)/cgi-bin
        mkdir -p $(CGIDIR)
-       cp -r cgi-bin/* $(CGIDIR)
+       for i in cgi-bin/*cgi; do perl -pe "s{##CONFIG##}{$(ETCDIR)}" < $i > $(TMP)/$i; done
+       cp $(TMP)/cgi-bin/*cgi $(CGIDIR)
+       cp -r cgi-bin/support $(CGIDIR)
+       cp cgi-bin/setup.pl $(ETCDIR)
+
+storage-bootstrap:
        ./extras/import/build-oils-db.sh $(DBDRVR) $(DBHOST) $(DBNAME) $(DBUSER) $(DBPW)
 
 # -----------------------------------------------------------------------------------
index 0528279..7372b9f 100755 (executable)
@@ -10,7 +10,7 @@ use OpenILS::Application::Storage::Driver::Pg;
 use CGI qw/:standard start_*/;
 
 our %config;
-do 'setup.pl';
+do '##CONFIG##/setup.pl';
 
 OpenILS::Application::Storage::CDBI->connection($config{dsn},$config{usr},$config{pw});
 OpenILS::Application::Storage::CDBI->db_Main->{ AutoCommit } = 1;
index 7d6cac9..5707744 100755 (executable)
@@ -9,7 +9,7 @@ use OpenILS::Application::Storage::Driver::Pg;
 
 use CGI qw/:standard start_*/;
 our %config;
-do 'setup.pl';
+do '##CONFIG##/setup.pl';
 
 OpenILS::Application::Storage::CDBI->connection($config{dsn},$config{usr},$config{pw});
 OpenILS::Application::Storage::CDBI->db_Main->{ AutoCommit } = 1;
index 7c283bc..6b90c76 100755 (executable)
@@ -9,7 +9,7 @@ use OpenILS::Application::Storage::Driver::Pg;
 
 use CGI qw/:standard start_*/;
 our %config;
-do 'setup.pl';
+do '##CONFIG##/setup.pl';
 
 OpenILS::Application::Storage::CDBI->connection($config{dsn},$config{usr},$config{pw});
 OpenILS::Application::Storage::CDBI->db_Main->{ AutoCommit } = 1;
index 03f1105..c9ceef4 100755 (executable)
@@ -10,7 +10,7 @@ use OpenILS::Application::Storage::Driver::Pg;
 use CGI qw/:standard start_*/;
 
 our %config;
-do 'setup.pl';
+do '##CONFIG##/setup.pl';
 
 OpenILS::Application::Storage::CDBI->connection($config{dsn},$config{usr},$config{pw});
 OpenILS::Application::Storage::CDBI->db_Main->{ AutoCommit } = 1;
index 209f237..cf624c6 100755 (executable)
@@ -10,7 +10,7 @@ use OpenILS::Application::Storage::Driver::Pg;
 use CGI qw/:standard start_*/;
 
 our %config;
-do 'setup.pl';
+do '##CONFIG##/setup.pl';
 
 OpenILS::Application::Storage::CDBI->connection($config{dsn},$config{usr},$config{pw});
 OpenILS::Application::Storage::CDBI->db_Main->{ AutoCommit } = 1;
index 799dc62..f21f6d3 100755 (executable)
@@ -10,7 +10,7 @@ use OpenILS::Application::Storage::Driver::Pg;
 use CGI qw/:standard start_*/;
 
 our %config;
-do 'setup.pl';
+do '##CONFIG##/setup.pl';
 
 OpenILS::Application::Storage::CDBI->connection($config{dsn},$config{usr},$config{pw});
 OpenILS::Application::Storage::CDBI->db_Main->{ AutoCommit } = 1;
index 4cbe98f..e6d0d28 100755 (executable)
@@ -184,6 +184,7 @@ function runInstall {
                                if building; then $MAKE -C "$OPENILSDIR" "mod_xmltools"; fi;
                                if building; then $MAKE -C "$OPENILSDIR" "mod_ils_rest_gateway"; fi;
                                if installing; then $MAKE -C "$OPENILSDIR" "web-install"; fi;
+                               if installing; then $MAKE -C "$OPENILSDIR" "cgi-bootstrap"; fi;
                                ;;
 
                        "openils_marcdumper" )