Browse Source

Started working with compojure

msmith-techempower 10 years ago
parent
commit
01c68ee53d

+ 1 - 1
frameworks/C++/wt/setup.sh

@@ -6,4 +6,4 @@ sed -i 's|INSERT_DB_HOST_HERE|'"${DBHOST}"'|g' benchmark.cpp
 
 g++-4.8 -O3 -DNDEBUG -std=c++0x -L${BOOST_LIB} -I${BOOST_INC} -L${WT_LIB} -I${WT_INC} -o benchmark.wt benchmark.cpp -lwt -lwthttp -lwtdbo -lwtdbomysql -lboost_thread
 
-./benchmark.wt -c wt_config.xml -t ${MAX_THREADS} --docroot . --http-address 0.0.0.0 --http-port 8080 --accesslog=- --no-compression &
+./benchmark.wt -c wt_config.xml -t ${MAX_THREADS} --docroot . --http-address 0.0.0.0 --http-port 8080 --accesslog=- --no-compression &

+ 1 - 1
frameworks/C++/wt/setup_postgres.sh

@@ -6,4 +6,4 @@ sed -i 's|INSERT_DB_HOST_HERE|'"${DBHOST}"'|g' benchmark.cpp
 
 g++-4.8 -O3 -DNDEBUG -DBENCHMARK_USE_POSTGRES -std=c++0x -L${BOOST_LIB} -I${BOOST_INC} -L${WT_LIB} -I${WT_INC} -o benchmark_postgres.wt benchmark.cpp -lwt -lwthttp -lwtdbo -lwtdbopostgres -lboost_thread
 
-./benchmark_postgres.wt -c wt_config.xml -t ${MAX_THREADS} --docroot . --http-address 0.0.0.0 --http-port 8080 --accesslog=- --no-compression &
+./benchmark_postgres.wt -c wt_config.xml -t ${MAX_THREADS} --docroot . --http-address 0.0.0.0 --http-port 8080 --accesslog=- --no-compression &

+ 0 - 3
frameworks/Clojure/compojure/install.sh

@@ -1,3 +0,0 @@
-#!/bin/bash
-
-fw_depends java7 resin leiningen

+ 4 - 10
frameworks/Clojure/compojure/setup.sh

@@ -1,18 +1,12 @@
 #!/bin/bash
 
-source $IROOT/java7.installed
-
-export RESIN_HOME=${IROOT}/resin-4.0.41
-export LEIN_HOME=$IROOT/lein
-
-# Path vars must be set here
-export PATH="$JAVA_HOME/bin:$PATH"
+fw_depends java7 resin leiningen
 
 sed -i 's|:subname "//.*:3306|:subname "//'"${DBHOST}"':3306|g' hello/src/hello/handler.clj
 
 cd hello
-$LEIN_HOME/bin/lein clean
-$LEIN_HOME/bin/lein ring uberwar
+lein clean
+lein ring uberwar
 rm -rf $RESIN_HOME/webapps/*
 cp target/hello-compojure-standalone.war $RESIN_HOME/webapps/compojure.war
-$RESIN_HOME/bin/resinctl start
+resinctl start

+ 8 - 2
toolset/setup/linux/systools/leiningen.sh

@@ -1,11 +1,17 @@
 #!/bin/bash
 
 RETCODE=$(fw_exists ${IROOT}/lein.installed)
-[ ! "$RETCODE" == 0 ] || { return 0; }
+[ ! "$RETCODE" == 0 ] || { \
+  source $IROOT/lein.installed
+  return 0; }
 
 mkdir -p lein/bin
 fw_get https://raw.github.com/technomancy/leiningen/stable/bin/lein -O leinbin
 mv leinbin lein/bin/lein
 chmod +x lein/bin/lein
 
-touch ${IROOT}/lein.installed
+LEIN_HOME=$IROOT/lein
+echo "export LEIN_HOME=${LEIN_HOME}" > $IROOT/lein.installed
+echo "export PATH=${LEIN_HOME}/bin:${PATH}" >> $IROOT/lein.installed
+
+source $IROOT/lein.installed

+ 1 - 1
toolset/setup/linux/webservers/apache.sh

@@ -3,4 +3,4 @@
 sudo apt-get install -y apache2
 
 # Stop Apache; it starts after it is installed
-sudo /etc/init.d/apache2 stop
+sudo /etc/init.d/apache2 stop