cwd=$PWD
( cd tmp &&
- tar jxf ../deps/tarpit/sbcl-1.2.11-x86-64-darwin-binary.tar.bz2 &&
- tar jxf ../deps/tarpit/sbcl-1.2.13-source.tar.bz2 &&
+ tar jxf ../deps/osx/sbcl-1.2.11-x86-64-darwin-binary.tar.bz2 &&
+ tar jxf ../deps/osx/sbcl-1.2.13-source.tar.bz2 &&
cd sbcl-1.2.11-x86-64-darwin/ &&
SBCL_HOME="" INSTALL_ROOT=$cwd/tmp/sbcl-binary/ bash install.sh &&
cd ../sbcl-1.2.13/ &&
mkdir -p tmp/deps/
( cd tmp/deps &&
- tar zxf ../../deps/tarpit/3b-cl-opengl-993d627.tar.gz &&
- tar zxf ../../deps/tarpit/alexandria-b1c6ee0.tar.gz &&
- tar zxf ../../deps/tarpit/babel_0.5.0.tar.gz &&
- tar zxf ../../deps/tarpit/cffi_0.15.0.tar.gz &&
- tar zxf ../../deps/tarpit/cl-ppcre.tar.gz &&
- tar zxf ../../deps/tarpit/ironclad.tar.gz &&
- tar zxf ../../deps/tarpit/mt19937-latest.tar.gz &&
- tar zxf ../../deps/tarpit/nibbles-v0.12.tar.gz &&
- tar zxf ../../deps/tarpit/trivial-features_0.8.tar.gz &&
- tar zxf ../../deps/tarpit/cl-charms-9bb94ef.tar.gz # &&
- ln -s 3b-cl-opengl-993d627/cl-glut.asd . &&
- ln -s 3b-cl-opengl-993d627/cl-opengl.asd . &&
- ln -s alexandria-b1c6ee0/alexandria.asd . &&
- ln -s babel_0.5.0/babel-streams.asd . &&
- ln -s babel_0.5.0/babel.asd . &&
- ln -s cffi_0.15.0/cffi-examples.asd . &&
- ln -s cffi_0.15.0/cffi-grovel.asd . &&
- ln -s cffi_0.15.0/cffi-libffi.asd . &&
- ln -s cffi_0.15.0/cffi-uffi-compat.asd . &&
- ln -s cffi_0.15.0/cffi.asd . &&
- ln -s cl-charms/cl-charms.asd . &&
- ln -s cl-ppcre-2.0.10/cl-ppcre.asd . &&
- ln -s mt19937-1.1.1/mt19937.asd . &&
- ln -s nibbles-0.12/nibbles.asd . &&
- ln -s trivial-features_0.8/trivial-features.asd . &&
- ln -s ../../src/main/clnl.asd .
+ tar zxf ../../deps/common-lisp/3b-cl-opengl-993d627.tar.gz &&
+ tar zxf ../../deps/common-lisp/alexandria-b1c6ee0.tar.gz &&
+ tar zxf ../../deps/common-lisp/babel_0.5.0.tar.gz &&
+ tar zxf ../../deps/common-lisp/cffi_0.15.0.tar.gz &&
+ tar zxf ../../deps/common-lisp/cl-ppcre.tar.gz &&
+ tar zxf ../../deps/common-lisp/ironclad.tar.gz &&
+ tar zxf ../../deps/common-lisp/mt19937-latest.tar.gz &&
+ tar zxf ../../deps/common-lisp/nibbles-v0.12.tar.gz &&
+ tar zxf ../../deps/common-lisp/trivial-features_0.8.tar.gz &&
+ tar zxf ../../deps/common-lisp/cl-charms-9bb94ef.tar.gz
)
SBCL_HOME="" tmp/sbcl/bin/sbcl --core tmp/sbcl/lib/sbcl/sbcl.core --no-sysinit --no-userinit \
--eval "(require 'asdf)" \
- --eval '(setf asdf:*central-registry* (list #p"tmp/deps/"))' \
+ --eval "(asdf:initialize-source-registry '(:source-registry (:tree \"${PWD}/tmp/deps\") (:directory \"${PWD}/src/main\") :IGNORE-INHERITED-CONFIGURATION))" \
--eval "(asdf:load-system :clnl)" \
--eval "(asdf:clear-output-translations)" \
--eval '(sb-ext:save-lisp-and-die "osxsbcl" :executable t :toplevel (function clnl:run))' \
cwd=$PWD
( cd tmp &&
- tar jxf ../deps/tarpit/sbcl-1.2.6-x86-64-linux-binary.tar.bz2 &&
+ tar jxf ../deps/linux/sbcl-1.2.6-x86-64-linux-binary.tar.bz2 &&
cd sbcl-1.2.6-x86-64-linux/ &&
SBCL_HOME="" INSTALL_ROOT=$cwd/tmp/sbcl/ bash install.sh )
mkdir -p tmp/deps/
( cd tmp/deps &&
- tar zxf ../../deps/tarpit/3b-cl-opengl-993d627.tar.gz &&
- tar zxf ../../deps/tarpit/alexandria-b1c6ee0.tar.gz &&
- tar zxf ../../deps/tarpit/babel_0.5.0.tar.gz &&
- tar zxf ../../deps/tarpit/cffi_0.15.0.tar.gz &&
- tar zxf ../../deps/tarpit/cl-ppcre.tar.gz &&
- tar zxf ../../deps/tarpit/ironclad.tar.gz &&
- tar zxf ../../deps/tarpit/mt19937-latest.tar.gz &&
- tar zxf ../../deps/tarpit/nibbles-v0.12.tar.gz &&
- tar zxf ../../deps/tarpit/trivial-features_0.8.tar.gz &&
- tar zxf ../../deps/tarpit/cl-charms-9bb94ef.tar.gz &&
- tar zxf ../../deps/tarpit/style-checker_0.1.tar.gz &&
- tar zxf ../../deps/tarpit/docgen_0.1.tar.gz &&
- ln -s cl-ppcre-2.0.10/cl-ppcre.asd . &&
- ln -s ironclad_0.33.0/ironclad.asd . &&
- ln -s mt19937-1.1.1/mt19937.asd . &&
- ln -s nibbles-0.12/nibbles.asd . &&
- ln -s 3b-cl-opengl-993d627/cl-glut.asd . &&
- ln -s 3b-cl-opengl-993d627/cl-opengl.asd . &&
- ln -s alexandria-b1c6ee0/alexandria.asd . &&
- ln -s babel_0.5.0/babel-streams.asd . &&
- ln -s babel_0.5.0/babel.asd . &&
- ln -s cffi_0.15.0/cffi-examples.asd . &&
- ln -s cffi_0.15.0/cffi.asd . &&
- ln -s cffi_0.15.0/cffi-libffi.asd . &&
- ln -s cffi_0.15.0/cffi-grovel.asd . &&
- ln -s cffi_0.15.0/cffi-uffi-compat.asd . &&
- ln -s trivial-features_0.8/trivial-features.asd . &&
- ln -s cl-charms/cl-charms.asd . &&
- ln -s style-checker_0.1/style-checker.asd . &&
- ln -s docgen_0.1/docgen.asd .
+ tar zxf ../../deps/common-lisp/3b-cl-opengl-993d627.tar.gz &&
+ tar zxf ../../deps/common-lisp/alexandria-b1c6ee0.tar.gz &&
+ tar zxf ../../deps/common-lisp/babel_0.5.0.tar.gz &&
+ tar zxf ../../deps/common-lisp/cffi_0.15.0.tar.gz &&
+ tar zxf ../../deps/common-lisp/cl-ppcre.tar.gz &&
+ tar zxf ../../deps/common-lisp/ironclad.tar.gz &&
+ tar zxf ../../deps/common-lisp/mt19937-latest.tar.gz &&
+ tar zxf ../../deps/common-lisp/nibbles-v0.12.tar.gz &&
+ tar zxf ../../deps/common-lisp/trivial-features_0.8.tar.gz &&
+ tar zxf ../../deps/common-lisp/cl-charms-9bb94ef.tar.gz &&
+ tar zxf ../../deps/common-lisp/style-checker_0.1.tar.gz &&
+ tar zxf ../../deps/common-lisp/docgen_0.1.tar.gz
)
SBCL_HOME="" tmp/sbcl/bin/sbcl --core tmp/sbcl/lib/sbcl/sbcl.core \
--eval "(require 'asdf)" \
- --eval '(setf asdf:*central-registry* (list #p"tmp/deps/"))' \
+ --eval "(asdf:initialize-source-registry '(:source-registry (:tree \"${PWD}/tmp/deps\") :IGNORE-INHERITED-CONFIGURATION))" \
+ --eval "(require 'asdf)" \
--eval "(asdf:load-system :cl-ppcre)" \
--eval "(asdf:load-system :mt19937)" \
--eval "(asdf:load-system :ironclad)" \
--- /dev/null
+#!/bin/bash
+
+# This sciprt builds a version of sbcl pre loaded with libraries that can run on windows.
+# You can use ./winsbcl.exe to run it
+
+# It is meant to be run from cygwin
+
+if ! type sbcl &> /dev/null ; then
+ echo "Please install sbcl. A version has been included in deps/windows for your convenience"
+ exit 1
+fi
+
+sbcl_exec=$(which sbcl)
+sbcl_dir=${sbcl_exec%sbcl}
+
+if [ ! -e "$sbcl_dir/freeglut.dll" ] ; then
+ echo "Please copy deps/windows/freeglut.dll into $sbcl_dir"
+ exit 1
+fi
+
+if [ ! -e "$sbcl_dir/pdcurses.dll" ] ; then
+ echo "Please copy deps/windows/pdcurses.dll into $sbcl_dir"
+ exit 1
+fi
+
+mkdir -p tmp/deps/
+
+( cd tmp/deps &&
+ tar zxf ../../deps/common-lisp/3b-cl-opengl-993d627.tar.gz &&
+ tar zxf ../../deps/common-lisp/alexandria-b1c6ee0.tar.gz &&
+ tar zxf ../../deps/common-lisp/babel_0.5.0.tar.gz &&
+ tar zxf ../../deps/common-lisp/cffi_0.15.0.tar.gz &&
+ tar zxf ../../deps/common-lisp/cl-ppcre.tar.gz &&
+ tar zxf ../../deps/common-lisp/ironclad.tar.gz &&
+ tar zxf ../../deps/common-lisp/mt19937-latest.tar.gz &&
+ tar zxf ../../deps/common-lisp/nibbles-v0.12.tar.gz &&
+ tar zxf ../../deps/common-lisp/trivial-features_0.8.tar.gz &&
+ tar zxf ../../deps/common-lisp/cl-charms-9bb94ef.tar.gz
+)
+
+cur_dir=$(cygpath -d $PWD)
+escaped_cur_dir=${cur_dir//\\/\\\\}
+
+sbcl --no-sysinit --no-userinit \
+ --eval "(require 'asdf)" \
+ --eval "(asdf:initialize-source-registry '(:source-registry (:tree \"${escaped_cur_dir}\\\\tmp\\\\deps\") (:directory \"${escaped_cur_dir}\\\\src\\\\main\") :IGNORE-INHERITED-CONFIGURATION))" \
+ --eval "(asdf:load-system :clnl)" \
+ --eval "(asdf:clear-output-translations)" \
+ --eval '(sb-ext:save-lisp-and-die "windowssbcl.exe" :executable t :toplevel (function clnl:run))'
+
+rm -rf tmp
+
+echo "Executable is windowssbcl.exe"
(setf *compile-print* nil)
(require 'asdf)
-(push #p"deps/" asdf:*central-registry*)
(asdf:load-system :clnl)
(clnl:run)
(setf *compile-print* nil)
(require 'asdf)
-(setf asdf:*central-registry* (list #p"deps/"))
+;(setf asdf:*central-registry* (list #p"deps/"))
+(asdf:initialize-source-registry `(:source-registry (:tree ,(car (directory "src"))) :IGNORE-INHERITED-CONFIGURATION))
(asdf:load-system :clnl.internal)
(asdf:load-system :clnl-test.internal)
+++ /dev/null
-../src/test/clnl-test.asd
\ No newline at end of file
+++ /dev/null
-../src/test/clnl-test.asd
\ No newline at end of file
+++ /dev/null
-../src/main/clnl.asd
\ No newline at end of file
+++ /dev/null
-../src/main/clnl.asd
\ No newline at end of file
(refresh-cli))
(defun setup-info (num-tall num-wide)
- (setf *info* (newwin 20 60 (floor (- num-tall 20) 2) (floor (- num-wide 60) 2)))
- (mvwprintw *info* 1 1
- (format nil
- "
- .
- / \\
- / \\ Welcome to CLNL version ~A!
- / \\
- /_______\\
-
- CLNL is an experiment at creating an alternate
- implementation of NetLogo.
-
- You can enter in various netlogo commands below,
- or use q to quit the program.
-
- See http://github.com/frankduncan/clnl for more
- information about CLNL and to keep apprised of
- any updates that may happen."
- (asdf:component-version (asdf:find-system :clnl))))
- (box *info* 0 0)
- (wrefresh *info*))
+ (let*
+ ((info "
+ / \\
+ / \\ Welcome to CLNL version ~A!
+ / \\
+ /_______\\
+
+ CLNL is an experiment at creating an alternate
+ implementation of NetLogo.
+
+ You can enter in various netlogo commands below,
+ or use q to quit the program.
+
+ See http://github.com/frankduncan/clnl for more
+ information about CLNL and to keep apprised of
+ any updates that may happen.")
+ (info-height (length (cl-ppcre:split "\\n" info)))
+ (info-width (apply #'max (mapcar #'length (cl-ppcre:split "\\n" info)))))
+ (setf *info* (newwin
+ (+ 3 info-height)
+ (+ 2 info-width)
+ (max 0 (floor (- num-tall info-height) 2))
+ (max 0 (floor (- num-wide info-width) 2))))
+ (mvwprintw *info* 1 0
+ (format nil info
+ (asdf:component-version (asdf:find-system :clnl))))
+ (box *info* 0 0)
+ (wrefresh *info*)))
;
; There's probably a better way, but I don't know it
-(asdf:defsystem clnl.internal
- :serial t
- :components ((:file "package")
- (:file "lex")
- (:file "parse")
- (:file "nvm")
- (:file "transpile")
- (:file "random")
- (:file "interface")
- (:file "cli")
- (:file "main")))
-
(asdf:defsystem clnl
:name "Experiment"
:version "0.0.1"
--- /dev/null
+; The systems are split up into two because travis will run more smoothly
+; if we use a custom built sbcl that has all the deps pre-loaded since
+; we are sure those will work just fine :)
+;
+; You should link to this file in your systems directory, or however you
+; handle your asdf configurations. Then just (asdf:load-system :clnl)
+;
+; There's probably a better way, but I don't know it
+
+(asdf:defsystem clnl.internal
+ :serial t
+ :components ((:file "package")
+ (:file "lex")
+ (:file "parse")
+ (:file "nvm")
+ (:file "transpile")
+ (:file "random")
+ (:file "interface")
+ (:file "cli")
+ (:file "main")))
; For why this is the way it is, see src/main/clnl.asd
-(asdf:defsystem clnl-test.internal
- :components ((:file "package")
- (:file "main")
- (:file "simpletests")
- (:file "viewtests")))
-
(asdf:defsystem clnl-test
:name "Experiment Tests"
:version "0.0.1"
--- /dev/null
+; For why this is the way it is, see src/main/clnl.asd
+(asdf:defsystem clnl-test.internal
+ :components ((:file "package")
+ (:file "main")
+ (:file "simpletests")
+ (:file "viewtests")))