xiw / stack

A static checker for identifying unstable code.
http://css.csail.mit.edu/stack/
Other
359 stars 56 forks source link

Fix up the build scripts #33

Open mstewartgallus opened 10 years ago

mstewartgallus commented 10 years ago

Now the modules are isolated and everything installs properly.

Bad build scripts make me really, really angry so I made everything much cleaner.

xiw commented 10 years ago

awesome! thanks!

sorry i don't have a testing machine this week. does make check work (without make install)?

also im not particular into hierarchical source directory---with this patch we would have to repeat *_CXXFLAGS several times rather than keeping them in one place.

mstewartgallus commented 10 years ago

I tried fixing the test suite but I have an old version of Ruby so I can't fully test the test suite. In the meanwhile I'll work on using Automake's %C% and %D% substitutions so I can just include makefiles instead of using SUBDIRS so that a global CXXFLAGS works.

denji commented 10 years ago

Flag CPP incorrect work, please remove. configure: error: C preprocessor fails sanity check

unset ENV[CPP], work.

llvm-config tools automatically configure LLVM environment.

usage: llvm-config <OPTION>... [<COMPONENT>...]

Get various configuration information needed to compile programs which use
LLVM.  Typically called from 'configure' scripts.  Examples:
  llvm-config --cxxflags
  llvm-config --ldflags
  llvm-config --libs engine bcreader scalaropts

Options:
  --version         Print LLVM version.
  --prefix          Print the installation prefix.
  --src-root        Print the source root LLVM was built from.
  --obj-root        Print the object root used to build LLVM.
  --bindir          Directory containing LLVM executables.
  --includedir      Directory containing LLVM headers.
  --libdir          Directory containing LLVM libraries.
  --cppflags        C preprocessor flags for files that include LLVM headers.
  --cflags          C compiler flags for files that include LLVM headers.
  --cxxflags        C++ compiler flags for files that include LLVM headers.
  --ldflags         Print Linker flags.
  --system-libs     System Libraries needed to link against LLVM components.
  --libs            Libraries needed to link against LLVM components.
  --libnames        Bare library names for in-tree builds.
  --libfiles        Fully qualified library filenames for makefile depends.
  --components      List of all possible components.
  --targets-built   List of all targets currently built.
  --host-target     Target triple used to configure LLVM.
  --build-mode      Print build mode of LLVM tree (e.g. Debug or Release).
  --assertion-mode  Print assertion mode of LLVM tree (ON or OFF).
Typical components:
  all               All LLVM libraries (default).
  engine            Either a native JIT or a bitcode interpreter.