Skip to content
GitLab
Projects
Groups
Snippets
Help
Loading...
Help
What's new
7
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Open sidebar
CMake
CMake
Commits
74f5545d
Commit
74f5545d
authored
Nov 28, 2013
by
Julien Schueller
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
UseSWIG: set .bundle ext on OSX and no prefix (
#12184
)
parent
93d2322e
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
12 additions
and
2 deletions
+12
-2
Modules/UseSWIG.cmake
Modules/UseSWIG.cmake
+12
-2
No files found.
Modules/UseSWIG.cmake
View file @
74f5545d
...
...
@@ -210,8 +210,7 @@ macro(SWIG_ADD_MODULE name language)
# Linux : libLIBRARY.so
set_target_properties
(
${
SWIG_MODULE_
${
name
}
_REAL_NAME
}
PROPERTIES SUFFIX
".jnilib"
)
endif
()
endif
()
if
(
"
${
swig_lowercase_language
}
"
STREQUAL
"python"
)
elseif
(
"
${
swig_lowercase_language
}
"
STREQUAL
"python"
)
# this is only needed for the python case where a _modulename.so is generated
set_target_properties
(
${
SWIG_MODULE_
${
name
}
_REAL_NAME
}
PROPERTIES PREFIX
""
)
# Python extension modules on Windows must have the extension ".pyd"
...
...
@@ -225,6 +224,17 @@ macro(SWIG_ADD_MODULE name language)
if
(
WIN32 AND NOT CYGWIN
)
set_target_properties
(
${
SWIG_MODULE_
${
name
}
_REAL_NAME
}
PROPERTIES SUFFIX
".pyd"
)
endif
()
elseif
(
"
${
swig_lowercase_language
}
"
STREQUAL
"ruby"
)
# In ruby you want:
# require 'LIBRARY'
# then ruby will look for a library whose name is platform dependent, namely
# MacOS : LIBRARY.bundle
# Windows: LIBRARY.dll
# Linux : LIBRARY.so
set_target_properties
(
${
SWIG_MODULE_
${
name
}
_REAL_NAME
}
PROPERTIES PREFIX
""
)
if
(
APPLE
)
set_target_properties
(
${
SWIG_MODULE_
${
name
}
_REAL_NAME
}
PROPERTIES SUFFIX
".bundle"
)
endif
()
endif
()
endmacro
()
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment