Comments (8)
BTW, this is the error im having
CMake Error at CMake/common/CommonCUDA.cmake:33 (string):
string sub-command REGEX, mode REPLACE needs at least 6 arguments total to
command.
Call Stack (most recent call first):
CMake/common/CommonFindPackage.cmake:276 (find_cuda_compatible_host_compiler)
CMakeLists.txt:103 (common_find_package_post)
CMake 3.9.4
from cmake.
You don't need to use CommonCUDA explicitly, the necessary code gets invoked from common_find_package_post(). If you've observed that error just by adding common_find_package(CUDA), then the problem must be in the parsing of the host_config.h CUDA header, which keeps changing all the time.
Related to the first problem, you should use cuda_add_library. Although I don't remember what's the actual explanation for it I added this to my CMakeLists.txt:
install(TARGETS your_target EXPORT ${PROJECT_NAME}Targets LIBRARY DESTINATION lib COMPONENT COMMON)
It may also solve your problem.
from cmake.
The problem with cudacommon happens when doing common_find_package(CUDA). Isn't there an easy way to simply do common_library and that compiles it with cuda if cuda is enabled? Or what should be the correct process to configure a project with cuda with cmakecommon?
from cmake.
Ideally, having a smart common_library that can handle CUDA libraries would be perfect. But nobody has the time time right now to implement and I'm afraid that is not that simple, as it requires embedding cuda_add_library and will require making a few assumptions about the user intentions.
I think the problem is the header parsing as I said, so it should be easily fixable. Which CUDA version are you using?
from cmake.
Cuda 9
from cmake.
I'll try to see the difference in the host_config.h header as soon as possible.
from cmake.
Sorry for the delay, but I had to look into more urgent things and eventually forgot about this issue. If you're problem with the header parsing solved?
from cmake.
Ive been able to workaround the problem adding common_find_package(CUDA) after common_find_package_post(). This bypass the checks done in _post() and everything seems to work fine.
Not a production solution for CMakeCommon, but it works.
from cmake.
Related Issues (20)
- PROJECT_DESCRIPTION should not include ":" character
- COMMON_USE_CXX03 doesn't set -std flag HOT 6
- GitTargets.cmake has error on OSX HOT 1
- Move Doxygit.cmake to BBPDocumentation
- Remove per-system defines.h file generation HOT 2
- -WError abuse HOT 7
- Problems with pkg_check_modules output variable casing HOT 1
- Dependent libraries rebuilt HOT 1
- Complex bug with recursive git_subprojects and system packge installed HOT 4
- ninja rebase clones CMake/common for all subprojects
- "make prj-doxygen" invokes a "make install" HOT 2
- FindPackage not found persists HOT 1
- FindPackage not found persists [Reopen] HOT 5
- Extra targets HOT 1
- Subproject git modules not cloned recursively
- Please allow override of COMMON_DOC_DIR
- Mini-bug CommonGraph.cmake - change add CURR_DIR
- GitHooks does not handle running in submodules
- Do not override the default installation path to `/usr`
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from cmake.