Commit Graph

792 Commits

Author SHA1 Message Date
Daniel Dunbar 8657a02e3e Eliminate CFERuntimeLibDir make variable, this shouldn't be needed.
llvm-svn: 96932
2010-02-23 09:28:50 +00:00
Daniel Dunbar 40886109ce Inline and eliminate LLVMG{CC,XX}WITHPATH.
llvm-svn: 96913
2010-02-23 07:56:41 +00:00
Daniel Dunbar e63080d6cc Remove dead LUPGRADE make variable.
llvm-svn: 96911
2010-02-23 07:56:36 +00:00
Daniel Dunbar e7d4f92cfa Kill off LLVMGCC_MAJVERS make variable.
llvm-svn: 96907
2010-02-23 07:56:22 +00:00
Jeffrey Yasskin c451027db9 Roll back the shared library, r96559. It broke two darwins and arm, mysteriously.
llvm-svn: 96569
2010-02-18 04:43:02 +00:00
Jeffrey Yasskin f750fefaf8 Add a shared library for LLVM, named libLLVM2.7svn.(so|dylib), and add an
--enable-shared configure flag to have the tools linked shared. (2.7svn is just
$(LLVMVersion) so it'll change to "2.7" in the release.)  Always link the
example programs shared to test that the shared library keeps working.

On my mac laptop, Debug libLLVM2.7svn.dylib is 39MB, and opt (for example) is
16M static vs 440K shared.

Two things are less than ideal here:
1) The library doesn't include any version information. Since we expect to break
the ABI with every release, this shouldn't be much of a problem. If we do
release a compatible 2.7.1, we may be able to hack its library to work with
binaries compiled against 2.7.0, or we can just ask them to recompile. I'm
hoping to get a real packaging expert to look at this for the 2.8 release.
2) llvm-config doesn't yet have an option to print link options for the shared
library. I'll add this as a subsequent patch.

llvm-svn: 96559
2010-02-18 02:36:02 +00:00
Sean Callanan 82436d1666 Added a custom TableGen backend to support the
enhanced disassembler, and the necessary makefile
rules to build the table for X86.

llvm-svn: 94764
2010-01-29 00:21:04 +00:00
Chris Lattner 823aed16f9 make -fno-rtti the default unless a directory builds with REQUIRES_RTTI.
llvm-svn: 94378
2010-01-24 20:43:08 +00:00
Chris Lattner db308fdd35 libs that need EH need RTTI.
llvm-svn: 94376
2010-01-24 20:21:50 +00:00
Chris Lattner ab8a7c49b2 ENABLE_EXPENSIVE_CHECKS shouldn't know how rtti is enabled, let REQUIRES_RTTI handle it.
llvm-svn: 94375
2010-01-24 20:20:40 +00:00
Daniel Dunbar 99ab0e0377 make: Make .o files depend on Makefile, at least for now.
llvm-svn: 94184
2010-01-22 18:10:54 +00:00
Anton Korobeynikov 803c60c012 Provide magic define on mingw to not generate inline variants of ctyper functions.
Otherwise we'll end with random cyclic deps between libraries due to this.
Proposed by Gianluigi Tiesi!

llvm-svn: 93635
2010-01-16 14:06:58 +00:00
Daniel Dunbar e8b8ccefcb Add the rest of the build system logic for optional target disassemblers
llvm-svn: 89841
2009-11-25 04:46:58 +00:00
Daniel Dunbar 0dd2b817c2 Add TOOLALIAS makefile variable; this defines an alternate name for a program
which the makefiles will create by symlinking the actual tool to.
 - For use by clang, where we want to make 'clang++' and alias for clang (which
   enables C++ support in the driver)

 - Not sure this is the best approach, alternative suggestions welcome!

llvm-svn: 89282
2009-11-19 00:14:53 +00:00
Daniel Dunbar 08d4ab9663 Add "Unoptimized" build (NO_DEBUG_SYMBOLS=1 ENABLE_OPTIMIZED=1), for reducing
disk space, and increasing battery lifetime. :)

llvm-svn: 88978
2009-11-16 22:37:52 +00:00
Daniel Dunbar b4a289c88e configure: Add --with-optimize-option, for setting the default value of
OPTIMIZE_OPTION.

llvm-svn: 86005
2009-11-04 04:32:50 +00:00
Jim Grosbach 95e6e933ed Build in ARM mode explicitly when on ARM Darwin
llvm-svn: 85615
2009-10-30 21:33:05 +00:00
Nick Lewycky efd3e907b4 Indent.
llvm-svn: 85034
2009-10-25 03:22:00 +00:00
Jakob Stoklund Olesen 79843050d5 Tablegen target intrinsics from the target main .td file.
Fix pasto.

llvm-svn: 84190
2009-10-15 18:48:47 +00:00
Edward O'Callaghan 4ae411e096 AuroraUX needs special Solaris system header.
llvm-svn: 84076
2009-10-14 05:55:03 +00:00
Mikhail Glushenkov fc8809d0ac Raise the limit on built-in plugins in llvmc to 10.
llvm-svn: 83614
2009-10-09 04:15:52 +00:00
Jakob Stoklund Olesen befc8539d2 Remove trailing whitespace from build output.
llvm-svn: 83284
2009-10-04 17:54:36 +00:00
Jeffrey Yasskin c3273dca48 Enable -g with DEBUG_SYMBOLS and --enable-debug-symbols instead of
DEBUG_RUNTIME.

llvm-svn: 82906
2009-09-27 17:47:29 +00:00
Jeffrey Yasskin db281085c5 This patch causes the --enable-debug-runtime configure flag and the
DEBUG_RUNTIME Makefile variable to pass -g to gcc when building LLVM's objects.
Without this, it's very hard to debug crashes that happen in Release-Asserts
mode but not Debug mode.

llvm-svn: 82775
2009-09-25 16:46:09 +00:00
Daniel Dunbar f2719e6c6a Add 'make check-all', which runs the LLVM tests along with the clang tests if
its in the standard location.

llvm-svn: 82374
2009-09-20 06:17:21 +00:00
Daniel Dunbar 96ccc47a13 Build (not test) the unittests as part of a normal build.
- 'make unittests' still builds and tests.
 - 'make unitcheck' inside a unittest directory runs the tests in that directory.

llvm-svn: 81725
2009-09-13 22:39:27 +00:00
Daniel Dunbar 63f5a77822 Revert unittests build changes temporarily, the unit test build isn't -j safe.
llvm-svn: 81692
2009-09-13 18:58:14 +00:00
Daniel Dunbar 37af2a9588 Build (not test) the unittests as part of a normal build.
- 'make unittests' still builds and tests.
 - 'make unitcheck' inside a unittest directory runs the tests in that directory.

llvm-svn: 81687
2009-09-13 18:43:46 +00:00
Daniel Dunbar 24c00479df ... and fix the REQUIRES_RTTI condition.
llvm-svn: 81524
2009-09-11 15:47:24 +00:00
Daniel Dunbar 421bca3c70 Fix REQUIRES_RTTI while awake.
llvm-svn: 81523
2009-09-11 15:45:13 +00:00
Daniel Dunbar 8504030c8b Make REQUIRES_RTTI work.
llvm-svn: 81522
2009-09-11 15:39:39 +00:00
Evan Cheng 57b14190e6 Do not specify -mmacosx-version-min if building for arm-apple-darwin.
llvm-svn: 81240
2009-09-08 18:52:20 +00:00
Dan Gohman 40d204fc83 llvm-as is no longer needed here, now that opt can read assembly
files directly.

llvm-svn: 81222
2009-09-08 15:52:56 +00:00
Daniel Dunbar 3eeddd22dd Add 'lit' support for llvm tests.
- This adds 'make check-lit' from the top-level Makefile.

llvm-svn: 81191
2009-09-08 05:31:44 +00:00
Dan Gohman a7326b5ba5 Remove some unnecessary -f options.
llvm-svn: 80924
2009-09-03 16:11:53 +00:00
Daniel Dunbar 213f8f4860 Filter out -fno-rtti from CXXFLAGS as well (in an expensive checks build).
llvm-svn: 80910
2009-09-03 08:41:19 +00:00
Daniel Dunbar 8d799c5144 Fix creation of .bca libraries with EXPORTED_SYMBOLS_LIST, this was putting the
llvm-ld shell wrapper script in the archive, not the relinked object!

Also, rename the temp file to avoid conflicts.

llvm-svn: 80373
2009-08-28 16:14:46 +00:00
Nicolas Geoffray 43cce2294c Add a REQUIRES_FRAME_POINTER option to disable the frame pointer
elimination optimization on the LLVM code base.

llvm-svn: 79477
2009-08-19 22:04:44 +00:00
Eric Christopher d604b256d5 Add CXXFLAGS to the Link lines as well in case someone used those instead
of LDFLAGS.

llvm-svn: 79352
2009-08-18 18:07:35 +00:00
Eric Christopher 3fe6967b5d Separate out Makefile defines so that we can keep the llvm
defined ones from the user defined ones. Propagate accordingly.

llvm-svn: 79308
2009-08-18 03:23:40 +00:00
Anton Korobeynikov 90e17e787f The attached patches attempt to fix cross builds. For example, if you
try to use i686-darwin to build for arm-eabi, you'll quickly run into
several false assumptions that the target OS must be the same as the
host OS. These patches split $(OS) into $(HOST_OS) and $(TARGET_OS) to
help builds like "make check" and the test-suite able to cross
compile. Along the way a target of *-unknown-eabi is defined as
"Freestanding" so that TARGET_OS checks have something to work with.

Patch by Sandeep Patel!

llvm-svn: 79296
2009-08-18 00:40:33 +00:00
Misha Brukman 5906bc1059 Fixed indentation and spelling.
llvm-svn: 79245
2009-08-17 15:31:24 +00:00
Anton Korobeynikov 28381c05d4 Force reconfigure
llvm-svn: 79019
2009-08-14 18:53:19 +00:00
Daniel Dunbar d81866827c Add temporary hack to teach LLVM to reconfigure itself to pick up the new PIC16
AsmPrinter (in AsmPrinters.def).

llvm-svn: 78922
2009-08-13 17:22:49 +00:00
Anton Korobeynikov 1bb812e86b Add executable suffix for the tool. This is needed e.g. for 'make install' on mingw32.
llvm-svn: 78185
2009-08-05 09:37:43 +00:00
Daniel Dunbar 2841ea4749 Makefile rules for generating assembly matcher.
- Unused, fear not cmakers.

llvm-svn: 75483
2009-07-13 18:35:35 +00:00
Mikhail Glushenkov d6c39ae68c Add --enable-llvmc-dynamic configure option.
Controls whether libCompilerDriver should be loaded dynamically. By default this
is needed only on Win32, to make dynamic plugins work.

llvm-svn: 74759
2009-07-03 03:52:47 +00:00
Mikhail Glushenkov 72f3f7eb56 Make dynamic LLVMC plugins work on Windows (finally!).
Implemented by making lib/CompilerDriver a shared library that holds all the
global static data (CommandLine options, plugin registry) that we unfortunately
have to live with.

llvm-svn: 74417
2009-06-29 03:09:15 +00:00
Mikhail Glushenkov 73da626340 Remove duplication.
Factor out common preprocessor-related bits to Makefile.rules.

llvm-svn: 74153
2009-06-25 01:07:00 +00:00
Mikhail Glushenkov 248c414024 Make llvmc work again.
Chris recently broke llvmc with his Makefile changes (r75379). That patch made
the global change .o -> .a, which caused built-in llvmc plugins to stop working
since plugin initialization in llvmc is based on static variables not referenced
from the main executable. This patch implements auto-generated forced references
to the plugin libraries.

llvm-svn: 74000
2009-06-23 20:46:48 +00:00
Duncan Sands e532b557c4 Since -Wno-long-long is ignored without -pedantic,
place it with -pedantic.  Remove -Wunused since it
is implied by -Wall.  Group -Wno-unused-parameter
with -Wall -W since it is the combination of these
two that turns on -Wunused-parameter.

llvm-svn: 73765
2009-06-19 12:40:30 +00:00
Chris Lattner eaae8d0cdc Remove support for building LLVM libraries into "relinked"
object files.  Now we always build LLVM libraries into archives (.a files).

This makes the 'make' build work more like the cmake build, among other
things.  Doing this exposed some latent circular library dependencies, so
I think that llvm-config wasn't quite right for .o files anyway.

llvm-svn: 73579
2009-06-16 23:00:42 +00:00
Duncan Sands 8b9524eede On platforms like Sparc64 you need to pass -r to
gcc rather than directly to the linker: gcc will
then modify the linker options it generates (it
will not use --relax for example, incompatible
with -r, as it otherwise would).  This fixes the
sparc build.

llvm-svn: 72943
2009-06-05 15:05:19 +00:00
Torok Edwin 49db738833 For the new ar --plugin libLLVMgold.so to work we need libLTO linked with
pthreads, otherwise ar complains of unresolved references to pthread_mutex_*.
LTO doesn't actually use pthreads, but ManagedStatic does.

Fix this by linking in LIBS (that contains pthreads) for LTO and gold.
For now this links in more libs than needed (libffi for example), we can figure
out later how to link in those libs per-tool later.

llvm-svn: 72430
2009-05-26 19:11:47 +00:00
Jay Foad e609ab00a5 Work around the fact that GNU libstdc++'s debug mode uses RTTI.
llvm-svn: 71871
2009-05-15 18:13:31 +00:00
Daniel Dunbar 310511d429 Allow client Makefiles control over whether they want -pedantic by
defining NO_PEDANTIC.
  - Pedantic C89 is a painful language...

llvm-svn: 71545
2009-05-12 07:26:49 +00:00
Daniel Dunbar 8a28e011f4 Refactor dependency generation for .ll files.
- This matches the normal dependency generation code.

 - This also fixes the problem that when building a normal and bitcode
   archive from the same source, the dependency files would overwrite
   one another. Which was bad.

llvm-svn: 71542
2009-05-12 06:35:50 +00:00
Daniel Dunbar 583c5dcd76 Remove obsolete Makefile magic for calling llvm-upgrade
llvm-svn: 71540
2009-05-12 05:49:22 +00:00
Daniel Dunbar c25ba426bd Install bytecode libraries with a .bca suffix, otherwise it isn't
possible to build both a .a and a .bca.
 - My understanding is no one else is using this stuff, please let me
   know if I am wrong.

llvm-svn: 71539
2009-05-12 05:35:40 +00:00
Mike Stump d1b4636717 In non-pic builds, we can use -mdynamic-no-pic for a little more speed.
llvm-svn: 71281
2009-05-08 23:08:58 +00:00
Anton Korobeynikov 0a0cc2d7b7 Workaround libstdc++ bug when crosscompiling to mingw.
Patch by Jay Foad!

llvm-svn: 70849
2009-05-04 10:25:30 +00:00
Mikhail Glushenkov 2c332fec97 Support --with-llvmgccdir and friends in llvmc, take 2.
Should now work when building with objdir != srcdir and when llvm-gcc is not
available.

Thanks to Duncan Sands for testing and advice!

llvm-svn: 69700
2009-04-21 19:46:10 +00:00
Evan Cheng 5770950dbb No, we are not avoiding -O3, just -fstrict-aliasing.
llvm-svn: 69633
2009-04-20 22:49:59 +00:00
Evan Cheng 40c52322a7 One Mac OS X, just build with -O3 but without -fstrict-aliasing (which is kinda broken).
llvm-svn: 69630
2009-04-20 22:16:40 +00:00
David Greene 80f48bd13f Add a --enable-profiling option to configure to build Debug+Profile and
Opt+Profile tools.  Now we can profile any kind of flavor we build.

llvm-svn: 69351
2009-04-17 14:49:22 +00:00
Chris Lattner b4494eb887 move clang-specific makefile goop to clang makefile.
llvm-svn: 69206
2009-04-15 19:57:42 +00:00
Bill Wendling e8b48b49c9 Don't install the libLLVMHello.dylib example.
llvm-svn: 68807
2009-04-10 18:48:38 +00:00
Bill Wendling cd1e037c50 Add compatibility_version and current_version flags when creating dylibs.
llvm-svn: 68801
2009-04-10 18:20:41 +00:00
Bill Wendling f704f90f6e Revert r68708. It was causing this failure in the self-hosting buildbot:
llvm[2]: Compiling lto.cpp for Debug build  (PIC)
make[2]: *** No rule to make target `/Volumes/Sandbox/Buildbot/llvm/full-llvm/build/llvm.sh.build/Debug/lib/libLLVMBitWriter.a', needed by `/Volumes/Sandbox/Buildbot/llvm/full-llvm/build/llvm.sh.build/Release/lib/libLTO.dylib'.  Stop.
make[1]: *** [all] Error 1
make: *** [all] Error 1

llvm-svn: 68721
2009-04-09 18:26:57 +00:00
Misha Brukman a04ede8d5b Make sure to rebuild dependencies for the `check' and `unittests' targets so
we're not testing out-of-date code.  This also makes "make check" and
"make unittests" work out-of-the box right after the configure step, without
requiring the user to run "make tools-only" or "make libs-only".

Tested on Linux/x86_64 and Darwin/x86.

llvm-svn: 68708
2009-04-09 14:57:00 +00:00
Mike Stump 82d7cfda21 Avoid -O3 on Darwin for now.
llvm-svn: 68455
2009-04-06 19:58:11 +00:00
Julien Lerouge 15833b93cf Fix build on MacOS 10.4 systems (suggested by Mike Smith).
llvm-svn: 67855
2009-03-27 18:18:00 +00:00
Duncan Sands 99d0b2353e Revert previous change in favour of an explanatory
comment.

llvm-svn: 67833
2009-03-27 11:35:00 +00:00
Duncan Sands af7ae6ce3c A Release-Asserts build makes it sound like assertions
are turned on, while in fact they are turned off.  Name
this Release-NoAsserts instead.

llvm-svn: 67831
2009-03-27 09:41:56 +00:00
Evan Cheng 3138f7a781 Missed this as part of r67451.
llvm-svn: 67500
2009-03-23 03:45:56 +00:00
Bill Wendling a443ab4bcd Really should pass -dylib to the linker...
llvm-svn: 67469
2009-03-22 08:56:15 +00:00
Bill Wendling f3ef2c758f A dylib should be built as a dylib and not a bundle.
llvm-svn: 67468
2009-03-22 08:28:45 +00:00
Nick Lewycky 18ca80cdda Revert r67334 and r37349 which break "make check" on Linux.
llvm-svn: 67368
2009-03-20 07:56:31 +00:00
Evan Cheng 05799db963 More makefile changes to allow dejagnu tests to pass when system tools default to a different target from the llvm configuration (e.g. 64-bit gcc and 32-bit llvm).
llvm-svn: 67334
2009-03-19 20:27:23 +00:00
Sebastian Redl 6c2d55922f Fix Clang build for srcdir != objdir
llvm-svn: 67008
2009-03-14 14:42:51 +00:00
Sebastian Redl f2e58d6694 Add support for generating Clang diagnostic defs to Makefile.rules.
llvm-svn: 67006
2009-03-14 11:59:18 +00:00
Daniel Dunbar 5b86bf527e Add ENABLE_COVERAGE, for building a +Coverage (gcov) configuration.
- Required some extra makefile tweaks to introduce a new flag var
   which only goes to compile/link tools but not the relink step,
   otherwise we get a copy of libgcov in the relinked .o files.

 - No configure magic for this.

llvm-svn: 66945
2009-03-13 20:59:41 +00:00
Scott Michel b1a830abf0 Darwin 10.4.x: "-rpath" is unnecessary when linking shared libraries.
llvm-svn: 66825
2009-03-12 21:03:53 +00:00
Bill Wendling 207495d8ea Revert r66765 and r66766. These were causing build failures on Darwin.
llvm-svn: 66770
2009-03-12 04:10:09 +00:00
Nick Lewycky ca433d8a84 Set ARCH to x86 on mixed 32/64-bit Linux systems.
Remove the explicit if OS = Darwin test around the setting of -m32/-m64.

llvm-svn: 66765
2009-03-12 03:34:19 +00:00
Rafael Espindola 59e371ac96 Fix rebuilding after a .td file is modified. This was broken since revision
65834.

llvm-svn: 66553
2009-03-10 17:58:54 +00:00
Chris Lattner 869b6bfd0b don't pass -Wl,-exported_symbol -Wl,_main to the linker when building on
Tiger.  PR3743

llvm-svn: 66550
2009-03-10 17:15:56 +00:00
Evan Cheng 3807bb77fa Re-apply 66315, but restrict it to Darwin only.
llvm-svn: 66427
2009-03-09 18:28:37 +00:00
Chris Lattner 3b935fbcf2 Fix PR3743 - -mmacosx-version-min inappropriate for Mac OS X 10.4.11,
by stripping off any versions past the "10.4".

llvm-svn: 66392
2009-03-09 04:45:03 +00:00
Nick Lewycky f653c2e18e Revert r66315. Fix the build on mixed 64/32 Linux systems.
llvm-svn: 66350
2009-03-07 22:17:05 +00:00
Evan Cheng 9153f08c74 If ARCH is x86_64, pass -m64 to the host compiler. -m32 for i386. This makes sure the JIT work correctly.
llvm-svn: 66315
2009-03-07 01:40:17 +00:00
Daniel Dunbar 3b3c3f02cc Rename my makefile debugging rule to prevent accidental collisions.
llvm-svn: 66294
2009-03-06 22:23:25 +00:00
Mikhail Glushenkov ab6f8ded33 LINK_COMPONENTS should be added to LLVMLibsOptions.
From the code: "There are "Proj" libs (defined by the user's project) and "LLVM"
libs (defined by the LLVM project)." LINK_COMPONENTS are clearly defined by the
LLVM project.

Additionally, this fixes an issue with llvmc's build process:-)

llvm-svn: 65940
2009-03-03 10:03:27 +00:00
Nick Lewycky 7d01e394ba Switch to using -Wl,-R on Solaris.
llvm-svn: 65927
2009-03-03 04:55:15 +00:00
Nick Lewycky 9c51e8f962 Fix build on Cygwin.
llvm-svn: 65922
2009-03-03 03:36:50 +00:00
Mikhail Glushenkov c6333bdc50 Remove duplication in Makefile.rules.
Merge common bits from the LLVMC and TABLEGEN sections.

llvm-svn: 65834
2009-03-02 09:42:59 +00:00
Mikhail Glushenkov 7cff81825f Move the rules for building plugins to Makefile.rules.
llvm-svn: 65827
2009-03-02 09:04:13 +00:00
Chris Lattner 659ed19150 Fix universal builds to not use -XCClinker (a libtool thing) now that
libtool doesn't exist.

llvm-svn: 65561
2009-02-26 19:08:30 +00:00
Chris Lattner 75f9c4e4a1 no really, use the right path.
llvm-svn: 65554
2009-02-26 18:38:40 +00:00
Chris Lattner 8f9c4e67bb Search for the export map in a place that it can be found.
llvm-svn: 65552
2009-02-26 18:37:59 +00:00
Chris Lattner 0f19580996 strip exported symbols from tools that build with TOOL_NO_EXPORTS=1.
llvm-svn: 65543
2009-02-26 17:47:49 +00:00
Chris Lattner c1504647ee pass -mmacosx-version-min to the compiler and linker, which makes the build
substantially happier on some versions of Mac OS/X.

llvm-svn: 65542
2009-02-26 17:44:38 +00:00
Nick Lewycky b51813fc1c Fix typo.
llvm-svn: 65521
2009-02-26 08:48:14 +00:00
Nick Lewycky a0b8aaaad4 Fix typo!
llvm-svn: 65520
2009-02-26 08:03:36 +00:00
Nick Lewycky 28c62d211a Remove libtool.
llvm-svn: 65517
2009-02-26 07:44:16 +00:00
Daniel Dunbar 0094e341d0 Add makefile debugging target; use "make print-FOO" to print the
value/definition/origin of FOO.

llvm-svn: 65245
2009-02-21 20:42:39 +00:00
Nick Lewycky 9e5ed6d329 Pass different flags on different platforms when building PIC.
llvm-svn: 65229
2009-02-21 08:41:09 +00:00
Mike Stump 35f423e09e Avoid order files for now, as they aren't supported in 3.79.
llvm-svn: 64412
2009-02-12 23:45:11 +00:00
Dale Johannesen b842d529a3 Reapply 63765. Patches for clang and llvm-gcc to follow.
llvm-svn: 63812
2009-02-05 01:49:45 +00:00
Dale Johannesen ae616c2c61 Reverting 63765. This broke the build of both clang
and llvm-gcc.

llvm-svn: 63786
2009-02-04 22:47:25 +00:00
Nate Begeman 6ae3aa83d0 New feature: add support for target intrinsics being defined in the
target directories themselves.  This also means that VMCore no longer
needs to know about every target's list of intrinsics.  Future work
will include converting the PowerPC target to this interface as an
example implementation.

llvm-svn: 63765
2009-02-04 19:47:21 +00:00
Mike Stump 82221d62a9 Perform optional clang building.
llvm-svn: 62895
2009-01-24 00:00:41 +00:00
Mike Stump f7a16e9380 Don't create .dir files in installation directories. Switch to using
order-only dependancies for installation directories.

llvm-svn: 62746
2009-01-22 03:24:22 +00:00
Mikhail Glushenkov 726440dbc9 Support llvmc plugins in out-of-tree projects.
llvm-svn: 61990
2009-01-09 16:31:01 +00:00
Misha Brukman 2879c29274 Removed trailing whitespace.
llvm-svn: 61904
2009-01-08 02:11:55 +00:00
Bill Wendling 8790e3260d Modify the unittests Makefiles so that they don't rebuild parts of LLVM just to
run the tests. Most of this was stolen from the llvm/test Makefiles.

llvm-svn: 61648
2009-01-04 23:12:21 +00:00
Bill Wendling b2f724edb4 Revert r61598 as it does nothing.
llvm-svn: 61614
2009-01-03 22:46:50 +00:00
Bill Wendling cea11dbf6e Make sure that 'ranlib' runs only after 'ar' is completed.
llvm-svn: 61598
2009-01-03 01:11:39 +00:00
Chris Lattner 814d9eec97 Remove lex/bison support from makefile.rules.
llvm-svn: 61562
2009-01-02 07:16:45 +00:00
Bill Wendling ea58ff5a8a Don't error out if ranlib fails.
llvm-svn: 61551
2009-01-02 02:53:24 +00:00
Duncan Sands 445071c44f Fix PR3117: not all nodes being legalized. The
essential problem was that the DAG can contain
random unused nodes which were never analyzed.
When remapping a value of a node being processed,
such a node may become used and need to be analyzed;
however due to operands being transformed during
analysis the node may morph into a different one.
Users of the morphing node need to be updated, and
this wasn't happening.  While there I added a bunch
of documentation and sanity checks, so I (or some
other poor soul) won't have to scratch their head
over this stuff so long trying to remember how it
was all supposed to work next time some obscure
problem pops up!  The extra sanity checking exposed
a few places where invariants weren't being preserved,
so those are fixed too.  Since some of the sanity
checking is expensive, I added a flag to turn it
on.  It is also turned on when building with
ENABLE_EXPENSIVE_CHECKS=1.

llvm-svn: 60797
2008-12-09 21:33:20 +00:00
Evan Cheng 977e7be9d4 Move target independent td files from lib/Target/ to include/llvm/Target so they can be distributed along with the header files.
llvm-svn: 59953
2008-11-24 07:34:46 +00:00
Anton Korobeynikov 8e58c52b37 Proper way of doing llvm canadian-cross compilation.
Patch by Jim Grosbach!

llvm-svn: 58981
2008-11-10 07:33:13 +00:00
Daniel Dunbar d395a1722d Comment fix.
llvm-svn: 58621
2008-11-03 17:33:36 +00:00
Dan Gohman ca0546facc Fun x86 encoding tricks: when adding an immediate value of 128,
use a SUB instruction instead of an ADD, because -128 can be
encoded in an 8-bit signed immediate field, while +128 can't be.
This avoids the need for a 32-bit immediate field in this case.

A similar optimization applies to 64-bit adds with 0x80000000,
with the 32-bit signed immediate field.

To support this, teach tablegen how to handle 64-bit constants.

llvm-svn: 57663
2008-10-17 01:33:43 +00:00
Daniel Dunbar 4b928f6550 Another dependency fix, prevent ObjDir from having trailing slash.
- It turns out this is enough to completely break dependency file
   (.d) usage (at least for my gmake).

llvm-svn: 57030
2008-10-03 21:24:52 +00:00
Daniel Dunbar 78caa02ef4 Add IS_CLEANING_TARGET Makefile variable.
- Fixes bug in dependency inclusions where make with unspecified
   target wouldn't include dependency files, eek!

llvm-svn: 57026
2008-10-03 19:11:19 +00:00
Jim Grosbach 009db89513 Add support for Canadian Cross builds where the host executables are not
runnable on the build machine.

There are a few bits that need built for the build environment (TableGen).
This patch builds those bits, and the associated libraries, for the build
environment as well as the (usual) host environment.

Thanks to Eric C. and Devang P. for pre-commit review.

llvm-svn: 56975
2008-10-02 22:56:44 +00:00
Daniel Dunbar 61e0a821cc Reapply majority of r55557 but with the changes to compilation flags
disabled until issues with gcc 4.1 on linux 32-bit are resolved.

llvm-svn: 55636
2008-09-02 17:35:16 +00:00
Matthijs Kooijman 7b704a502b Revert r55557, it is causing linking failures on 32bit linux.
llvm-svn: 55628
2008-09-02 09:51:00 +00:00
Daniel Dunbar 8eec985ac7 Enable -fvisibility-inlines-hidden by default for compilers which
support it.

llvm-svn: 55557
2008-08-30 01:16:19 +00:00
Gabor Greif 2dd54ed593 fix the output dumbness I have introduced some time ago
llvm-svn: 55506
2008-08-28 22:32:39 +00:00
Dan Gohman b2226e21c3 Initial checkin of the new "fast" instruction selection support. See
the comments in FastISelEmitter.cpp for details on what this is.
This is currently experimental and unusable.

llvm-svn: 54751
2008-08-13 20:19:35 +00:00
Chris Lattner 01602a18a9 Add support for building on solaris, working around namespace
polution problems from system headers.  Patch by Nathan Keynes!

llvm-svn: 52682
2008-06-24 17:44:42 +00:00
Evan Cheng c7007a7211 Warn of potential violations of strict aliasing rules.
llvm-svn: 52027
2008-06-05 23:00:08 +00:00
Evan Cheng 215c528565 Revert 51775.
llvm-svn: 51795
2008-05-30 22:47:19 +00:00
Evan Cheng a50833b695 Patches for building llvm on Solaris x86. Contributed by Nathan Keynes.
llvm-svn: 51775
2008-05-30 17:16:20 +00:00
Gabor Greif 697e94cc22 Fix a bunch of 80col violations that arose from the Create API change. Tweak makefile targets to find these better.
llvm-svn: 51143
2008-05-15 10:04:30 +00:00
Gordon Henriksen 04e38cf30a Refresh Makefile.ocaml in objdir if it is modified in srcdir.
Patch by Erick Tryzelaar!

llvm-svn: 48149
2008-03-10 15:58:40 +00:00
Gabor Greif c848f9ea4e Remove inappropriate whitespace, change CVS to SVN where it makes sense.
llvm-svn: 47671
2008-02-27 13:34:15 +00:00
Andrew Lenharth dddb68c63a when making bytecode modules, link as library
llvm-svn: 47574
2008-02-25 22:41:55 +00:00
Chris Lattner 42e35d4fcc Make the check for GCC version more robust, fix shared library
dependencies in makefile, and fix llvm_cv_no_link_all_option
on darwin.

Patch by Shantonu Sen, more info here:
http://lists.cs.uiuc.edu/pipermail/llvmdev/2008-February/012410.html

llvm-svn: 46760
2008-02-05 19:43:40 +00:00
Duncan Sands 9f6f4d39f7 Unbreak builds with differing object and source
directories.  Patch by Sam Bishop.

llvm-svn: 46453
2008-01-28 17:38:30 +00:00
Chris Lattner 6379fc68ff reduce duplicate -I flags passed to the compiler, cleaning up the VERBOSE
output.  Patch contributed by Sam Bishop!

llvm-svn: 46432
2008-01-28 04:18:41 +00:00
Chris Lattner efc922d089 One too many )'s breaks 'make clean' with certain versions of make.
This fixes PR1927

This should be pulled into llvm 2.2.

llvm-svn: 46245
2008-01-22 05:19:26 +00:00
Chris Lattner 5047536879 Commit a piece that I missed before, patch by Alain Frisch
llvm-svn: 46032
2008-01-15 23:27:40 +00:00
Gordon Henriksen db911e9037 Modify Makefile.rules to allow makefiles to prepend to C.Flags and
fiends. Change Makefile.ocaml to not touch CFLAGS.

llvm-svn: 45663
2008-01-06 21:54:35 +00:00
Chris Lattner c23e6351de Factor out makefile dependency generation better.
Don't include system headers in the .d files.
Don't use $@ in the makefile rules, as there are two possible targets it could resolve to: use the one that we need explicitly.

llvm-svn: 45473
2007-12-31 23:58:31 +00:00
Chris Lattner 11cc8b3c14 remove attributions from the rest of the llvm makefiles.
llvm-svn: 45416
2007-12-29 20:11:13 +00:00
Chris Lattner d0382a8550 noone uses etags. Connected to PR1601
llvm-svn: 42344
2007-09-26 06:10:47 +00:00
Reid Spencer fcd7815249 Restore ability to build archives (oops)
Fix -include line so it doesn't reference /dev/null

llvm-svn: 40429
2007-07-23 08:20:46 +00:00
Reid Spencer 63ebdf7994 Remove bizarre use of /dev/null in a makefile include line that
produces warning from make about bad timestamp on /dev/null

Patch by Holger Schurig.

llvm-svn: 40426
2007-07-23 08:09:15 +00:00
Reid Spencer bca0811462 Make sure to keep symbols for profile build.
Patch by Benoit Boissinot. Thanks, Benoit!

llvm-svn: 38490
2007-07-10 14:52:01 +00:00
Reid Spencer fd8e641c1e Make sure that preprocessor symbols like _DEBUG, NDEBUG, and _GLIBC_DEBUG are
put into the CPP.Defines variable. Seems the convention was corrupted with
various changes made. It is important to get command line parameters into the
right variable because things like llvm-config and sub-makefiles depend on it.

llvm-svn: 38486
2007-07-10 07:19:53 +00:00
Reid Spencer 7214cfdf66 Add a missing .
llvm-svn: 37800
2007-06-29 14:02:07 +00:00
David Greene 869e4b5dac Clean up comments to be consistent with code.
llvm-svn: 37798
2007-06-29 03:36:21 +00:00
David Greene cbc8ddf81a Add support for building with _GLIBCXX_DEBUG. New configure option
--enable-expensive-checks allows the developer to enable runtime
checking that can greatly increase compile time.  Currently it only
turns on _GLIBCXX_DEBUG.  Other expensive debugging checks added later
should be controlled by this configure option.

This patch also updates llvm-config with a --cppflags option to inform
llvm-gcc how to build itself so that it is compatible with an llvm that
was built with _GLIBCXX_DEBUG.

llvm-svn: 37777
2007-06-28 19:36:08 +00:00
Reid Spencer 07aa66887c Fix a problem with building .y files when BISON is not present.
Merged from the release_20 branch.

llvm-svn: 37188
2007-05-17 22:51:35 +00:00
Reid Spencer 700a0381b5 Disable RTTI handling until we're ready.
llvm-svn: 36651
2007-05-02 21:31:09 +00:00
Reid Spencer e6bc20629d Add a rule to get the footprint of binaries and libraries.
llvm-svn: 36650
2007-05-02 21:29:39 +00:00
Anton Korobeynikov fb80151c42 Removed tabs everywhere except autogenerated & external files. Add make
target for tabs checking.

llvm-svn: 36146
2007-04-16 18:10:23 +00:00
Chris Lattner f8adf7af88 add a target to print out 80-column violations.
llvm-svn: 36032
2007-04-14 23:35:45 +00:00
Reid Spencer c82c2cf483 Speed up installation a bit by ignoring .svn directories.
Patch by Scott Michel.

llvm-svn: 35826
2007-04-09 19:08:58 +00:00
Reid Spencer 200c6f9c3d For PR789:
Make the sys::Path::getFileStatus function more efficient by having it
return a pointer to the FileStatus structure rather than copy it. Adjust
uses of the function accordingly. Also, fix some memory issues in sys::Path.

llvm-svn: 35476
2007-03-29 19:05:44 +00:00
Chris Lattner 0706d8496c correct dependency
llvm-svn: 34723
2007-02-28 05:10:40 +00:00
Chris Lattner ee0fe3be68 target for generating CC info
llvm-svn: 34683
2007-02-27 20:44:12 +00:00
Reid Spencer 7cec4f2e8a Fix some bugs in module building that broke llvm-stacker project.
llvm-svn: 34099
2007-02-09 17:09:14 +00:00
Reid Spencer b63d0c4ad2 Don't use gccld or gccas
llvm-svn: 34093
2007-02-09 15:52:07 +00:00
Reid Spencer 48c74391c4 Make the cleaning of BUILT_SOURCES be a "clean-all" target item, not a
"clean" target item. This gets around having the built sources disappear
when only one build mode wants to be cleaned. With the "clean-all" target,
all build modes are cleaned so it also makes sense to clean out the built
sources at that point.

llvm-svn: 34003
2007-02-07 19:13:19 +00:00
Reid Spencer 960cf7c929 Remove a spurious ;
llvm-svn: 33976
2007-02-07 03:29:29 +00:00
Reid Spencer a79819d8c6 Implement the NO_INSTALL feature. Setting this variable to any value in
a directory's Makefile will prevent the build products from that directory
from being installed. This is useful for tools and libraries that are
only useful as part of the build process.

llvm-svn: 33968
2007-02-06 18:53:14 +00:00
Reid Spencer 1e86e65b83 When using LINK_COMPONENTS, append the components to the end of the
libraries linked with. This permits a project to still use USEDLIBS to
specify its own libraries in conjunction with LINK_COMPONENTS. llvm-stacker
needs this after libLLVMTransforms.a went away.

llvm-svn: 33886
2007-02-04 22:12:25 +00:00
Andrew Lenharth 0ad67b0e43 Work around broken binutils on alpha
llvm-svn: 33535
2007-01-26 13:34:50 +00:00
Reid Spencer 582db976d8 Don't remove the find_rule label from FLEX output. It is needed by some
versions of FLEX even through we don't use REJECT. Thanks to Jeff Cohen
for tracking this down.

llvm-svn: 33085
2007-01-11 21:40:25 +00:00
Reid Spencer b8f3fe8ec5 Remove the find_rule label from the output of flex. This will break any
use of the REJECT macro but we don't use it. This just hushes up a warning
in the presence of -Wno-unused.

llvm-svn: 32843
2007-01-03 19:56:14 +00:00
Reid Spencer 96edbd5c07 When compiling a C or C++ file to assembly, make the assembly output
depend on the compiler. This works around problems in the Stacker runtime
when the CFE changes in such a way that the assembly file needs to be
updated.

llvm-svn: 32773
2006-12-30 16:31:02 +00:00
Reid Spencer 05a1fe5bf5 Allow an --enable-pic option to turn on -fPIC compiler option when building.
The default is disabled until we know this doesn't break anyone.

llvm-svn: 32635
2006-12-16 22:07:52 +00:00
Reid Spencer bef61c5781 Don't bother with setting the path before running llvm-gcc4, it doesn't
need it like llvm-gcc3 did.

llvm-svn: 32410
2006-12-10 04:56:38 +00:00
Reid Spencer 3c3fed62bf Remove line not meant to be committed.
llvm-svn: 32163
2006-12-03 21:17:12 +00:00
Reid Spencer 9a6fc825b4 Handle upgrade of llvm-gcc3 assembly files.
llvm-svn: 32161
2006-12-03 21:01:45 +00:00
Reid Spencer 4b8067f37b Undo removal of the runtime libraries. While this may have been a bit
premature, these libraries will be going away for the 2.0 release. Other
arrangements for profiling, gc, etc. should be made in the next few months.

llvm-svn: 31807
2006-11-17 03:32:33 +00:00
Reid Spencer 3f97d03f86 In LLVM 2.0 we won't use the runtime libraries as llvm-gcc3 support will
be dropped. This patch pertains to removing the runtime directory from LLVM.

llvm-svn: 31793
2006-11-16 23:17:27 +00:00
Chris Lattner 7cab3de0da Fix typo pointed out by Bryan Adams
llvm-svn: 31766
2006-11-15 21:04:15 +00:00
Reid Spencer d185c02007 Allow ENABLE_OPTIMIZED=0 to turn off optimization (turn on debug).
llvm-svn: 31655
2006-11-11 00:00:31 +00:00
Reid Spencer de46e48420 For PR786:
Turn on -Wunused and -Wno-unused-parameter. Clean up most of the resulting
fall out by removing unused variables. Remaining warnings have to do with
unused functions (I didn't want to delete code without review) and unused
variables in generated code. Maintainers should clean up the remaining
issues when they see them. All changes pass DejaGnu tests and Olden.

llvm-svn: 31380
2006-11-02 20:25:50 +00:00
Chris Lattner 3becc6b0d5 Targets should depend on all the intrinsics.td files also, otherwise they
will compute a locally wrong numbering for the intrinsics.  This fixes a
nasty issue where the x86 backend started miscompiling stuff in a 'cvs up'd
build after the altivec intrinsics were added.

llvm-svn: 31172
2006-10-24 20:32:44 +00:00
Chris Lattner 008b2de1fc Move CompileCommonOpts to the end of the list so that EXTRA_OPTIONS=-O0 will
override the optimization level.

llvm-svn: 30672
2006-09-29 18:47:13 +00:00
Chris Lattner a5d27b19e1 Fix a build problem
llvm-svn: 30096
2006-09-04 06:39:52 +00:00
Chris Lattner 79baf1ee7c Remove some dead makefilery
llvm-svn: 30093
2006-09-04 06:07:12 +00:00
Chris Lattner 68c9754e76 Bugfix for llvm-config support
llvm-svn: 30087
2006-09-04 05:23:20 +00:00
Chris Lattner 9a4a92e829 Make LINK_COMPONENTS interact well with make clean
llvm-svn: 30086
2006-09-04 04:50:10 +00:00
Chris Lattner f9ac33d8ed Add a new make option (LINK_COMPONENTS) which tools can use to specify what
libraries they need.  This uses llvm-config to link the tools.

llvm-svn: 30084
2006-09-04 04:47:21 +00:00
Chris Lattner de54ffc225 Rearrange library linkage order.
llvm-svn: 30074
2006-09-04 01:02:25 +00:00
Reid Spencer e7141c8be6 For PR387:
Close out this long standing bug by removing the remaining overloaded
virtual functions in LLVM. The -Woverloaded-virtual option is now turned on.

llvm-svn: 29934
2006-08-28 01:02:49 +00:00
Reid Spencer 0b6396c6b3 Doh! Commit the change that turns ON -fno-exceptions.
llvm-svn: 29883
2006-08-25 20:56:59 +00:00
Reid Spencer 51e6f68b47 For PR797:
Final commit for this bug. This removes the last EH holdouts in LLVM
and turns off exception support by using the -fno-exceptions option. This
leads to the following reduction in library and executable sizes:
                DEBUG BUILD                RELEASE BUILD
         before     after   delta     before   after    delta
lib    162,328K  157,616K   4,712    17,864K  16,416K  1,448K
bin    571,444K  557,156K  14,288    63,296K   56,996K 6,300K

Debug   Improvement: 19,000K (2.59%)
Release Improvement:  7,748K (9.55%)

llvm-svn: 29882
2006-08-25 19:54:53 +00:00
Reid Spencer 917cf12928 For PR738:
Demote check for bison from error to warning and make sure that the
makefile can handle an empty definition for BISON variable.

llvm-svn: 29861
2006-08-24 22:41:20 +00:00
Reid Spencer 27665c1331 To avoid errors where a non-exception .o is on the stack between a throw
and a handler, which would produce errors like:
  terminate called after throwing an instance of 'std::string'
we must comment out setting -fno-exceptions until PR797 is completely
fixed. Once libraries like lib/System and lib/Support are exception free,
we can turn it back on.

llvm-svn: 29768
2006-08-18 17:22:07 +00:00
Reid Spencer 7c9ec5ff37 For PR797:
1. Actually turn on -fno-exceptions in libraries that do not have the
   REQUIRES_EH option in their Makefile. The following library file size
   savings were made (DEBUG):
      libLLVMDataStructure.a  525K
      libLLVMCore.a           380K
      libLLVMCodeGen.a        350K
      libLLVMTransformUtils.a 305K
      libLLVMScalarOpts.a     270K
      libLLVMAnalysis.a       247K
      libLLVMSelectionDAG.a   233K
      libLLVMipo.a            175K
      LLVMX86.o               123K
      LLVMPPC.o                81K
      libLLVMipa.a             17K
                 TOTAL      2,706K
      Note that the savings is actually a little larger than this because
      I didn't count any of the libraries that had small changes.

2. Remove REQUIRES_EH from the AsmParser library as it is now exception
   free. This resulted in a nearly 78K drop in the size of the debug
   library for AsmParser.

llvm-svn: 29767
2006-08-18 09:30:03 +00:00
Reid Spencer e6458c3fb2 For PR780:
1. Change the usage of LOADABLE_MODULE so that it implies all the things
   necessary to make a loadable module. This reduces the user's burdern to
   get a loadable module correctly built.
2. Document the usage of LOADABLE_MODULE in the MakefileGuide
3. Adjust the makefile for lib/Transforms/Hello to use the new specification
   for building loadable modules
4. Adjust the sample project to not attempt to build a shared library for
   its little library. This was just wasteful and not instructive at all.

llvm-svn: 29551
2006-08-07 23:12:15 +00:00
Chris Lattner dc5a8963c1 Pass -fstrict-aliasing to the compiler when building a release build on darwin.
Darwin doesn't default to it being on.

llvm-svn: 29350
2006-07-27 18:19:51 +00:00
Reid Spencer 0aa9d00ba0 For PR814:
Provide support for making cross-compiling builds. See the PR for details.
Patch provided by Anton Korobeynikov. Thanks, Anton!

llvm-svn: 29309
2006-07-26 21:14:56 +00:00
Chris Lattner b92596114b Reduce work done for directory traversal in srcdir==objdir builds.
llvm-svn: 29300
2006-07-26 20:22:26 +00:00
Evan Cheng 83c56aa220 Workaround no longer needed.
llvm-svn: 29260
2006-07-21 23:06:51 +00:00
Devang Patel 2c15c01c19 Fix MacOSX build failures. (pr841)
llvm-svn: 29246
2006-07-21 19:44:55 +00:00
Chris Lattner 55782c6c41 Build more debugger/selectiondag libraries as archives instead of .o files.
This works around bugs in some versions of the cygwin linker.

Patch contributed by Anton Korobeynikov.

llvm-svn: 29239
2006-07-21 00:10:47 +00:00
Andrew Lenharth 2b0baddc33 Fix linking on Alpha
llvm-svn: 29219
2006-07-20 17:27:58 +00:00
Chris Lattner 4a48245919 Profile builds should always have debug info enabled.
llvm-svn: 29109
2006-07-11 18:33:50 +00:00
Chris Lattner 65e28b3186 Allow specifying an explicit list of architectures to build for, e.g.:
make ENABLE_OPTIMIZED=1 UNIVERSAL=1 UNIVERSAL_ARCH="i386 ppc ppc64"

retain the default of building for just i386/ppc.

llvm-svn: 28985
2006-06-29 19:38:04 +00:00
Chris Lattner 161a84ebeb Add targets for generating .s file in addition to .o files.
llvm-svn: 28903
2006-06-21 21:01:20 +00:00
Chris Lattner 085c7153da Factor a bunch of rules together, no functionality change.
llvm-svn: 28902
2006-06-21 20:58:03 +00:00
Evan Cheng 9e7e4b5d85 Allow LLVM to be built with extra options.
llvm-svn: 28873
2006-06-20 18:50:48 +00:00
Chris Lattner 64e85f309f Do not hardcode random paths into the makefile. Make the user specify the
SDK to use when building "universal" on Mac OS/X, if they want to use a
specific one.

llvm-svn: 28842
2006-06-16 21:47:59 +00:00
Chris Lattner 3743bd84cd Fix building on case-sensitive file systems, grr :)
llvm-svn: 28801
2006-06-15 17:31:22 +00:00
Chris Lattner 4d1eeb48e0 Remove obsolete CORE_IS_ARCHIVE stuff.
llvm-svn: 28648
2006-06-02 00:27:42 +00:00
Reid Spencer 187b4adcfe Provide configuration support and usage for MINGW32 platform
llvm-svn: 28639
2006-06-01 19:03:21 +00:00
Reid Spencer a62f097c96 For PR786:
Turn -pedantic and -Wno-long-long compile flags on by default. In a few
places, avoid the warnings by removing these options in the local makefile.
One notable exception: lib/Target/CBackend/Writer.cpp. These warnings are
left on as a reminder to developers to clean them up.

llvm-svn: 28614
2006-06-01 01:55:21 +00:00
Reid Spencer a647c7ff42 Use archive libraries instead of object files for VMCore, BCReader,
BCWriter, and bzip2 libraries. Adjust the various makefiles to accommodate
these changes. This was done to speed up link times.

llvm-svn: 28610
2006-06-01 01:30:27 +00:00
Chris Lattner 11c25cfa13 Enable -fno-use-cxa-atexit on darwin/ppc also.
llvm-svn: 28558
2006-05-30 16:38:06 +00:00
Chris Lattner 213a85b43c Abstract out the current optimization level into a flag that can be overridden
on the make line, to avoid bugs in native compilers.

llvm-svn: 28457
2006-05-24 23:02:40 +00:00
Chris Lattner d36c0fdf2e Remove flags implied by -O3
llvm-svn: 28456
2006-05-24 22:59:07 +00:00
Chris Lattner 040c110569 Don't use -fomit-frame-pointer on darwin, it breaks stacktrace collection.
llvm-svn: 28451
2006-05-24 18:34:08 +00:00
Reid Spencer a22a5b382f Make some changes suggested by Chris:
1. Remove the LLVM_DO_NOT_BUILD feature (not needed any more)
2. Ensure that lib/VMCore gets built first. This needs to be done because
   VMCore now uses tblgen to generate the Intrinsics header which are
   needed in other libraries. In parallel builds, this can cause problems.

llvm-svn: 28374
2006-05-17 22:55:35 +00:00
Reid Spencer 540c1b95f1 Make sure that $(CXX.Flags) is passed to the linker so that the same options
with which source is compiled are used when linking. This matters when a
project is using the LLVM makefiles and overrides CXXFLAGS to specify new
flags to use.

llvm-svn: 28322
2006-05-16 06:51:02 +00:00
Vladimir Prus 788db2c812 Replace "../whatever.td" with "whatever.td", so that out-of-tree backends
can just add lib/Target to TableGen includes.

llvm-svn: 28318
2006-05-16 06:39:36 +00:00
Reid Spencer 1053658517 When linking, make sure the project libraries are linked before the LLVM
libraries. This ensures that the project's libraries (which most likely
depend on LLVM libraries) come first on the command line and can thus be
resolved by the LLVM libraries that appear later.

llvm-svn: 28316
2006-05-16 06:25:14 +00:00
Owen Anderson 68afff2dcd Fix some problems linking stuff in libTarget.
llvm-svn: 28218
2006-05-11 03:10:15 +00:00
Reid Spencer 9597684ba7 Remove traces of Burg utility now that its gone and not needed.
llvm-svn: 27902
2006-04-20 18:42:24 +00:00
Chris Lattner d5737be0f0 Remove V9 jit support
llvm-svn: 27891
2006-04-20 17:52:00 +00:00
Chris Lattner f2f4aedc6e Final piece to get relinked .o files buildable universal on Darwin.
llvm-svn: 27839
2006-04-19 18:45:29 +00:00
Reid Spencer 78ede56ed0 Make sure that the C Frontend's runtime library directory is included as
a -L option to gccld whenever we're building a bytecode module or archive.
This gets around the "Cannot find library 'crtend'" warning messages.

llvm-svn: 27621
2006-04-12 18:21:35 +00:00
Reid Spencer ca4abfe3db Remove extraneous building in target dist-check. There is no reason that
a distribution should need to be able to make a distribution so eliminate
the "make dist" from the list of targets attempted.

llvm-svn: 27600
2006-04-12 03:07:02 +00:00
Reid Spencer 15b8509c11 ENABLE_ASSERTIONS -> DISABLE_ASSERTIONS
llvm-svn: 27558
2006-04-10 16:46:04 +00:00
Reid Spencer ece1358c80 Check for DISABLE_ASSERTIONS, not ENABLE_ASSERTIONS
llvm-svn: 27552
2006-04-09 23:41:14 +00:00
Reid Spencer 056f022569 For PR723:
1. Don't force debug builds to have assertion checking turned on always.
   Let the default (on) be taken, or overridden by the command line
2. Create two new BuildModes based on assertion checking: Release+Assert
   and Debug-Assert.
3. Ensure that when building a distribution we get a release build with
   assertions enabled, regardless of the tree's configuration.
4. (unrelated) Fix library name generation for llvm-config usage.

llvm-svn: 27488
2006-04-07 16:06:18 +00:00
Evan Cheng bb66ec263c A saner workaround. I hope.
llvm-svn: 27483
2006-04-07 08:31:56 +00:00
Evan Cheng 1e86e679a5 Temporary workaround for a Mac OSX specific issue.
llvm-svn: 27482
2006-04-07 08:10:09 +00:00
Chris Lattner d81eba56d7 Add support for building the LLVM libraries and tools as a Mac OS/X
universal binary, by specifying UNIVERSAL=1 on the make command line.

llvm-svn: 27447
2006-04-06 06:30:15 +00:00
Reid Spencer d813b95fc3 Add a facility for invoking the llvm-config tool when linking a program.
This facility allows LLVMLIBS to be specified with something like:
LLVMLIBS = config --libs jit
instead of:
LLVMLIBS = JIT
with the same effect. However, the llvm-config utility is much more versatile
than the single keyword approach. Note that "config" is the keyword after
which any arguments to llvm-config are allowed. When llvm-config is tested
and working well, we'll start using this and drop support for the JIT
keyword.

llvm-svn: 27057
2006-03-24 07:36:57 +00:00
Reid Spencer 6f682b79af These changes are necessary to support the new llvm-config tool. llvm-config
is a handy tool for users of LLVM who want to be able to quickly get
information about LLVM's configuration. It is intended to be used in the
command line of other tools. Documentation will be forthcoming in a
subsequent patch.

llvm-svn: 26952
2006-03-22 15:59:55 +00:00
Chris Lattner 98c79c34ef Enable assertions to be enabled in release builds by building with
make ENABLE_OPTIMIZED=1 ENABLE_ASSERTIONS=1

llvm-svn: 26914
2006-03-21 01:06:41 +00:00
Chris Lattner 35ac761341 reorder these to make it work with static libraries
llvm-svn: 26698
2006-03-10 21:01:34 +00:00
Chris Lattner 5b59d7cb11 Use $(Verb) instead of @ so that VERBOSE=1 will print these.
llvm-svn: 26626
2006-03-09 06:00:05 +00:00
Chris Lattner 8a87f5fb18 pass -Illvm/include to tblgen
llvm-svn: 26489
2006-03-03 01:54:54 +00:00
Chris Lattner c1fa889cde 8 spaces -> tab. Reported by Wink Saville
llvm-svn: 26425
2006-02-28 19:12:58 +00:00
Chris Lattner 1e6128254c Fix a minor makefile bug with lex/yacc handling that nate noticed. We don't
want to copy the files when the .cpp file changes, we want to copy them
to the .cvs versions when the .l/.y file change (like the comments even say).
This avoids having bogus changes show up in diffs.

llvm-svn: 26229
2006-02-16 05:10:48 +00:00
Chris Lattner b0240b2f4a bugfixes
llvm-svn: 26207
2006-02-15 07:23:05 +00:00
Chris Lattner c38a9755f1 Convert the bison-output-checked-into-cvs makefile handling stuff to work
like the flex stuff, which actually works when people do cvs updates and
get conflicts in the updated checked in file.

llvm-svn: 26205
2006-02-15 07:16:57 +00:00
Duraid Madina cbbc184a2e HP aCC (and a bunch of other compilers, no doubt) don't share
GCC's syntax for auto-dependency generation stuff. This should
be changed to be disabling dependency stuff unless GCC/ICC is
found.

llvm-svn: 26201
2006-02-15 03:23:26 +00:00
Duraid Madina 1f898afd3d oops, I meant this
llvm-svn: 26200
2006-02-15 03:20:16 +00:00