Commit Graph

244 Commits

Author SHA1 Message Date
Talin
bdcd766028 Added missing va_end().
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@126759 91177308-0d34-0410-b5e6-96231b3b80d8
2011-03-01 18:00:49 +00:00
Tobias Grosser
f3a83d6d0b cmake: Add xdot.py support as it already exists in autoconf.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@126563 91177308-0d34-0410-b5e6-96231b3b80d8
2011-02-27 04:11:05 +00:00
Oscar Fuentes
7d83dc0424 Export TARGET_TRIPLE on LLVM.cmake. It is necessary for running tests
on Clang when it builds using LLVM as an external library.

Fixes PR9293.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@126309 91177308-0d34-0410-b5e6-96231b3b80d8
2011-02-23 11:28:40 +00:00
Oscar Fuentes
50b284666f CMake: remove unnecessary variable.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@126224 91177308-0d34-0410-b5e6-96231b3b80d8
2011-02-22 15:40:20 +00:00
NAKAMURA Takumi
afcf6ac7a8 CMake: Define LLVM_INCLUDE_TESTS in cmake/modules/HandleLLVMOptions.cmake. It affects testing stuff on clang-standalone build.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@126107 91177308-0d34-0410-b5e6-96231b3b80d8
2011-02-21 03:21:06 +00:00
NAKAMURA Takumi
0f300475be CMake: Fix breakage on clang standalone build.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@126106 91177308-0d34-0410-b5e6-96231b3b80d8
2011-02-21 03:20:57 +00:00
Oscar Fuentes
0b85d07d46 Put targets on folders, if the IDE supports the feature.
Requires CMake 2.8.3 or newer.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@126092 91177308-0d34-0410-b5e6-96231b3b80d8
2011-02-20 22:06:10 +00:00
Oscar Fuentes
00d78f1348 Use explicit add_subdirectory's for LLVM target sublibraries instead
of testing for its presence at cmake time.

This way the build automatically regenerates the makefiles when a svn
update brings in a new sublibrary.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@126068 91177308-0d34-0410-b5e6-96231b3b80d8
2011-02-20 02:55:27 +00:00
Jeffrey Yasskin
9bb83e4f48 Add the PARSE_ARGUMENTS CMake macro to LLVM so I can use it to clean
up add_clang_unittest's calling convention.



git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@126031 91177308-0d34-0410-b5e6-96231b3b80d8
2011-02-19 18:01:15 +00:00
Oscar Fuentes
6d857ca4d7 Move library stuff out of the toplevel CMakeLists.txt file.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@125968 91177308-0d34-0410-b5e6-96231b3b80d8
2011-02-18 22:06:14 +00:00
Oscar Fuentes
742c0dd8fd New library: LLVMX86Utils.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@125786 91177308-0d34-0410-b5e6-96231b3b80d8
2011-02-17 22:26:11 +00:00
NAKAMURA Takumi
cbf023d7ec CMake: LLVM_LIT_TOOLS_DIR is needed only on Win32 hosts to use GnuWin32 tools.
Unixen and Cygwin do not need it.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@125277 91177308-0d34-0410-b5e6-96231b3b80d8
2011-02-10 10:29:42 +00:00
NAKAMURA Takumi
b656a11c70 CMake: Add the new option LLVM_LIT_TOOLS_DIR. It can specify "Path to GnuWin32 tools".
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@125173 91177308-0d34-0410-b5e6-96231b3b80d8
2011-02-09 04:18:58 +00:00
NAKAMURA Takumi
e29b0aca51 lib/Support/Errno.cpp: Check strerror_s() with HAVE_DECL_STRERROR_S in config.h.*.
AC_CHECK_FUNCS seeks a symbol only in libs. We should check the declaration in string.h.

FIXME: I have never seen mingw(s) have strerror_s() (not _strerror_s()).
FIXME: Autoconf/CMake may seek strerror_s() with the definition MINGW_HAS_SECURE_API in future.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@125172 91177308-0d34-0410-b5e6-96231b3b80d8
2011-02-09 04:18:48 +00:00
Oscar Fuentes
cf9efa5966 Install only *.cmake files. Don't install .svn directory.
Fixes PR9159.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@125001 91177308-0d34-0410-b5e6-96231b3b80d8
2011-02-07 02:22:23 +00:00
Oscar Fuentes
dd70cd8933 Don't define NDEBUG on MSVC_IDE and XCode builds. Fixes PR9155.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@124985 91177308-0d34-0410-b5e6-96231b3b80d8
2011-02-06 19:07:06 +00:00
Oscar Fuentes
5a858e3416 Moved more stuff to HandleLLVMOptions.cmake
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@124968 91177308-0d34-0410-b5e6-96231b3b80d8
2011-02-05 19:08:42 +00:00
NAKAMURA Takumi
1f6832a858 Windows/DynamicLibrary.inc: Split explicit symbols into explicit_symbols.inc.
config.h.* have conditions whether each symbol is defined or not.
Autoconf and CMake may check symbols in libgcc.a for JIT on Mingw.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@124950 91177308-0d34-0410-b5e6-96231b3b80d8
2011-02-05 15:11:53 +00:00
Oscar Fuentes
325610bf77 LLVM_ON_WIN32 is not defined on config-ix.cmake. Use something else.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@124857 91177308-0d34-0410-b5e6-96231b3b80d8
2011-02-04 05:40:04 +00:00
Oscar Fuentes
ba6ac91995 Add the tablegenned files to the `clean' target.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@124854 91177308-0d34-0410-b5e6-96231b3b80d8
2011-02-04 03:47:50 +00:00
Oscar Fuentes
d538e24922 Changes for building Clang and others using LLVM as an external
library.

Installs tblgen (required by Clang).

Translates handling of user settings and platform-dependant options to
its own file, where it can included by another project.

Installs the .cmake files required by projects like Clang.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@124816 91177308-0d34-0410-b5e6-96231b3b80d8
2011-02-03 20:57:36 +00:00
NAKAMURA Takumi
76422f3e08 cmake/*: Add svn:eol-style=native and fix CRLF.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@124793 91177308-0d34-0410-b5e6-96231b3b80d8
2011-02-03 11:41:27 +00:00
Oscar Fuentes
254f35ca4a Platform tests for sys/uio.h' header and writev' function.
This is the cmake equivalent for r124769.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@124775 91177308-0d34-0410-b5e6-96231b3b80d8
2011-02-03 04:23:07 +00:00
Oscar Fuentes
78e2074eee Adds some platform checks to cmake/config-ix.cmake and fixes checking
for dlopen/dlerror.

Patch by arrowdodger!

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@124590 91177308-0d34-0410-b5e6-96231b3b80d8
2011-01-31 18:25:25 +00:00
Oscar Fuentes
d73e5751b2 Don't show -pedantic, -W and -Wall on the output of
llvm-config --cflags --cxxflags --cppflags

We shouldn't impose those flags on people who use llvm-config for
building their own projects.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@124399 91177308-0d34-0410-b5e6-96231b3b80d8
2011-01-27 19:29:48 +00:00
Oscar Fuentes
5969379145 Handles libffi on the CMake build.
Patch by arrowdodger!

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@123976 91177308-0d34-0410-b5e6-96231b3b80d8
2011-01-21 15:42:54 +00:00
Oscar Fuentes
3c00a83c33 Add some platform checks. Also fix a typo on a Makefile.
Patch by arrowdodger!

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@123659 91177308-0d34-0410-b5e6-96231b3b80d8
2011-01-17 16:35:14 +00:00
Oscar Fuentes
111fd9ce64 Make config.h.cmake similar to config.h.in
Patch by arrowdodger!

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@123539 91177308-0d34-0410-b5e6-96231b3b80d8
2011-01-15 13:35:37 +00:00
Oscar Fuentes
006bfeba06 Add some platform tests.
Patch by arrowdodger!

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@123388 91177308-0d34-0410-b5e6-96231b3b80d8
2011-01-13 19:17:28 +00:00
Oscar Fuentes
60b531270b Platform tests for argz_* functions.
Patch by arrowdodger!

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@123376 91177308-0d34-0410-b5e6-96231b3b80d8
2011-01-13 15:06:32 +00:00
Oscar Fuentes
19823b19ba Add to the CMake build some options and platform tests supported by
the traditional build.

Patch by arrowdodger!

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@123233 91177308-0d34-0410-b5e6-96231b3b80d8
2011-01-11 12:31:54 +00:00
Oscar Fuentes
927d8aee53 Made llvm_replace_compiler_option more robust. Use it on
llvm_process_sources.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@123232 91177308-0d34-0410-b5e6-96231b3b80d8
2011-01-11 12:31:34 +00:00
Oscar Fuentes
2c5e0b8b98 Rewrite handling of LLVM_ENABLE_PIC. It was being processed after
config.h was generated, so it had no effect on it.

Thanks to arrowdodger for pointing out this and a tentative patch.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@123119 91177308-0d34-0410-b5e6-96231b3b80d8
2011-01-09 14:34:39 +00:00
Oscar Fuentes
53bf3ee82b Don't use -O3 on Mingw, as people report it as unreliable. Use -O2
instead.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@123028 91177308-0d34-0410-b5e6-96231b3b80d8
2011-01-07 20:31:03 +00:00
Oscar Fuentes
5b30f0a7eb TableGen.cmake: sometimes the .td file is not in the current directory
(clang/include/clang/Basic/StmtNodes.td, for instance, is tablegenned
from clang/include/clang/AST/CMakeLists.txt) so it is not contained on
the list of all .td files on the current source directory which is
used as the DEPENDS of the custom command. We must add the .td file to
the DEPENDS list of the custom command. Otherwise some .inc files are
not regenerated when the corresponding .td file changes.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@122768 91177308-0d34-0410-b5e6-96231b3b80d8
2011-01-03 20:01:32 +00:00
Oscar Fuentes
0895db0abf LLVMProcessSources: add .def files along with .h files to targets for
the benefit of project-based generators (VS, XCode, etc).

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@122749 91177308-0d34-0410-b5e6-96231b3b80d8
2011-01-03 16:59:52 +00:00
Oscar Fuentes
449d4e12c9 Propagate to parent scope changes made to CMAKE_CXX_FLAGS.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@122692 91177308-0d34-0410-b5e6-96231b3b80d8
2011-01-02 12:30:18 +00:00
Oscar Fuentes
023c63351e CMake (MSVC): cmake automatically adds the /EHsc and /GR compiler
options. If we are building with exceptions/rtti disabled, we replace
/EHsc with /EHs-c- and /GR with /GR-, respectively. If we just add the
disabling options we get warnings like this:

cl : Command line warning D9025 : overriding '/EHs' with '/EHs-'

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@122648 91177308-0d34-0410-b5e6-96231b3b80d8
2010-12-31 19:10:49 +00:00
Oscar Fuentes
711042839c Fixes file extension for loadable modules on OS X.
Patch by Wesley Peck!

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@122395 91177308-0d34-0410-b5e6-96231b3b80d8
2010-12-22 08:30:17 +00:00
Oscar Fuentes
ec33e8dcd6 Update cmake library dependencies.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@122239 91177308-0d34-0410-b5e6-96231b3b80d8
2010-12-20 09:47:08 +00:00
Wesley Peck
59b4127029 Reverting commit to LLVMLibDeps that was inadvertently done in 121649.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@121651 91177308-0d34-0410-b5e6-96231b3b80d8
2010-12-12 22:28:51 +00:00
Wesley Peck
a7c7b9dccb The ADD and ADDK (and all variants) instructions where flip-flopped in the MBlaze backend. This bug fix makes 64-bit math work on the MBlaze backend.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@121649 91177308-0d34-0410-b5e6-96231b3b80d8
2010-12-12 22:02:31 +00:00
NAKAMURA Takumi
51c06bf6ad Add dependency to "make check".
cmake/modules/AddLLVM.cmake: Add empty "phony" target in add_llvm_loadable_module() even if loadable module were not supported.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@121455 91177308-0d34-0410-b5e6-96231b3b80d8
2010-12-10 02:15:36 +00:00
Francois Pichet
b361452ef9 Disable C++ exception handling on MSVC.
Total size of bin\Release on disk goes from 82.9 MB to 74.2 MB. (~10% saving)


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@120908 91177308-0d34-0410-b5e6-96231b3b80d8
2010-12-04 14:30:22 +00:00
Francois Pichet
a785a6b5c5 Disable RTTI on Windows.
Total size of bin\Release on disk goes from 83.6 MB to 81.8MB. (~2% saving)

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@120901 91177308-0d34-0410-b5e6-96231b3b80d8
2010-12-04 09:42:30 +00:00
Michael J. Spencer
db04b39dad Support/FileSystem: Fix MinGW build. It doesn't have _chsize_s.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@120826 91177308-0d34-0410-b5e6-96231b3b80d8
2010-12-03 18:48:56 +00:00
Michael J. Spencer
e93e10a0dd Update library dependencies changed in the System -> Support merge.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@120308 91177308-0d34-0410-b5e6-96231b3b80d8
2010-11-29 19:28:48 +00:00
Michael J. Spencer
1f6efa3996 Merge System into Support.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@120298 91177308-0d34-0410-b5e6-96231b3b80d8
2010-11-29 18:16:10 +00:00
Wesley Peck
4b04713423 Implement ELF object file writing support for the MBlaze backend. Its not perfect yet, but it works for many tests.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@119952 91177308-0d34-0410-b5e6-96231b3b80d8
2010-11-21 22:06:28 +00:00
Oscar Fuentes
78786f9eb6 Updated library dependencies.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@119592 91177308-0d34-0410-b5e6-96231b3b80d8
2010-11-18 00:12:27 +00:00