Skip to content

Commit

Permalink
Expand COMPILING and setup_env.py to be even more userfriendly
Browse files Browse the repository at this point in the history
  • Loading branch information
Jens Geiregat committed May 16, 2012
1 parent 6520091 commit 72e7248
Show file tree
Hide file tree
Showing 2 changed files with 20 additions and 2 deletions.
9 changes: 8 additions & 1 deletion COMPILING
Expand Up @@ -8,9 +8,16 @@ react 0.9.2
camlbz2 0.6.0


we provide a script that sets up the development the prerequisites:
we provide a script that sets up the development prerequisites:
python tools/setup_env.py

You can tweak the features/dependencies of the development prerequisites with
command line arguments to the tools/setup_env.py script. Check out:
python tools/setup_env.py --help

Note that when the tools/setup_env.py script has finished, it outputs some
commands for you to run in your shell!

COMPILING:

we use ocamlbuild combined with ocamlfind as main driver for our builds.
Expand Down
13 changes: 12 additions & 1 deletion tools/setup_env.py
Expand Up @@ -284,6 +284,16 @@ def install_libbz2():
lib.sh(['make', '-f', 'Makefile-libbz2_so'])
lib.sh(['cp', 'libbz2.so.1.0.6', '%s/lib' % PREFIX])

def print_env_setup_help():
print
print
print 'Now execute these statements in your shell to enable your ' \
'build env:'
print 'export OCAML_HOME=%s' % PREFIX
print 'export LIBRARY_PATH=${LIBRARY_PATH}:${OCAML_HOME}/lib'
print 'export LD_LIBRARY_PATH=${LD_LIBRARY_PATH}:${OCAML_HOME}/lib'
print 'export PATH=${PATH}:${OCAML_HOME}/bin'

def do_it():
fine = maybe_clean()
if not fine:
Expand All @@ -305,9 +315,10 @@ def do_it():
if options.bisect:
install_bisect()
#sudo cp lablgtk-2.14.2/examples/test.xpm /usr/share/pixmaps/ocaml.xpm
print '\n\nnow prepend %s/bin to your PATH' % PREFIX
print_env_setup_help()
else:
print "setup_env.py: quick-check tells me we're fine (%s)" % PREFIX
print_env_setup_help()


if __name__ == '__main__':
Expand Down

0 comments on commit 72e7248

Please sign in to comment.