#!/bin/csh if ($1 != "")goto $1 echo " " echo Hello! This is an automated script for installing Split on your echo system. There are a number of stages, some requiring action on your echo "part. Should the script be interrupted (and you wish to start it up" echo "again), you may restart it with 'install woof', where 'woof' is the" echo "name of the stage you wish to start at. You'll know where this is" echo "because I will periodically issue messages of the form 'stage = woof'." echo " " echo "I am hoping that this script is portable. If not (or there are any other" echo "problems), please let me know\!" echo " " ; echo "David Jaffe (e-mail: jaffe@cpthree.unl.edu)" echo " "; echo -n "Press return to proceed (or x, followed by return to exit)...."; set input = $<; if ($input == "x")exit; echo " "; acknowledge: ; echo stage = acknowledge; echo " " echo Software acknowledgments: Split makes use of the following free software echo which was not written by the author: echo "--- various GNU (Free Software Foundation) products, including g++ and" echo " libg++" echo "--- Brendan McKay's graph isomorphism package **nauty**" echo "--- Keith Briggs double-double precision floating point package **quad**." echo " "; echo -n Press return to proceed....; set input = $<; if ($input == "x")exit; echo " "; hardware_check: ; echo stage = hardware_check; echo " " echo "This program should run on any reasonably modern Unix machine. " echo "(However, spurious segmentation faults have been encountered under " echo "NeXTStep-Intel.)" echo " " echo This program requires at least 32 megabytes of RAM to install and use. echo If you have less than 32 megabytes of RAM, go buy some echo more before proceeding. If you have between 32 and 64 megabytes, you echo are probably OK, but the compilation may be slow, as there is likely echo to be a lot of swapping to disk. echo " "; echo -n Press return to proceed....; set input = $<; if ($input == "x")exit; echo " "; cplex_check: ; echo stage = cplex_check; echo " " echo Split functions best if the commercial linear programming solver CPLEX echo is installed. For academic users, a echo "'Linear Optimizer Single CPU License' costs about 500 dollars; you can " echo send echo e-mail to info@cplex.com if you want to get it. Otherwise, echo Split will work without CPLEX, but it will be slower. Split has been echo tested with echo versions 2.1 and 4.04 of CPLEX. Hopefully other versions echo will work as well. echo " "; echo -n Press return to proceed....; set input = $<; if ($input == "x")exit; echo " "; gnu_check: ; echo stage = gnu_check; echo " " echo "Now I'm going to ask if you have various programs installed on your" echo computer, all available for free, and mostly produced by the Free Software echo "Foundation (GNU). All are essential, except as noted, and you will need" echo "the indicated version. For more recent version (released since this was" echo "written), some adjustments may be necessary." echo "g++ (version 2.7.2)" echo " (Testing for g++ version...)" g++ --version echo " (If that's not 2.7.2, you should upgrade before proceeding.)" echo "libg++ (version 2.7.1)" echo -n "sort (the GNU version). I find the following binaries: " which sort | tr '\n' ' ' echo "." echo "Press return if the gnu binary appears first, which it should...." set input = $< echo -n "fold (the GNU version). I find the following binaries: " which fold | tr '\n' ' ' echo -n ". Press return if the gnu binary appears first, which it should...." set input = $< echo -n "gzip. I find the following binaries: " which gzip | tr '\n' ' set input = $< echo "m4 (the GNU version): I find: " m4 --version echo -n Press return if you the word GNU appears on the above line.... set input = $< echo "GNU binutils package (contains c++ filt)" echo "xdvi (version 20 or later -- only used by 'help' command)" echo "gs (ghostscript) -- only used by 'help' command)" echo echo Otherwise, go install the programs you do not have, and come back and echo try again. echo " "; echo -n Press return to proceed....; set input = $<; if ($input == "x")exit; echo " "; download: ; echo stage = download; echo " " echo You should now be in the directory where you want to install Split. echo This could be an empty directory or it could be a directory where you echo "previously installed Split. I won't delete anything, but I might" echo accidentally overwrite a file you care about. echo I will now download files into this directory by anonymous ftp. echo In total, about 800 kilobytes will be transferred. echo " "; echo -n Press return to proceed....; set input = $<; if ($input == "x")exit; echo " "; echo user ftp `whoami`@`hostname` > ftp_in echo cd pub >> ftp_in echo cd coding >> ftp_in echo binary >> ftp_in echo get CODE.gz >> ftp_in echo get nauty.c >> ftp_in echo get quad.h >> ftp_in echo get disect.cc >> ftp_in echo get nauty.h >> ftp_in echo get nug.alw.gz >> ftp_in echo get t.dvi.gz >> ftp_in echo get nautil.c >> ftp_in echo get quad.cc >> ftp_in echo get t.idxb >> ftp_in echo bye >> ftp_in ftp -n -v cpthree.unl.edu < ftp_in rm ftp_in echo " "; unpack: ; echo stage = unpack; echo " " echo "File transfer complete. Now I'll make subdirectories, unzip some files," echo "and put some files in them. Please wait..." mkdir cc doc inc obj tex calculations gunzip CODE.gz gunzip nug.alw.gz gunzip t.dvi.gz mv t.dvi tex mv nug.alw doc mv t.idxb tex mv quad.cc cc mv quad.h inc mv nauty.c cc mv nautil.c cc mv nauty.h inc echo " "; echo -n Done. Press return to proceed....; set input = $<; if ($input == "x")exit; echo " "; nextstep: ; echo stage = nextstep, echo " " echo If your platform is NeXTSTep-Intel, change nan.h to math.h in quad.cc. echo " "; echo -n Press return to proceed....; set input = $<; if ($input == "x")exit; echo " "; modify: ; echo stage = modify; echo " " echo Now you may need to modify CODE to suit your system, by editing the echo "#define lines, as indicated below. In the case where something should not" echo "be defined, put // in front of #define to comment out the line. In the" echo case where something should be defined, remove the // if present. echo " " echo --- CPLEX should be set to the name of your CPLEX executable file echo " (probably cplex or cplexmip)" echo --- CPLEX_VERSION should be set to the version number of your copy of CPLEX echo --- ABSOLUTE_PATH_FOR_CPLEX will need to be set if CPLEX refuses to echo " recognize relative file names" echo " " echo -n Make any needed changes to CODE and then press return to proceed.... set input = $<; if ($input == "x")exit; echo " "; disect: ; echo stage = disect; echo " " echo Now I am ready to unpack the file CODE. First I will compile the program echo disect, and then execute it on CODE. This takes 9 seconds on my echo machine, but disect is rather badly written, and could take forever if echo files are being shuffled across a network. echo " "; echo -n Press return to proceed with the disection....; set input = $<; if ($input == "x")exit; echo " "; g++ disect.cc -s -o disect disect CODE chmod 755 prep echo " "; echo -n Done. Press return to proceed....; set input = $<; if ($input == "x")exit; echo " "; compile: ; echo stage = compile echo "And now it's time to compile Split\! This takes 8 minutes on my machine." echo "If it is incredibly slow on your machine, try reading the file 'prep'" echo " "; echo -n Press return to proceed with the compilation....; set input = $<; if ($input == "x")exit; echo " "; prep all echo " " echo Assuming that no error messages appeared above, Split has now been echo "successfully installed\!" echo " " echo If you do not wish to modify and thence recompile the program, only echo the following files/directories are essential: echo Split, code.data, calculations, tex, tex/t.dvi, and tex/t.idxb. echo "You could (if you wished) copy these to another place on your computer" echo for someone else to use. echo " "; echo You may wish to look at the file doc/backward-compatibility, which echo contains a record of incompatibilities with earlier versions that have echo been introduced. echo " "; echo -n Press return to proceed....; set input = $<; if ($input == "x")exit; echo " "; echo You can now test the program file of the report by typing echo " Split < code.data" echo On my machine, this takes 39 hours. That is with CPLEX. Without it, echo execution will be slower. In the report, under the heading echo "'Execution of the proofs in this report'", you will find some additional echo tests that may be carried out. echo " "; echo Have fun!