Commit Graph

181 Commits

Author SHA1 Message Date
Chris Lattner
694c5df02a Add facilities for building source that is outside of the current directory
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@6238 91177308-0d34-0410-b5e6-96231b3b80d8
2003-05-15 21:28:55 +00:00
Chris Lattner
760da06489 Fix several bugs in the build system, including the use of the Debug version of Burg no matter what configuration is currently configured.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@5744 91177308-0d34-0410-b5e6-96231b3b80d8
2003-03-14 20:25:22 +00:00
Chris Lattner
fe95dae26b Fix warnings compiling C files
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@5600 91177308-0d34-0410-b5e6-96231b3b80d8
2003-02-19 22:12:20 +00:00
Chris Lattner
1d1e5b598e Fix profile builds
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@5551 91177308-0d34-0410-b5e6-96231b3b80d8
2003-02-13 16:56:30 +00:00
Chris Lattner
3aed67875d Add -fomit-frame-pointer when optimizing
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@5547 91177308-0d34-0410-b5e6-96231b3b80d8
2003-02-12 20:45:45 +00:00
Chris Lattner
527002cfdd Fix strip issue Joel ran into
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@5449 91177308-0d34-0410-b5e6-96231b3b80d8
2003-01-31 19:00:26 +00:00
Chris Lattner
6d131b4582 Fix problem with flex scanners and huge token sizes
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@5410 91177308-0d34-0410-b5e6-96231b3b80d8
2003-01-23 16:33:10 +00:00
Chris Lattner
8d7dfb36c6 Fix lli build problem with parallel makes
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@5396 91177308-0d34-0410-b5e6-96231b3b80d8
2003-01-22 16:13:31 +00:00
Chris Lattner
e899678ffd Simplify and correct rules for building lex/yacc files. Make sure to delete
output upon make clean


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@5347 91177308-0d34-0410-b5e6-96231b3b80d8
2003-01-16 22:44:19 +00:00
Chris Lattner
30440c6342 Add helper
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@5342 91177308-0d34-0410-b5e6-96231b3b80d8
2003-01-16 21:06:18 +00:00
Chris Lattner
dc95aded43 Add support for a recursive test target
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@5332 91177308-0d34-0410-b5e6-96231b3b80d8
2003-01-16 20:02:30 +00:00
Vikram S. Adve
ec4d36276f Use -Wl,-x instead of -s: it is more portable, and in particular,
is needed on BSD (MacOS).
Also, use -Ldir instead of -L dir on the link line.  Same reason...


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@5068 91177308-0d34-0410-b5e6-96231b3b80d8
2002-12-16 01:31:18 +00:00
Misha Brukman
ab6d293435 On `make clean', kill the core files produced, which are of the form:
core.### where ### is the process ID. We use core.[0-9][0-9]* to avoid killing
core.c, core.cpp, and core.h files which may be part of benchmarks.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@4913 91177308-0d34-0410-b5e6-96231b3b80d8
2002-12-04 17:08:15 +00:00
Chris Lattner
1c588505b8 Generalize ExportSymbols into PLATFORMLINKOPTS
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@4542 91177308-0d34-0410-b5e6-96231b3b80d8
2002-11-04 20:50:33 +00:00
Chris Lattner
3ea6a42b64 Don't link tools with -g objects!
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@4370 91177308-0d34-0410-b5e6-96231b3b80d8
2002-10-29 15:15:22 +00:00
Chris Lattner
ed03bc913f Patch submited by Casey to remove obnoxious warnings.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@4278 91177308-0d34-0410-b5e6-96231b3b80d8
2002-10-25 14:32:42 +00:00
Chris Lattner
f924b2de08 Disable optimization that doesn't apply to C
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@4264 91177308-0d34-0410-b5e6-96231b3b80d8
2002-10-22 23:35:28 +00:00
Chris Lattner
1eeac6612b Fix misspelled variable
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@4262 91177308-0d34-0410-b5e6-96231b3b80d8
2002-10-22 23:28:23 +00:00
Vikram S. Adve
3ea6769070 Warn when we are linking an executable without symbols.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@4236 91177308-0d34-0410-b5e6-96231b3b80d8
2002-10-20 21:45:49 +00:00
Vikram S. Adve
a0c8e0a73d Remove outdated line which of course cvs merging never detects...
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@4175 91177308-0d34-0410-b5e6-96231b3b80d8
2002-10-15 01:59:45 +00:00
Vikram S. Adve
ad9ea7e694 Allow the Source variable to be overridden completely if needed.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@4172 91177308-0d34-0410-b5e6-96231b3b80d8
2002-10-14 16:40:04 +00:00
Chris Lattner
9e39816f13 Make sure to print message when linking a debug .o file
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@3918 91177308-0d34-0410-b5e6-96231b3b80d8
2002-09-25 17:15:22 +00:00
Chris Lattner
172b648cd4 * Minor fixes to support C files.
* Build burg as a utility now, change its location
* Clean up other rules


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@3876 91177308-0d34-0410-b5e6-96231b3b80d8
2002-09-22 02:47:15 +00:00
Vikram S. Adve
e155af8376 Fix yet another profile linking issue.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@3865 91177308-0d34-0410-b5e6-96231b3b80d8
2002-09-20 18:16:20 +00:00
Vikram S. Adve
12520cdab4 Fix link error for profile version. Also, build Burg differently
for different architectures.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@3862 91177308-0d34-0410-b5e6-96231b3b80d8
2002-09-20 16:15:57 +00:00
Vikram S. Adve
41e7891e07 The ENABLE_PROFILING flag now builds the profiled libraries and executables
into a Profile/ directory to keep them separate from the Debug/ and
Release/ versions.  Also, it turns on ENABLE_OPTIMIZED automatically.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@3854 91177308-0d34-0410-b5e6-96231b3b80d8
2002-09-20 14:03:13 +00:00
Chris Lattner
9b94701fdf Move the burg option out of Makefile.config into Makefile.common since
it no longer needs to be configured.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@3828 91177308-0d34-0410-b5e6-96231b3b80d8
2002-09-19 19:42:24 +00:00
Vikram S. Adve
feeae58705 Strip tools/Debug/ executables by default. Define KEEP_SYMBOLS to
turn off stripping for any executable.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@3812 91177308-0d34-0410-b5e6-96231b3b80d8
2002-09-18 11:55:13 +00:00
Anand Shukla
7c7a07e501 corrected small bug, to handle when DIRS is not defined.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@3810 91177308-0d34-0410-b5e6-96231b3b80d8
2002-09-18 04:29:30 +00:00
Chris Lattner
a8abc228ba Add support for the new PARALLEL_DIRS option
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@3807 91177308-0d34-0410-b5e6-96231b3b80d8
2002-09-18 03:22:27 +00:00
Chris Lattner
16d1f73cf3 Allow the VERBOSE=1 option to turn on output of recursive make behavior
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@3796 91177308-0d34-0410-b5e6-96231b3b80d8
2002-09-17 23:45:34 +00:00
Chris Lattner
f1ffd99a75 Fix parallel recursive make to build directories in order
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@3794 91177308-0d34-0410-b5e6-96231b3b80d8
2002-09-17 23:35:02 +00:00
Chris Lattner
2a548c5d5f Comment line of the makefile
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@3770 91177308-0d34-0410-b5e6-96231b3b80d8
2002-09-16 22:36:42 +00:00
Chris Lattner
ccb4ebd6d1 Handle whitespace in LIBRARYNAME gracefully
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@3769 91177308-0d34-0410-b5e6-96231b3b80d8
2002-09-16 22:34:56 +00:00
Chris Lattner
4bb13b8eb1 Factor platform specific makefile directives out into their own makefile
fragments.  This is gross, but having tons of confusing conditionals all
throughout the build system seems worst.

Credits got to Casey Carter for the idea.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@3705 91177308-0d34-0410-b5e6-96231b3b80d8
2002-09-13 22:14:47 +00:00
Chris Lattner
ab060db476 Link .so files correctly on either linux or solaris
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@3703 91177308-0d34-0410-b5e6-96231b3b80d8
2002-09-13 21:41:07 +00:00
Chris Lattner
73e1d0f195 Build with -D_GNU_SOURCE to enable gnu extensions in header files
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@3702 91177308-0d34-0410-b5e6-96231b3b80d8
2002-09-13 16:02:26 +00:00
Chris Lattner
287d4436c5 Make sure to print a message when linking a tool
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@3687 91177308-0d34-0410-b5e6-96231b3b80d8
2002-09-12 17:02:40 +00:00
Misha Brukman
b5f096fc51 Compiling with "gmake" should produce less output. The compilation/linking
flags are always the same anyway, who wants to see so much text on the
screen? Compiling with "gmake VERBOSE=1" should produce all the output
you're used to.

Basically it checks for VERBOSE being defined, and if it is, sets VERB
appropriately. VERB is then prepended in a bunch of key places such that
when VERB is "@", the command is not echoed, when VERB is not set to
anything, it's as before.

One thing I could not get rid of is "gmake[1]: Entering directory <blah>",
but running "gmake -s" suppresses it all, and shows just the interesting
stuff.

Now output (when running "gmake -s" will look something like):

<snip>
======= Linking target debug library =======
Compiling Writer.cpp
Compiling getLLVMinfo.cpp
Compiling as.cpp
Compiling dis.cpp
Compiling opt.cpp
Compiling gccas.cpp
<snip>


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@3686 91177308-0d34-0410-b5e6-96231b3b80d8
2002-09-12 16:05:39 +00:00
Vikram S. Adve
c214e71edf Simplified significantly by pulling out local configuration options
into Makefile.config.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@3527 91177308-0d34-0410-b5e6-96231b3b80d8
2002-08-29 23:28:46 +00:00
Vikram S. Adve
764b46ea2d Factor out /shared/... path to simplify changing it.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@3521 91177308-0d34-0410-b5e6-96231b3b80d8
2002-08-29 18:40:51 +00:00
Vikram S. Adve
f8d630a0fa Fix clean command to clean in /shared when that is used.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@3449 91177308-0d34-0410-b5e6-96231b3b80d8
2002-08-22 03:20:27 +00:00
Chris Lattner
8e28a70044 Throw purify temporary files into /shared if we have it.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@3365 91177308-0d34-0410-b5e6-96231b3b80d8
2002-08-17 21:39:58 +00:00
Chris Lattner
285af38864 - Makefile changes:
- Now build executables into /shared
   - New BUILD_ROOT_TOP variable which is basically = $(BUILD_ROOT)/$(LEVEL) but
     cleaner and works for llvm/test/*
   - Use := more in Makefile.common


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@3291 91177308-0d34-0410-b5e6-96231b3b80d8
2002-08-12 21:19:28 +00:00
Chris Lattner
43db05a81c Oops, I accidentally broke the .d files. Fixed thusly
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@3272 91177308-0d34-0410-b5e6-96231b3b80d8
2002-08-09 19:18:12 +00:00
Chris Lattner
e16b1b492d * Remove some bogus dependencies on Depend/.dir
* Build into the machine local /shared directory instead of using local
  Debug/Depend/Release directories


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@3269 91177308-0d34-0410-b5e6-96231b3b80d8
2002-08-09 15:41:55 +00:00
Chris Lattner
9dd794ee00 Comment options that may be enabled
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@3237 91177308-0d34-0410-b5e6-96231b3b80d8
2002-08-03 20:19:30 +00:00
Vikram S. Adve
60f5606f5f Don't build Debug/ versions when ENABLE_OPTIMIZED is on.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@3216 91177308-0d34-0410-b5e6-96231b3b80d8
2002-08-02 18:34:12 +00:00
Chris Lattner
1917e95cf0 Cleanup Makefile a bit
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@3192 91177308-0d34-0410-b5e6-96231b3b80d8
2002-07-31 21:32:05 +00:00
Chris Lattner
4fa128c950 Changes to allow building lib/Target/Sparc the FIRST time.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@3078 91177308-0d34-0410-b5e6-96231b3b80d8
2002-07-25 15:01:19 +00:00
Chris Lattner
edf1f23e53 Allow directories to specify that they want to be built as a shared object by default
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@3027 91177308-0d34-0410-b5e6-96231b3b80d8
2002-07-23 19:21:31 +00:00
Chris Lattner
e62dbe9a22 Enable USEDLIBS to contain .a and .o files
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@3003 91177308-0d34-0410-b5e6-96231b3b80d8
2002-07-23 17:56:16 +00:00
Vikram S. Adve
d60aedef05 Add makefile-mode flag for emacs.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@2841 91177308-0d34-0410-b5e6-96231b3b80d8
2002-07-09 12:04:21 +00:00
Chris Lattner
18f4701b2b * Allow a profile'd code build to be done with a simple 'make ENABLE_PROFILING=1'
* Only build tags for include, lib, and tools, not tests
* Turn on verbose output from bison to get information about shift/reduce
  conficts (why isn't this the default??)


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@2603 91177308-0d34-0410-b5e6-96231b3b80d8
2002-05-10 18:51:54 +00:00
Chris Lattner
ec6bed27dd Hopefully this change will make the makefile work for other people without hacking it.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@2128 91177308-0d34-0410-b5e6-96231b3b80d8
2002-04-07 06:18:40 +00:00
Chris Lattner
12604ed51a * Allow purify builds to be enabled without hacking the makefile. Now you
just have to run: make ENABLE_PURIFY=1
* Add command to the link line that makes the broken GCC 3.0 compiler work
  without affecting 2.95.3


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@2116 91177308-0d34-0410-b5e6-96231b3b80d8
2002-04-05 18:56:58 +00:00
Chris Lattner
0cac4b8f3f Try to fix build error
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@1723 91177308-0d34-0410-b5e6-96231b3b80d8
2002-02-11 17:12:03 +00:00
Chris Lattner
c7acf81519 Add := to make stuff more efficient
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@1551 91177308-0d34-0410-b5e6-96231b3b80d8
2002-01-23 05:46:01 +00:00
Chris Lattner
514fc3651b Reenable warning now that Chuck fixed GCC
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@1517 91177308-0d34-0410-b5e6-96231b3b80d8
2002-01-21 23:15:20 +00:00
Chris Lattner
697954c15d Changes to build successfully with GCC 3.02
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@1503 91177308-0d34-0410-b5e6-96231b3b80d8
2002-01-20 22:54:45 +00:00
Chris Lattner
aa6ec735cf 1. -Winline emits spurious warnings that aren't useful right now
2. Fix the "rebuild everything if I change one file" problem


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@1176 91177308-0d34-0410-b5e6-96231b3b80d8
2001-11-07 14:50:58 +00:00
Chris Lattner
6e39070b09 Add easy way to enable purify support
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@1045 91177308-0d34-0410-b5e6-96231b3b80d8
2001-10-30 20:24:08 +00:00
Vikram S. Adve
27dc7b6b9d Simplify etags command.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@954 91177308-0d34-0410-b5e6-96231b3b80d8
2001-10-22 13:58:22 +00:00
Chris Lattner
e001059e0a Change Sources specifier to ExtraSources
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@874 91177308-0d34-0410-b5e6-96231b3b80d8
2001-10-18 01:48:09 +00:00
Vikram S. Adve
c4bed346ec Allow only extra Source files to be listed in a local Makefile.
Needed for automatically generated .cpp files.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@853 91177308-0d34-0410-b5e6-96231b3b80d8
2001-10-17 12:33:55 +00:00
Chris Lattner
db00877496 Burg files should come out of the Debug Directory for temporary files
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@790 91177308-0d34-0410-b5e6-96231b3b80d8
2001-10-14 17:23:55 +00:00
Vikram S. Adve
022d06ce2f Fixed tags target so it only happens at root level.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@787 91177308-0d34-0410-b5e6-96231b3b80d8
2001-10-13 12:26:59 +00:00
Chris Lattner
669bd7c2c2 Each tools should not make tags
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@730 91177308-0d34-0410-b5e6-96231b3b80d8
2001-10-13 05:10:29 +00:00
Vikram S. Adve
0193d5e58e Added a rule for building TAGS.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@723 91177308-0d34-0410-b5e6-96231b3b80d8
2001-10-10 22:35:00 +00:00
Chris Lattner
49f2b9470e Add support for tool specified linker options
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@527 91177308-0d34-0410-b5e6-96231b3b80d8
2001-09-10 04:49:26 +00:00
Chris Lattner
bf2f043659 Fix automatic dependence on static libs
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@513 91177308-0d34-0410-b5e6-96231b3b80d8
2001-09-09 20:59:28 +00:00
Chris Lattner
1cbc29ff20 Support TOOLNAME and USEDLIBS options for easier tool building
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@498 91177308-0d34-0410-b5e6-96231b3b80d8
2001-09-07 22:57:58 +00:00
Vikram S. Adve
d9151962df Added InstrSched library to link line.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@386 91177308-0d34-0410-b5e6-96231b3b80d8
2001-08-28 21:33:33 +00:00
Vikram S. Adve
bedbcf65e2 And add rule to create a .cpp source file from burg input file!
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@345 91177308-0d34-0410-b5e6-96231b3b80d8
2001-08-06 19:06:43 +00:00
Vikram S. Adve
dba59efd43 Add path and options for burg.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@343 91177308-0d34-0410-b5e6-96231b3b80d8
2001-08-06 19:01:20 +00:00
Vikram S. Adve
588f14855f Remove lib/LLC library.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@314 91177308-0d34-0410-b5e6-96231b3b80d8
2001-07-28 04:39:27 +00:00
Vikram S. Adve
c4651a91c0 Added support for getting the dependence of an executable on its libs,
using a variable to get the list of libraries on the link path.
BUG: If the library in the same directory as the executable is missing,
BUG: gnumake will build the library but then fail when linking the executable
BUG: saying the library was not found.  Need a better hack.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@225 91177308-0d34-0410-b5e6-96231b3b80d8
2001-07-21 12:38:14 +00:00
Chris Lattner
febb11f9af Compile source files in alphabetical order
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@202 91177308-0d34-0410-b5e6-96231b3b80d8
2001-07-18 23:43:37 +00:00
Vikram S. Adve
112a72ce80 Changed default to building library archives instead of shared objects.
Added support for compiling *.c files.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@197 91177308-0d34-0410-b5e6-96231b3b80d8
2001-07-15 13:16:47 +00:00
Chris Lattner
b19e59cb8d Fixed the obnoxious problem that caused an entire directory to rebuild
even if you only change one .cpp file. Yaay


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@97 91177308-0d34-0410-b5e6-96231b3b80d8
2001-06-29 05:20:16 +00:00
Chris Lattner
009505452b Initial revision
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@2 91177308-0d34-0410-b5e6-96231b3b80d8
2001-06-06 20:29:01 +00:00