Commit Graph

794 Commits

Author SHA1 Message Date
Eric Christopher 5a30e0328b We're actually -Wmissing-field-initializers clean thanks to the cmake
build so check and turn on -Wmissing-field-initializers. While there,
reorganize the conditional warning code based on compiler to be a bit
more obvious and inside a switch statement.

llvm-svn: 244330
2015-08-07 16:44:47 +00:00
Eric Christopher 56d00fee88 Add support for SunOS function/data sections and associated
section gc.

Patch by Bill Rushmore.

llvm-svn: 231128
2015-03-03 20:54:29 +00:00
Eric Christopher 65ec83b09f Add a check for misbehaving -Wcomment from gcc-4.7 and add
-Wno-comment to the compilation flags if so.

Patch by Filipe Cabecinhas, configure regenerated by me.

llvm-svn: 221323
2014-11-05 00:35:15 +00:00
Eric Christopher abc1297a70 Revert my earlier change to add "all" as a dependency to check. In
retrospect it really wasn't a good idea.

llvm-svn: 218136
2014-09-19 18:44:27 +00:00
David Blaikie 9db82cf45d Disable GCC's -Woverloaded-virtual in the configure+make build. Clang's is better.
Turns out Clang's -Woverloaded-virtual is enabled by -Wall in both CMake
and Configure builds. We were only explicitly specifying it (thus
enabling GCC's version of the warning) in the Configure build.

The specific case of interest is:

  struct base {
    virtual void func();
    virtual void func(int);
  };
  struct derived: base {
    virtual void func(); // GCC warns here, because this causes
                         // func(int) to be hidden
  };

I don't think that's worth getting fussed about (& Clang (indirectly
me... since I improved this warning in Clang) agrees or we would've made
the warning catch these cases.

Technically this could still lead to bugs/confusion if base had
func(int) and func(bool), derived overrode func(bool) and then a caller
with a derived object tried to call func(42) - it would silently call
func(bool). We should probably improve clang's warnings to catch this at
the call site at some point.

llvm-svn: 218059
2014-09-18 16:34:25 +00:00
Eric Christopher 79cc1e3ae7 Reinstate "Nuke the old JIT."
Approved by Jim Grosbach, Lang Hames, Rafael Espindola.

This reinstates commits r215111, 215115, 215116, 215117, 215136.

llvm-svn: 216982
2014-09-02 22:28:02 +00:00
Rafael Espindola 36d3ee7c32 Delete support for AuroraUX.
auroraux.org is not resolving.

I will add this to the release notes as soon as I figure out where to put the
3.6 release notes :-)

llvm-svn: 215645
2014-08-14 15:15:09 +00:00
Eric Christopher b9fd9ed37e Temporarily Revert "Nuke the old JIT." as it's not quite ready to
be deleted. This will be reapplied as soon as possible and before
the 3.6 branch date at any rate.

Approved by Jim Grosbach, Lang Hames, Rafael Espindola.

This reverts commits r215111, 215115, 215116, 215117, 215136.

llvm-svn: 215154
2014-08-07 22:02:54 +00:00
Rafael Espindola f8b27c41e8 Nuke the old JIT.
I am sure we will be finding bits and pieces of dead code for years to
come, but this is a good start.

Thanks to Lang Hames for making MCJIT a good replacement!

llvm-svn: 215111
2014-08-07 14:21:18 +00:00
Adam Nemet f67d999ebb [Make] Fix dependencies for td.expanded
Depend on all the .td files not just the main one.

llvm-svn: 211390
2014-06-20 19:00:41 +00:00
Eric Christopher f6e456dd63 Add the coverage cflags to the link step as well to make sure
that we link in the support libraries.

llvm-svn: 211131
2014-06-17 23:27:32 +00:00
Tom Stellard 50801489ee autoconf: Fix libLLVM-Major-Minor-Patch.so symlink
The symlink needs to point to a relative path, so we don't break
building in a chroot.

Tested-by: Laurent Carlier <lordheavym@gmail.org>
llvm-svn: 208908
2014-05-15 19:50:25 +00:00
Tom Stellard 9541307c27 autoconf: Fix soname for libLLVM-Major.Minor.so (2nd try)
We were using libLLVM-Major.Minor.Patch.so for the soname, but we
need the soname to stay consistent for all Major.Minor.* releases
otherwise operating system distributors  will need to rebuild all
packages that link with LLVM every time there is a new point release.

This patch also reverses the compatibility symlink, so
libLLVM-Major.Minor.Patch.so is now a symlink that points
to libLLVM-Major-Minor.so.

llvm-svn: 208721
2014-05-13 19:37:03 +00:00
Adam Nemet 6112c2d26e [Build] Add rule to generate fully-expanded .td file
I found it useful in the past and now again to have a version of the .td file
where all the records are expanded.  This adds a makefile rule to generate
this on demand.

llvm-svn: 208056
2014-05-06 03:49:45 +00:00
Rafael Espindola 8b35074e09 Use -std=gnu++11 on cygwin and mingw.
Without this common features like off_t and strdup are missing.
This should bring back those bots.

Configure bits by Meador Inge.

llvm-svn: 203701
2014-03-12 20:01:15 +00:00
Nico Weber ad15692061 "Mac OS/X" -> "Mac OS X" spelling fixes for llvm.
Patch from Sean McBride <sean@rogue-research.com>!

llvm-svn: 203258
2014-03-07 18:08:54 +00:00
Tom Stellard e6ba81dae9 Add patch level to llvm version in CMake and Autoconf
The shared library generated by autoconf will now be called
libLLVM-$(VERSION_MAJOR).$(VERSION_MINOR).$(VERSION_PATCH)$(VERSION_SUFFIX).so
and a symlink named
libLLVM-$(VERSION_MAJOR).$(VERSION_MINOR)$(VERSION_SUFFIX).so will
also be created in the install directory.

llvm-svn: 202720
2014-03-03 15:22:00 +00:00
Chandler Carruth bbae512cd2 [C++11] Replace autoconf --enable-cxx11 with --enable-cxx1y. The
baseline is now C++11, and we unconditionally add -std=c++11 to the
flags.

This has the dim potential to break some non-GNU-compatible compiler (in
terms of -std flags) using the makefiles, but those makefiles are
littered with GNU-style compile flags so it would be very surprising to
me for it to actually happen in practice. As always, do let me know if
there is a toolchain you're using where this doesn't work, and I'll be
watching the bots.

llvm-svn: 202569
2014-03-01 03:33:08 +00:00
Rafael Espindola c80968e954 Centralize the handling of install_name and rpath.
This centralizes the Makefile handling of -install_name and -rpath. It also
moves the cmake build to using @rpath. The reason being that libclang needs it,
and it works for everything else.

A followup patch will move clang to using this and then there will be a single
point to edit to support other systems.

llvm-svn: 202499
2014-02-28 13:48:03 +00:00
NAKAMURA Takumi 01e3c64f11 Provide CMake package modules in install tree
Teach the Makefile build system to generate and install CMake modules
LLVMConfig.cmake and LLVMConfigVersion.cmake so that applications that
build with CMake can use 'find_package(LLVM)' even when LLVM is not
built with CMake.  These modules tell such applications about available
LLVM libraries and their dependencies.

Run llvm-config to generate the list of libraries and use the results of
llvm-build to generate the library dependencies.  Use sed to perform
substitutions in the LLVMConfig.cmake.in and LLVMConfigVersion.cmake.in
sources that our CMake build system uses.

Teach the Makefile build system to generate the LLVMExports.cmake file
with content similar to that produced by the CMake install(EXPORT)
command.  Extend llvm-build with an option to generate the library
dependencies fragment for this file.

Contributed by Brad King.

llvm-svn: 201053
2014-02-09 16:37:02 +00:00
Jack Carter 5b3d51c7fb [Mips]Work around MIPS linker issues exposed by commit r198087 until bug 18360 is resolved
llvm-svn: 198451
2014-01-03 22:18:43 +00:00
Nico Weber 47ba8fa7ec Strip dead code when linking by default with BFD ld (linux, ...) and ld64 (os x).
This reduces the size of clang-format from 22 MB to 1.8 MB, diagtool goes from
21 MB to 2.8 MB, libclang.so goes from 29 MB to 20 MB, etc.  The size of the
bin/ folder shrinks from 270 MB to 200 MB.

Targets that support plugins and don't already use EXPORTED_SYMBOL_FILE
(which libclang and libLTO already do) can set NO_DEAD_STRIP to opt out.

llvm-svn: 198087
2013-12-27 22:38:59 +00:00
Chandler Carruth 9c33cfa47b Teach the Makefile build system how to handle SOURCES which include
subdirectories. The only thing needed here is to create the appropriate
object file directories and add those as dependencies for the
compilation rules.

As a consequence, factor the non-source-file-specific dependencies for
compilation rules into a helper variable. This fixes an issue where the
project makefile wasn't actually a dependency of a bunch of compilation
make rules for no apparant reason.

This should have no observable effect for current makefile usage, but
will simplify how we build other libraries and is something CMake
already supports.

llvm-svn: 194753
2013-11-14 23:51:29 +00:00
Dmitri Gribenko 410ba0c3d5 Fix regular expression to work with multiple-digit version numbers
llvm-svn: 194719
2013-11-14 18:31:30 +00:00
Rafael Espindola aca9739a1a Rules adjustments in order to build on DragonFly BSD.
Patch by Robin Hahling.

llvm-svn: 193750
2013-10-31 14:35:00 +00:00
NAKAMURA Takumi ee4763c248 Makefile.rules: Avoid -fomit-frame-pointer also on cygwin due to PR14646.
llvm-svn: 188620
2013-08-18 03:38:40 +00:00
NAKAMURA Takumi 1ade5e9574 Makefile.rules: Simplify nested if(s) on OmitFramePointer.
llvm-svn: 188619
2013-08-18 02:46:21 +00:00
Tim Northover 35989340a4 Remove oddly named libraries with "make uninstall-local"
Patch by Edward-san.

llvm-svn: 187793
2013-08-06 12:50:45 +00:00
Bob Wilson 9fcf545575 Build with the $RDYNAMIC flag on Darwin as well as other platforms.
Part of <rdar://problem/14620988>

llvm-svn: 187710
2013-08-04 22:06:11 +00:00
Rafael Espindola bff44dddff Remove dead code from the makefile build system.
Back in r140220 we removed the autoconf code that would set LLVMCC_OPTION
since it was only used by the test-suite. This patch now removes code
that would only be used if LLVMCC_OPTION was set.

llvm-svn: 187154
2013-07-25 20:25:31 +00:00
Sylvestre Ledru 93a491bbf4 The build system is currently miss-identifying GNU/kFreeBSD as FreeBSD.
This kind of simplification is sometimes useful, but in general it's not correct. 

As GNU/kFreeBSD is an hybrid system, for kernel-related issues we want to match the
build definitions used for FreeBSD, whereas for userland-related issues we want to
match the definitions used for other systems with Glibc.

The current modification adjusts the build system so that they can be distinguished,
and explicitly adds GNU/kFreeBSD to the build checks in which it belongs.

Fixes bug #16444.

Patch by Robert Millan in the context of Debian.

llvm-svn: 185311
2013-07-01 08:07:52 +00:00
Bob Wilson 7abe25834a Add CXXFLAGS back to the Link command.
This is essentially reverting one piece of 184793 to try to fix one of Apple's
buildbots.  I will check with Eric to see if this is OK or if we need to find
some other solution.

llvm-svn: 185060
2013-06-27 06:09:14 +00:00
Eric Christopher f1bd7702bf Add an autoconf option for turning on -gsplit-dwarf by default
when building llvm. This saves quite a bit of time and space when
linking. Please report any problems via bugzilla.

Caveats:

a) This will only work on linux
b) This requires a fairly new binutils
c) This requires a fairly new gdb

llvm-svn: 184808
2013-06-25 01:12:25 +00:00
Eric Christopher 1f1578b7d3 As far as I know no linker needs or wants the -g flag.
llvm-svn: 184800
2013-06-25 00:40:03 +00:00
Eric Christopher 97e784a588 Remove all non-linker oriented compile options from the linker
command line. Change the darwin universal binary options to
be TargetCommonOpts so that they'll be passed to the linker since
-arch at least is still needed.

Someone on darwin with a buildit based build should probably verify
that this doesn't break anything there.

llvm-svn: 184793
2013-06-24 23:20:04 +00:00
Rafael Espindola d02e7e5693 Remove redundant rpath.
These are not needed since we added the $ORIGIN based rpath.

Fixes pr12517.

llvm-svn: 182559
2013-05-23 02:53:22 +00:00
Rafael Espindola 1250a307f6 Fix indentation.
llvm-svn: 182558
2013-05-23 02:38:50 +00:00
Eric Christopher 3c190d7d1c Revert previous patch, it's actually on under Wall.
llvm-svn: 181837
2013-05-14 21:52:01 +00:00
Eric Christopher 80d2dbe5cf Add -Wreorder to the list of C++ warnings.
This built clean with clang, but if we see false positives on the bots
then we'll revert and turn it into a compiler specific check.

llvm-svn: 181836
2013-05-14 21:49:38 +00:00
Bill Wendling 67758579f5 Remove this hack. We can support this better with function attributes.
llvm-svn: 181059
2013-05-03 21:53:50 +00:00
Bill Wendling 2d8b299dbd We don't want FP elimination when doing an Apple-style build.
llvm-svn: 180949
2013-05-02 21:09:03 +00:00
Filipe Cabecinhas 5afbec8b0c Allow users to choose identity used to sign tools.
Summary:
No change if the identity isn't defined by the makefile.

Reviewers: echristo

Differential Revision: http://llvm-reviews.chandlerc.com/D632

llvm-svn: 180240
2013-04-25 01:17:54 +00:00
Eric Christopher caeddf5a96 Make check depend on all.
llvm-svn: 179116
2013-04-09 19:42:12 +00:00
Eric Christopher 31f4354c75 Turn anonymous type in anonymous union warning back on after cleaning up
issues.

llvm-svn: 177136
2013-03-15 00:43:00 +00:00
Chris Lattner fd7d67e18f remove an ancient and quaint bit of commented out makefile goo from when
GCC was the system compiler on the mac.

llvm-svn: 176675
2013-03-08 01:26:10 +00:00
Bill Wendling 89ff87ec3b Use 'RC_XBS' instead of 'RC_BUILDIT' to catch all times when it's built in the Apple way.
llvm-svn: 175069
2013-02-13 19:44:08 +00:00
Bob Wilson a786b2c3d1 Set the deployment target for Apple llvmCore builds. <rdar://problem/12712431>
llvm-svn: 174397
2013-02-05 17:29:03 +00:00
Richard Smith 6c26e74781 Add -Wno-nested-anon-types to -pedantic builds of LLVM. This Clang warning
catches uses of an extremely minor and widely-available C++ extension (which
every C++ compiler I could find supports, but EDG and Clang reject in strict
mode).

The diagnosed code pattern looks like this:

struct X {
  union {
    struct {
      int a;
      int b;
    } S;
  };
};

llvm-svn: 174103
2013-01-31 22:19:12 +00:00
Saleem Abdulrasool 26127bd746 build: add --with-python option
This adds a new --with-python option to allow configuration of the python binary
for building.  If not specified, $PATH will be searched for common python binary
names (python, python2, python3).  If specified, and the path is not executable,
it will attempt to search $PATH.

Signed-off-by: Saleem Abdulrasool <compnerd@compnerd.org>
Reviewed-by: Eric Christopher <echristo@gmail.com>, Daniel Dunbar <daniel@zuster.org>
llvm-svn: 173890
2013-01-30 04:07:37 +00:00
David Greene b609a26355 Pass NO_MISSING_FIELD_INITIALIZERS to Compiler Flags
configure checks whether -Wno-missing-field-initializers is a valid
compiler flag but it was never actually used in Makefile.rules.
Enable it to avoid some ridiculous warnings from gcc.

llvm-svn: 172870
2013-01-18 23:22:52 +00:00