Merge "[CMakeList generator] Fix executable name"
This commit is contained in:
@@ -163,9 +163,15 @@ func generateCLionProject(compiledModule CompiledInterface, ctx blueprint.Single
|
|||||||
translateToCMake(cppParameters, f, false, true)
|
translateToCMake(cppParameters, f, false, true)
|
||||||
|
|
||||||
// Add project executable.
|
// Add project executable.
|
||||||
f.WriteString(fmt.Sprintf("\nadd_executable(%s ${SOURCE_FILES})\n", ccModule.ModuleBase.Name()))
|
f.WriteString(fmt.Sprintf("\nadd_executable(%s ${SOURCE_FILES})\n",
|
||||||
|
cleanExecutableName(ccModule.ModuleBase.Name())))
|
||||||
}
|
}
|
||||||
|
|
||||||
|
func cleanExecutableName(s string) string {
|
||||||
|
return strings.Replace(s, "@", "-", -1)
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
func translateToCMake(c compilerParameters, f *os.File, cflags bool, cppflags bool) {
|
func translateToCMake(c compilerParameters, f *os.File, cflags bool, cppflags bool) {
|
||||||
writeAllSystemDirectories(c.systemHeaderSearchPath, f)
|
writeAllSystemDirectories(c.systemHeaderSearchPath, f)
|
||||||
writeAllIncludeDirectories(c.headerSearchPath, f)
|
writeAllIncludeDirectories(c.headerSearchPath, f)
|
||||||
|
Reference in New Issue
Block a user