Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
V
vlc-gpu
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Redmine
Redmine
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Operations
Operations
Metrics
Environments
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
videolan
vlc-gpu
Commits
faaf778a
Commit
faaf778a
authored
Feb 07, 2008
by
Pierre d'Herbemont
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
cmake: FindLua and maintain an enabled module list.
parent
00ea5c2f
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
62 additions
and
16 deletions
+62
-16
extras/buildsystem/cmake/include/FindLua.cmake
extras/buildsystem/cmake/include/FindLua.cmake
+36
-0
extras/buildsystem/cmake/include/config.cmake
extras/buildsystem/cmake/include/config.cmake
+19
-14
extras/buildsystem/cmake/include/vlc_module_funcs.cmake
extras/buildsystem/cmake/include/vlc_module_funcs.cmake
+7
-2
No files found.
extras/buildsystem/cmake/include/FindLua.cmake
0 → 100644
View file @
faaf778a
# - Find library containing Lua()
# The following variables are set if Lua is found. If Lua is not
# found, Lua_FOUND is set to false.
# Lua_FOUND - System has Lua.
# Lua_LIBRARIES - Link these to use Lua.
# Lua_CFLAGS - Link these to use Lua.
if
(
NOT Lua_SEARCHED
)
include
(
CheckLibraryExists
)
set
(
Lua_SEARCHED TRUE CACHE INTERNAL
""
)
set
(
Lua_FOUND FALSE CACHE INTERNAL
""
)
pkg_check_modules
(
Lua lua>=5.1
)
if
(
NOT Lua_FOUND
)
find_library
(
Lua_LIBRARY NAMES lua5.1 lua51 lua
)
if
(
Lua_LIBRARY
)
set
(
Lua_LIBRARIES
"
${
Lua_LIBRARY
}
"
)
set
(
Lua_FOUND TRUE CACHE INTERNAL
""
)
endif
(
Lua_LIBRARY
)
endif
(
NOT Lua_FOUND
)
if
(
Lua_FOUND
)
if
(
NOT Lua_FIND_QUIETLY
)
message
(
STATUS
"Found Lua in:
${
Lua_LIBRARIES
}
"
)
endif
(
NOT Lua_FIND_QUIETLY
)
else
(
Lua_FOUND
)
if
(
Lua_FIND_REQUIRED
)
message
(
FATAL_ERROR
"Could not find the library containing Lua"
)
endif
(
Lua_FIND_REQUIRED
)
endif
(
Lua_FOUND
)
mark_as_advanced
(
Lua_LIBRARIES
)
endif
(
NOT Lua_SEARCHED
)
extras/buildsystem/cmake/include/config.cmake
View file @
faaf778a
...
...
@@ -136,7 +136,7 @@ if(APPLE)
include
(
${
CMAKE_SOURCE_DIR
}
/cmake/vlc_find_frameworks.cmake
)
if
(
ENABLE_NO_SYMBOL_CHECK
)
set
(
DYNAMIC_LOOKUP
"-undefined dynamic_lookup"
CACHE INTERNAL
)
set
(
DYNAMIC_LOOKUP
"-undefined dynamic_lookup"
CACHE INTERNAL
STRING
)
endif
(
ENABLE_NO_SYMBOL_CHECK
)
set
(
CMAKE_SHARED_MODULE_CREATE_CXX_FLAGS
"
${
CMAKE_SHARED_MODULE_CREATE_CXX_FLAGS
}
${
DYNAMIC_LOOKUP
}
"
)
...
...
@@ -188,9 +188,7 @@ if(APPLE)
COMMAND cd
${
CMAKE_CURRENT_BINARY_DIR
}
/tmp/extras/package/macosx && xcodebuild -target vlc | grep -vE '^\
(
[ \\t]|$$\
)
' && cd ../../../../ && cp
${
CMAKE_CURRENT_BINARY_DIR
}
/tmp/extras/package/macosx/build/Default/VLC.bundle/Contents/Info.plist
${
CMAKE_CURRENT_BINARY_DIR
}
/VLC.app/Contents && cp -R
${
CMAKE_CURRENT_BINARY_DIR
}
/tmp/extras/package/macosx/build/Default/VLC.bundle/Contents/Resources/English.lproj
${
CMAKE_CURRENT_BINARY_DIR
}
/VLC.app/Contents/Resources
COMMAND cp -r
${
CMAKE_CURRENT_SOURCE_DIR
}
/extras/package/macosx/Resources
${
CMAKE_CURRENT_BINARY_DIR
}
/VLC.app/Contents
COMMAND find -d
${
CMAKE_CURRENT_BINARY_DIR
}
/VLC.app/Contents/Resources -type d -name \\.svn -exec rm -rf {}
"
\;
"
COMMAND rm -rf
${
MacOS
}
/modules
${
MacOS
}
/locale
COMMAND mkdir
${
MacOS
}
/modules
COMMAND rm -f
${
MacOS
}
/share
#remove the link if it exists
COMMAND rm -rf
${
MacOS
}
/modules
${
MacOS
}
/locale
${
MacOS
}
/share
COMMAND ln -s
${
CMAKE_CURRENT_SOURCE_DIR
}
/share
${
MacOS
}
/share
COMMAND ln -s
${
CMAKE_CURRENT_BINARY_DIR
}
/modules
${
MacOS
}
/modules
COMMAND find
${
CMAKE_BINARY_DIR
}
/po -name *.gmo -exec sh -c \"mkdir -p
${
MacOS
}
/locale/\\`basename {}|sed s/\\.gmo//\\`/LC_MESSAGES\; ln -s {}
${
MacOS
}
/locale/\\`basename {}|sed s/\\.gmo//\\`/LC_MESSAGES/vlc.mo\"
"
\;
"
...
...
@@ -222,8 +220,6 @@ command_to_configvar( "${CMAKE_C_COMPILER} --version" CONFIGURE_LINE )
set
(
VLC_COMPILER
"
${
CMAKE_C_COMPILER
}
"
)
###########################################################
# Modules: Following are all listed in options
###########################################################
...
...
@@ -247,8 +243,6 @@ vlc_enable_modules(packetizer_mpeg4video packetizer_mpeg4audio)
vlc_enable_modules
(
packetizer_vc1
)
vlc_enable_modules
(
spatializer
)
vlc_enable_modules
(
ffmpeg
)
if
(
NOT mingwce
)
set
(
enabled ON
)
endif
(
NOT mingwce
)
...
...
@@ -289,8 +283,8 @@ if(ENABLE_CONTRIB)
set
(
CMAKE_CXX_LINK_FLAGS
"
${
CMAKE_CXX_LINK_FLAGS
}
-L
${
CONTRIB_LIB
}
"
)
set
(
CMAKE_SHARED_MODULE_CREATE_C_FLAGS
"
${
CMAKE_SHARED_MODULE_CREATE_C_FLAGS
}
-L
${
CONTRIB_LIB
}
"
)
set
(
CMAKE_SHARED_MODULE_CREATE_CXX_FLAGS
"
${
CMAKE_SHARED_MODULE_CREATE_CXX_FLAGS
}
-L
${
CONTRIB_LIB
}
"
)
set
(
CMAKE_SHARED_LIBRARY_CREATE_C_FLAGS
"
${
CMAKE_SHARED_
MODULE
_CREATE_C_FLAGS
}
-L
${
CONTRIB_LIB
}
"
)
set
(
CMAKE_SHARED_LIBRARY_CREATE_CXX_FLAGS
"
${
CMAKE_SHARED_
MODULE
_CREATE_CXX_FLAGS
}
-L
${
CONTRIB_LIB
}
"
)
set
(
CMAKE_SHARED_LIBRARY_CREATE_C_FLAGS
"
${
CMAKE_SHARED_
LIBRARY
_CREATE_C_FLAGS
}
-L
${
CONTRIB_LIB
}
"
)
set
(
CMAKE_SHARED_LIBRARY_CREATE_CXX_FLAGS
"
${
CMAKE_SHARED_
LIBRARY
_CREATE_CXX_FLAGS
}
-L
${
CONTRIB_LIB
}
"
)
add_definitions
(
-I
${
CONTRIB_INCLUDE
}
)
endif
(
ENABLE_CONTRIB
)
...
...
@@ -307,10 +301,21 @@ find_package(Dlopen)
set
(
HAVE_DL_DLOPEN
${
Dlopen_FOUND
}
)
find_package
(
FFmpeg
)
vlc_check_include_files
(
ffmpeg/avcodec.h
)
vlc_check_include_files
(
postproc/postprocess.h
)
vlc_add_module_compile_flag
(
ffmpeg
${
FFmpeg_CFLAGS
}
)
vlc_module_add_link_libraries
(
ffmpeg
${
FFmpeg_LIBRARIES
}
)
if
(
FFmpeg_FOUND
)
vlc_check_include_files
(
ffmpeg/avcodec.h
)
vlc_check_include_files
(
postproc/postprocess.h
)
vlc_enable_modules
(
ffmpeg
)
vlc_add_module_compile_flag
(
ffmpeg
${
FFmpeg_CFLAGS
}
)
vlc_module_add_link_libraries
(
ffmpeg
${
FFmpeg_LIBRARIES
}
)
endif
(
FFmpeg_FOUND
)
find_package
(
Lua
)
if
(
Lua_FOUND
)
set
(
HAVE_LUA TRUE
)
vlc_enable_modules
(
lua
)
vlc_add_module_compile_flag
(
lua
${
Lua_CFLAGS
}
)
vlc_module_add_link_libraries
(
lua
${
Lua_LIBRARIES
}
)
endif
(
Lua_FOUND
)
set
(
CMAKE_REQUIRED_INCLUDES
)
...
...
extras/buildsystem/cmake/include/vlc_module_funcs.cmake
View file @
faaf778a
...
...
@@ -15,9 +15,14 @@ MACRO(vlc_add_module module_name)
endif
(
ENABLE_VLC_MODULE_
${
module_name
}
)
ENDMACRO
(
vlc_add_module
)
MACRO
(
vlc_register_modules state
)
MACRO
(
vlc_register_modules
module_
state
)
foreach
(
module_name
${
ARGN
}
)
OPTION
(
ENABLE_VLC_MODULE_
${
module_name
}
"Enable the
${
module_name
}
module"
${
state
}
)
set
(
STATE module_state
)
if
(
STATE
)
set
(
VLC_ENABLED_MODULES_LIST
${
VLC_ENABLED_MODULES_LIST
}
${
module_name
}
_plugin
)
else
(
STATE
)
endif
(
STATE
)
OPTION
(
ENABLE_VLC_MODULE_
${
module_name
}
"Enable the
${
module_name
}
module"
${
module_state
}
)
endforeach
(
module_name
)
ENDMACRO
(
vlc_register_modules
)
...
...
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