-
Notifications
You must be signed in to change notification settings - Fork 9
Quick and dirty install of GeoMoose from source on FreeBSD 10.1
Jim Klassen edited this page Feb 23, 2016
·
1 revision
Edit to suit your local environment. YMMV.
# GeoMoose Runtime Deps
pkg install \
apache24 mod_php56
mapserver proj gdal \
php56-mbstring php56-gd php56-curl php56-sqlite3 php56-dom
# php5-mapscript may need to build this from ports, also no wms,wfs server
# GeoMoose Build Deps
pkg install \
git \
openjdk8-jre \
bash
# Install Build Deps for docs (big)
pkg install \
py27-sphinx texlive-full \
naturaldocs
echo "apache24_enable=YES" >> /etc/rc.conf cat > /usr/local/apache24/modules.d/080_mod_php.conf <<EOF <FilesMatch ".php$"> SetHandler application/x-httpd-php <FilesMatch ".phps$"> SetHandler application/x-httpd-php-source EOF apachectl restart
cat >> /etc/fstab <<EOF fdesc /dev/fd fdescfs rw 0 0 EOF
bash
git clone --recursive https://github.com/geomoose/geomoose.git /usr/local/www/geomoose
cd /usr/local/www/geomoose/js
ln -s ../services/php .
ln -s geomoose.html index.html
# Needed for GeoMoose build (make sure this isn't overwriting something important!)
ln -s /usr/local/bin/bash /bin/bash
# Needed for OpenLayers build
ln -s /usr/local/bin/python2.7 /usr/local/bin/python
cd /usr/local/www/geomoose/js/libs
./build_js.sh
# Cleanup (Make sure this isn't removing something important!)
rm -i /bin/bash
rm -i /usr/local/bin/python
cat > /usr/local/www/geomoose/conf/local_settings.ini <<EOF
[paths]
root=/usr/local/www/geomoose/maps/
mapserver_url=/cgi-bin/mapserv
temp=/tmp/
EOF
cat > /usr/local/www/geomoose/maps/temp_directory.map <<EOF
# This file is used to configure temporary directories for Mapserver Mapfile
IMAGEPATH "/tmp/"
EOF
cd /usr/local/www/geomoose/docs
make html
cd /usr/local/www/geomoose/js
mkdir -p ../docs/build/html/apidocs
NaturalDocs -i geomoose -o html ../docs/build/html/apidocs -p ntdocs
ln -s /usr/local/www/geomoose/js /usr/local/www/apache24/data/geomoose
ln -s /usr/local/www/geomoose/docs/build/html /usr/local/www/apache24/data/geomoose-docs
cp /usr/local/bin/mapserv /usr/local/www/apache24/cgi-bin/mapserv
apachectl restart
alias module cgid module
<IfModule !mpm_prefork_module> #LoadModule cgid_module libexec/apache24/mod_cgid.so #LoadModule cgi_module libexec/apache24/mod_cgi.so