readme 1.67 KB
Newer Older
Alan Mishchenko committed
1 2 3
Often the code comes directly from a Windows computer.
The following steps may be needed to compile it on UNIX:

Alan Mishchenko committed
4 5
Modify Makefile to have -DLIN (for 32-bits) or -DLIN64 (for 64-bits)

Alan Mishchenko committed
6 7 8 9 10 11 12 13
>> dos2unix Makefile Makefile
>> dos2unix depends.sh depends.sh
>> chmod 755 depends.sh
>> make  // on Solaris, try "gmake"

If compiling as a static library, it is necessary to uncomment
#define _LIB in "src/abc/main/main.c"

Alan Mishchenko committed
14 15 16 17
To compile with Microsoft Visual Studio higher than 6.0,
remove ABC_CHECK_LEAKS from the preprocessor definitions
for the debug version (Project->Settings->C/C++->Preprocessor Definitions)

Alan Mishchenko committed
18 19 20
If compilation does not start because of the cyclic dependency check, 
try "touching" all files:    find ./ -type f -exec touch "{}" \;

Alan Mishchenko committed
21 22 23 24 25 26 27 28 29 30 31 32
Several things to try if it does not compile on your platform:
- Try running all code (not only Makefile and depends.sh) through dos2unix
- Try the following actions:
  (a) Remove flags from the libs line (LIBS :=) in Makefile
  (b) Remove "src\base\main\libSupport.c" from "src\base\main\module.make"
  (c) Comment calls to Libs_Init() and Libs_End() in "src\base\main\mainInit.c"
- Try linking with gcc (rather than g++)
  For this replace "LD   := g++" with "LD   := gcc -lm" in Makefile
- If your Linux distributin does not have "readline", you may have problems 
  compiling ABC with gcc. Please try installing this library from
  http://tiswww.case.edu/php/chet/readline/rltop.html

Alan Mishchenko committed
33 34 35 36 37 38 39
To compile the latest version of ABC, you may need to define "LIN" or "LIN64" 
(depending on whether you are using 32- or 64-bit Linux). 
For example, instead of
    OPTFLAGS  := -g -O
use
    OPTFLAGS  := -g -O -DLIN64
in Makefile.
Alan Mishchenko committed
40 41 42

Finally, run regression test:
abc>>> so regtest.script