I was previously appending to nvcc_flags inside the file loop. This
caused the flag to be appended multiple times which freaks out nvcc.
Now the flag is specifically handled per file.
A previously undocumented feature allowed overriding the format
specified to CUDA_WRAP_SRCS with a source file property called
CUDA_SOURCE_PROPERTY_FORMAT. I added documentation for this feature as
well as added the ability to let nvcc compile any file regardless of
type if this property was found.
In addition, I also fixed a couple of bugs with the calls to
_cuda_get_important_host_flags that weren't garding the arguments with
"" to prevent empty values from causing errors.
If the host flags contain a c++11 flag (at least for gcc), then we can't
automatically propagate to nvcc it using -Xcompiler. This is because
nvcc can't use any C++ only flags. Instead we find this flag and add it
to nvcc's flags (it has a special flag for dealing with c++11 code) and
remove it from the host flags.
Co-Author: Guillermo Marcus <gmarcus@nvidia.com>
VS 2013 originally claimed to support initializer lists but a bug was
found in which it generated bad code silently. For this reason we
previously considered support to not be present. However, Update 3 adds
a hard error on cases that previously generated bad code, so it is now
safe to use initializer lists with VS 2013 Update 3 or greater. At
worst a compiler error will be issued in the cases that do not work, but
that is no different from any other compiler-specific workaround a
project code may need.
Beginning in CUDA 5.5 a static version of the cuda runtime library
became available. Since nvcc defaults to using this library over the
shared version, FindCUDA will also default to using this version. There
are many advantages to using the static version (most importantly to
avoid conflicts with multiple versions when building a CUDA based
library). Offer a CUDA_USE_STATIC_CUDA_RUNTIME option to control
this behavior.
RPM packages can contain symbolic links to relative paths - including
support for multiple relocation paths through generation of post install
relocation scripts. Add basic support with limitations described in
documentation.
Add the dependency on the main swig input source file as a normal
DEPENDS option. We cannot use MAIN_DEPENDENCY because if there are
multiple target languages then multiple custom commands would want to
use the same MAIN_DEPENDENCY, but at most one custom command may specify
a given source file as its MAIN_DEPENDENCY. Exposed by a CMP0057
warning.
Extend the ``DATA{Dir/,...}`` syntax with a new ``RECURSE:`` option
to enable recursive matching of associated files. This will allow
an entire directory tree of data to be referenced at once.
Extend the _ExternalData_arg_find_files signature with an option to
specify the kind of file(GLOB) operation to be performed. Set
CMP0009 to NEW so that GLOB_RECURSE does not follow symlinks.
Teach the Xcode generator that ONLY_ACTIVE_ARCH=YES means to use ARCHS,
and that the default of ONLY_ACTIVE_ARCH=NO means to use NATIVE_ARCH and
ignore ARCHS. In the latter case there is no reason to generate ARCHS.
The `binary_dir` variable is never set, so this is invalid. Instead, use
"." which all the other build commands use anyways. Also only set the
--config option if it is meaningful.
The compiler documents that USE statements search for ".mod" files
in directories specified with -I, but not -isystem.
Reported-by: Hugh Sorby <h.sorby@auckland.ac.nz>
Replace an old hack of the form 'if("${VAR}" MATCHES "^${VAR}$")'
with the much simpler 'if(NOT DEFINED ${VAR})'. This was exposed
by a CMP0054 warning.
The Xcode 5 platform specific framework locations differ from the Xcode
6 ones. Look first for the Xcode 6 ones, then for iOS Xcode 5 ones and
last for the Xcode 5 OS X ones.
For reference, the XCTest.framework is located as follows:
Xcode511.app/Contents/Developer/Library/Frameworks/XCTest.framework
Xcode511.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/SDKs/iPhoneOS7.1.sdk/Developer/Library/Frameworks/XCTest.framework
Xcode511.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator7.1.sdk/Developer/Library/Frameworks/XCTest.framework
Xcode601.app/Contents/Developer/Platforms/MacOSX.platform/Developer/Library/Frameworks/XCTest.framework
Xcode601.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/Library/Frameworks/XCTest.framework
Xcode601.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/Library/Frameworks/XCTest.framework
Signed-off-by: Gregor Jasny <gjasny@googlemail.com>
4178cd88 Help: Add notes for topic 'xcode-xctest'
87a4b858 Tests: Add XCTest example to test Frameworks and Cocoa App Bundles
ba14510b OS X: Add FindXCTest module
3714955b OS X: Add handling for XCTest bundles
54a5cdbb Tests: Compute Xcode version for any generator on OS X
Add a module to lookup XCTest Framework and xctest utility.
It also provides APIs for creating 'xctest' targets.
Signed-off-by: Gregor Jasny <gjasny@googlemail.com>
The PGI compilers on Linux do not have the -fPIE flag. Remove the table
entry added by commit v2.8.9~125^2~2 (Add platform variables for
position independent code flags, 2012-05-05), which likely included it
only as part of a sweeping introduction of such flags.
Since commit v2.8.11~63^2 (UseJava.cmake: require explicit request to
include jars, 2013-03-26) the argument parsing always overrides the
variable settings even if the corresponding arguments are not passed.
Re-order logic to fix this.
Fixes mantis bug report with id 15169. Some
component specific attributes were leaking
to next component. Leakage handling was
implemented in different locations but there
were still attributes that leaked. Patch
encapsulates generator into function so all
current leaks are fixed and no future leaks
can occur.
Implement a brand new FindMatlab module:
- Add support for versions and components.
- Find Matlab and its version in a more precise and multiplatform way.
- Add API to create a new mex extension with documentation.
- Add API to add matlab unit tests (with or without the unit test framework).
- Find as much as possible based on a single Matlab_ROOT_DIR cache entry
and allow the user to change it to re-find everything.