mirror of
https://github.com/citra-emu/citra.git
synced 2024-11-25 00:21:05 +00:00
CMake cleanup
Several cleanups to the buildsystem: - Do better factoring of common libs between platforms. - Add support to building on Windows. - Remove Qt4 support. - Re-sort file lists and add missing headers.
This commit is contained in:
parent
523385955c
commit
45976da975
@ -8,10 +8,16 @@ if [ "$TRAVIS_OS_NAME" = linux -o -z "$TRAVIS_OS_NAME" ]; then
|
|||||||
sudo apt-get -qq update
|
sudo apt-get -qq update
|
||||||
sudo apt-get -qq install g++-4.8 xorg-dev libglu1-mesa-dev libxcursor-dev
|
sudo apt-get -qq install g++-4.8 xorg-dev libglu1-mesa-dev libxcursor-dev
|
||||||
sudo update-alternatives --install /usr/bin/g++ g++ /usr/bin/g++-4.8 90
|
sudo update-alternatives --install /usr/bin/g++ g++ /usr/bin/g++-4.8 90
|
||||||
git clone https://github.com/glfw/glfw.git
|
(
|
||||||
mkdir glfw/build && cd glfw/build
|
git clone https://github.com/glfw/glfw.git --branch 3.0.4 --depth 1
|
||||||
cmake .. && make && sudo make install
|
mkdir glfw/build && cd glfw/build
|
||||||
cd -
|
cmake .. && make -j2 && sudo make install
|
||||||
|
)
|
||||||
|
|
||||||
|
sudo apt-get install lib32stdc++6
|
||||||
|
sudo mkdir -p /usr/local
|
||||||
|
curl http://www.cmake.org/files/v2.8/cmake-2.8.11-Linux-i386.tar.gz \
|
||||||
|
| sudo tar -xz -C /usr/local --strip-components=1
|
||||||
elif [ "$TRAVIS_OS_NAME" = osx ]; then
|
elif [ "$TRAVIS_OS_NAME" = osx ]; then
|
||||||
brew tap homebrew/versions
|
brew tap homebrew/versions
|
||||||
brew install qt5 glfw3 pkgconfig
|
brew install qt5 glfw3 pkgconfig
|
||||||
|
149
CMakeLists.txt
149
CMakeLists.txt
@ -1,78 +1,131 @@
|
|||||||
cmake_minimum_required(VERSION 2.8.7)
|
# CMake 2.8.11 required for Qt5 settings to be applied automatically on
|
||||||
|
# dependent libraries.
|
||||||
|
cmake_minimum_required(VERSION 2.8.11)
|
||||||
|
|
||||||
project(citra)
|
project(citra)
|
||||||
|
|
||||||
SET(CXX_COMPILE_FLAGS "-std=c++11")
|
if (NOT MSVC)
|
||||||
|
set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -std=c++11 -Wno-attributes")
|
||||||
# silence some spam
|
else()
|
||||||
add_definitions(-Wno-attributes)
|
# Silence deprecation warnings
|
||||||
|
add_definitions(/D_CRT_SECURE_NO_WARNINGS)
|
||||||
|
endif()
|
||||||
add_definitions(-DSINGLETHREADED)
|
add_definitions(-DSINGLETHREADED)
|
||||||
add_definitions(${CXX_COMPILE_FLAGS})
|
|
||||||
|
|
||||||
find_package(PNG)
|
find_package(PNG)
|
||||||
if (PNG_FOUND)
|
if (PNG_FOUND)
|
||||||
add_definitions(-DHAVE_PNG)
|
add_definitions(-DHAVE_PNG)
|
||||||
endif ()
|
endif ()
|
||||||
|
|
||||||
# dependency checking
|
# Include bundled CMake modules
|
||||||
list(APPEND CMAKE_MODULE_PATH "${CMAKE_CURRENT_SOURCE_DIR}/externals/cmake-modules/")
|
list(APPEND CMAKE_MODULE_PATH "${CMAKE_SOURCE_DIR}/externals/cmake-modules")
|
||||||
set(CMAKE_MODULE_PATH ${CMAKE_MODULE_PATH} ${CMAKE_SOURCE_DIR}/CMakeTests)
|
|
||||||
include(FindX11 REQUIRED)
|
|
||||||
find_package(PkgConfig REQUIRED)
|
|
||||||
find_package(OpenGL REQUIRED)
|
find_package(OpenGL REQUIRED)
|
||||||
pkg_search_module(GLFW REQUIRED glfw3)
|
|
||||||
|
|
||||||
# corefoundation is required only on OSX
|
|
||||||
IF (APPLE)
|
|
||||||
FIND_LIBRARY(COREFOUNDATION_LIBRARY CoreFoundation)
|
|
||||||
SET(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -stdlib=libc++")
|
|
||||||
SET(CMAKE_EXE_LINKER_FLAGS "${CMAKE_EXE_LINKER_FLAGS} -stdlib=libc++")
|
|
||||||
ENDIF (APPLE)
|
|
||||||
|
|
||||||
#external includes
|
|
||||||
include_directories(${GLFW_INCLUDE_DIRS})
|
|
||||||
include_directories(${OPENGL_INCLUDE_DIR})
|
include_directories(${OPENGL_INCLUDE_DIR})
|
||||||
|
|
||||||
# workaround for GLFW linking on OSX
|
option(ENABLE_GLFW "Enable the GLFW frontend" ON)
|
||||||
link_directories(${GLFW_LIBRARY_DIRS})
|
if (ENABLE_GLFW)
|
||||||
|
if (WIN32)
|
||||||
|
# Detect toolchain and platform
|
||||||
|
if (MSVC)
|
||||||
|
if (CMAKE_SIZEOF_VOID_P EQUAL 8)
|
||||||
|
set(TMP_ARCH "x64")
|
||||||
|
else()
|
||||||
|
set(TMP_ARCH "Win32")
|
||||||
|
endif()
|
||||||
|
|
||||||
option(DISABLE_QT "Disable Qt GUI" OFF)
|
if (MSVC11) # Visual C++ 2012
|
||||||
option(USE_QT5 "Use Qt5 when available" ON)
|
set(TMP_TOOLSET "v110")
|
||||||
if (NOT DISABLE_QT)
|
elseif (MSVC12) # Visual C++ 2013
|
||||||
if(USE_QT5)
|
set(TMP_TOOLSET "v120")
|
||||||
find_package(Qt5Gui)
|
else()
|
||||||
find_package(Qt5Widgets)
|
set(TMP_TOOLSET "UNSUPPORTED")
|
||||||
find_package(Qt5OpenGL)
|
message(SEND_ERROR "We don't supply GLFW binaries for your version of MSVC, you might have to provide them yourself.")
|
||||||
if(NOT Qt5Gui_FOUND OR NOT Qt5Widgets_FOUND OR NOT Qt5OpenGL_FOUND)
|
endif()
|
||||||
message("Qt5 libraries not found! Using Qt4 instead.")
|
|
||||||
set(USE_QT5 OFF)
|
|
||||||
endif()
|
|
||||||
endif()
|
|
||||||
if(NOT USE_QT5)
|
|
||||||
include(FindQt4)
|
|
||||||
find_package(Qt4 COMPONENTS QtCore QtGui QtOpenGL)
|
|
||||||
|
|
||||||
if(QT4_FOUND AND QT_QTCORE_FOUND AND QT_QTGUI_FOUND AND QT_QTOPENGL_FOUND)
|
set(TMP_TOOLSET "msvc_${TMP_TOOLSET}-${TMP_ARCH}")
|
||||||
include(${QT_USE_FILE})
|
|
||||||
include_directories(${QT_INCLUDES})
|
|
||||||
else()
|
else()
|
||||||
message("Qt4 libraries not found! Disabling Qt GUI")
|
# Assume mingw
|
||||||
set(DISABLE_QT ON)
|
if (CMAKE_SIZEOF_VOID_P EQUAL 8)
|
||||||
|
set(TMP_ARCH "x86_64")
|
||||||
|
else()
|
||||||
|
set(TMP_ARCH "i686")
|
||||||
|
endif()
|
||||||
|
|
||||||
|
set(TMP_TOOLSET "mingw-${TMP_ARCH}")
|
||||||
endif()
|
endif()
|
||||||
|
|
||||||
|
set(GLFW_PREFIX "${CMAKE_CURRENT_SOURCE_DIR}/externals/glfw-3.0.4.bin")
|
||||||
|
set(GLFW_INCLUDE_DIRS "${GLFW_PREFIX}/include" CACHE PATH "Path to GLFW3 headers")
|
||||||
|
set(GLFW_LIBRARY_DIRS "${GLFW_PREFIX}/lib-${TMP_TOOLSET}" CACHE PATH "Path to GLFW3 libraries")
|
||||||
|
|
||||||
|
# Clean up after ourselves
|
||||||
|
unset(TMP_TOOLSET)
|
||||||
|
unset(TMP_ARCH)
|
||||||
|
|
||||||
|
set(GLFW_LIBRARIES glfw3)
|
||||||
|
else()
|
||||||
|
find_package(X11 REQUIRED)
|
||||||
|
find_package(PkgConfig REQUIRED)
|
||||||
|
pkg_search_module(GLFW REQUIRED glfw3)
|
||||||
|
endif()
|
||||||
|
|
||||||
|
include_directories(${GLFW_INCLUDE_DIRS})
|
||||||
|
link_directories(${GLFW_LIBRARY_DIRS})
|
||||||
|
endif()
|
||||||
|
|
||||||
|
IF (APPLE)
|
||||||
|
# CoreFoundation is required only on OSX
|
||||||
|
FIND_LIBRARY(COREFOUNDATION_LIBRARY CoreFoundation)
|
||||||
|
set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -stdlib=libc++")
|
||||||
|
set(CMAKE_EXE_LINKER_FLAGS "${CMAKE_EXE_LINKER_FLAGS} -stdlib=libc++")
|
||||||
|
ENDIF (APPLE)
|
||||||
|
|
||||||
|
option(ENABLE_QT "Enable the Qt frontend" ON)
|
||||||
|
option(CITRA_FORCE_QT4 "Use Qt4 even if Qt5 is available." OFF)
|
||||||
|
if (ENABLE_QT)
|
||||||
|
# Set CMAKE_PREFIX_PATH if QTDIR is defined in the environment This allows CMake to
|
||||||
|
# automatically find the Qt packages on Windows
|
||||||
|
if (DEFINED ENV{QTDIR})
|
||||||
|
list(APPEND CMAKE_PREFIX_PATH "$ENV{QTDIR}")
|
||||||
|
endif()
|
||||||
|
|
||||||
|
if (NOT CITRA_FORCE_QT4)
|
||||||
|
find_package(Qt5 COMPONENTS Widgets OpenGL)
|
||||||
|
set(CITRA_QT_LIBS Qt5::Widgets Qt5::OpenGL)
|
||||||
|
endif()
|
||||||
|
|
||||||
|
if (CITRA_FORCE_QT4 OR NOT Qt5_FOUND)
|
||||||
|
# Try to fallback to Qt4
|
||||||
|
find_package(Qt4 REQUIRED COMPONENTS QtGui QtOpenGL)
|
||||||
|
set(CITRA_QT_LIBS Qt4::QtGui Qt4::QtOpenGL)
|
||||||
endif()
|
endif()
|
||||||
endif()
|
endif()
|
||||||
|
|
||||||
|
# This function should be passed a list of all files in a target. It will automatically generate
|
||||||
|
# file groups following the directory hierarchy, so that the layout of the files in IDEs matches the
|
||||||
|
# one in the filesystem.
|
||||||
|
function(create_directory_groups)
|
||||||
|
# Place any files that aren't in the source list in a separate group so that they don't get in
|
||||||
|
# the way.
|
||||||
|
source_group("Other Files" REGULAR_EXPRESSION ".")
|
||||||
|
|
||||||
|
foreach(file_name ${ARGV})
|
||||||
|
get_filename_component(dir_name "${file_name}" PATH)
|
||||||
|
# Group names use '\' as a separator even though the entire rest of CMake uses '/'...
|
||||||
|
string(REPLACE "/" "\\" group_name "${dir_name}")
|
||||||
|
source_group("${group_name}" FILES "${file_name}")
|
||||||
|
endforeach()
|
||||||
|
endfunction()
|
||||||
|
|
||||||
# generate git revision information
|
# generate git revision information
|
||||||
include(GetGitRevisionDescription)
|
include(GetGitRevisionDescription)
|
||||||
get_git_head_revision(GIT_REF_SPEC GIT_REV)
|
get_git_head_revision(GIT_REF_SPEC GIT_REV)
|
||||||
git_describe(GIT_DESC --always --long --dirty)
|
git_describe(GIT_DESC --always --long --dirty)
|
||||||
git_branch_name(GIT_BRANCH)
|
git_branch_name(GIT_BRANCH)
|
||||||
|
|
||||||
# internal includes
|
|
||||||
include_directories(src)
|
|
||||||
|
|
||||||
# process subdirectories
|
# process subdirectories
|
||||||
if(NOT DISABLE_QT)
|
if(ENABLE_QT)
|
||||||
include_directories(externals/qhexedit)
|
include_directories(externals/qhexedit)
|
||||||
add_subdirectory(externals/qhexedit)
|
add_subdirectory(externals/qhexedit)
|
||||||
endif()
|
endif()
|
||||||
|
15
externals/qhexedit/CMakeLists.txt
vendored
15
externals/qhexedit/CMakeLists.txt
vendored
@ -5,14 +5,17 @@ set(SRCS
|
|||||||
commands.cpp
|
commands.cpp
|
||||||
qhexedit.cpp
|
qhexedit.cpp
|
||||||
qhexedit_p.cpp
|
qhexedit_p.cpp
|
||||||
xbytearray.cpp)
|
xbytearray.cpp
|
||||||
|
)
|
||||||
|
|
||||||
set(HEADERS
|
set(HEADERS
|
||||||
|
commands.h
|
||||||
qhexedit.h
|
qhexedit.h
|
||||||
qhexedit_p.h)
|
qhexedit_p.h
|
||||||
|
xbytearray.h
|
||||||
|
)
|
||||||
|
|
||||||
|
create_directory_groups(${SRCS} ${HEADERS})
|
||||||
|
|
||||||
add_library(qhexedit STATIC ${SRCS} ${HEADERS})
|
add_library(qhexedit STATIC ${SRCS} ${HEADERS})
|
||||||
if(USE_QT5)
|
target_link_libraries(qhexedit ${CITRA_QT_LIBS})
|
||||||
target_link_libraries(qhexedit Qt5::Core Qt5::Widgets)
|
|
||||||
endif()
|
|
||||||
|
|
||||||
|
@ -1,9 +1,12 @@
|
|||||||
|
# Enable modules to include each other's files
|
||||||
|
include_directories(.)
|
||||||
|
|
||||||
add_subdirectory(common)
|
add_subdirectory(common)
|
||||||
add_subdirectory(core)
|
add_subdirectory(core)
|
||||||
add_subdirectory(video_core)
|
add_subdirectory(video_core)
|
||||||
add_subdirectory(citra)
|
if (ENABLE_GLFW)
|
||||||
add_subdirectory(citra_qt)
|
add_subdirectory(citra)
|
||||||
|
endif()
|
||||||
if(QT4_FOUND AND QT_QTCORE_FOUND AND QT_QTGUI_FOUND AND QT_QTOPENGL_FOUND AND NOT DISABLE_QT4)
|
if (ENABLE_QT)
|
||||||
#add_subdirectory(citra_qt)
|
add_subdirectory(citra_qt)
|
||||||
endif()
|
endif()
|
||||||
|
@ -1,6 +1,13 @@
|
|||||||
set(SRCS citra.cpp
|
set(SRCS
|
||||||
emu_window/emu_window_glfw.cpp)
|
emu_window/emu_window_glfw.cpp
|
||||||
set(HEADERS resource.h)
|
citra.cpp
|
||||||
|
)
|
||||||
|
set(HEADERS
|
||||||
|
emu_window/emu_window_glfw.h
|
||||||
|
resource.h
|
||||||
|
)
|
||||||
|
|
||||||
|
create_directory_groups(${SRCS} ${HEADERS})
|
||||||
|
|
||||||
# NOTE: This is a workaround for CMake bug 0006976 (missing X11_xf86vmode_LIB variable)
|
# NOTE: This is a workaround for CMake bug 0006976 (missing X11_xf86vmode_LIB variable)
|
||||||
if (NOT X11_xf86vmode_LIB)
|
if (NOT X11_xf86vmode_LIB)
|
||||||
@ -8,11 +15,16 @@ if (NOT X11_xf86vmode_LIB)
|
|||||||
endif()
|
endif()
|
||||||
|
|
||||||
add_executable(citra ${SRCS} ${HEADERS})
|
add_executable(citra ${SRCS} ${HEADERS})
|
||||||
|
target_link_libraries(citra core common video_core)
|
||||||
|
target_link_libraries(citra ${OPENGL_gl_LIBRARY} ${GLFW_LIBRARIES})
|
||||||
|
|
||||||
if (APPLE)
|
if (APPLE)
|
||||||
target_link_libraries(citra core common video_core iconv pthread ${COREFOUNDATION_LIBRARY} ${OPENGL_LIBRARIES} ${GLFW_LIBRARIES})
|
target_link_libraries(citra iconv pthread ${COREFOUNDATION_LIBRARY})
|
||||||
else()
|
elseif (WIN32)
|
||||||
target_link_libraries(citra core common video_core pthread X11 Xxf86vm Xi Xcursor ${OPENGL_LIBRARIES} ${GLFW_LIBRARIES} rt ${X11_Xrandr_LIB} ${X11_xv86vmode_LIB} ${PNG_LIBRARIES})
|
target_link_libraries(citra winmm)
|
||||||
|
else() # Unix
|
||||||
|
target_link_libraries(citra pthread rt)
|
||||||
|
target_link_libraries(citra ${X11_X11_LIB} ${X11_Xi_LIB} ${X11_Xcursor_LIB} ${X11_Xrandr_LIB} ${X11_xv86vmode_LIB})
|
||||||
endif()
|
endif()
|
||||||
|
|
||||||
#install(TARGETS citra RUNTIME DESTINATION ${bindir})
|
#install(TARGETS citra RUNTIME DESTINATION ${bindir})
|
||||||
|
@ -2,54 +2,61 @@ set(CMAKE_AUTOMOC ON)
|
|||||||
set(CMAKE_INCLUDE_CURRENT_DIR ON)
|
set(CMAKE_INCLUDE_CURRENT_DIR ON)
|
||||||
|
|
||||||
set(SRCS
|
set(SRCS
|
||||||
bootmanager.cpp
|
config/controller_config.cpp
|
||||||
|
config/controller_config_util.cpp
|
||||||
debugger/callstack.cpp
|
debugger/callstack.cpp
|
||||||
debugger/disassembler.cpp
|
debugger/disassembler.cpp
|
||||||
debugger/graphics.cpp
|
debugger/graphics.cpp
|
||||||
debugger/graphics_cmdlists.cpp
|
debugger/graphics_cmdlists.cpp
|
||||||
debugger/ramview.cpp
|
debugger/ramview.cpp
|
||||||
debugger/registers.cpp
|
debugger/registers.cpp
|
||||||
|
bootmanager.cpp
|
||||||
hotkeys.cpp
|
hotkeys.cpp
|
||||||
main.cpp
|
main.cpp
|
||||||
config/controller_config.cpp
|
)
|
||||||
config/controller_config_util.cpp)
|
|
||||||
|
|
||||||
set(HEADERS
|
set(HEADERS
|
||||||
bootmanager.hxx
|
config/controller_config.hxx
|
||||||
|
config/controller_config_util.hxx
|
||||||
debugger/callstack.hxx
|
debugger/callstack.hxx
|
||||||
debugger/disassembler.hxx
|
debugger/disassembler.hxx
|
||||||
|
debugger/graphics.hxx
|
||||||
|
debugger/graphics_cmdlists.hxx
|
||||||
debugger/ramview.hxx
|
debugger/ramview.hxx
|
||||||
debugger/registers.hxx
|
debugger/registers.hxx
|
||||||
|
bootmanager.hxx
|
||||||
hotkeys.hxx
|
hotkeys.hxx
|
||||||
main.hxx
|
main.hxx
|
||||||
version.h
|
version.h
|
||||||
config/controller_config.hxx
|
)
|
||||||
config/controller_config_util.hxx)
|
|
||||||
|
|
||||||
set(UIS
|
set(UIS
|
||||||
|
config/controller_config.ui
|
||||||
debugger/callstack.ui
|
debugger/callstack.ui
|
||||||
debugger/disassembler.ui
|
debugger/disassembler.ui
|
||||||
debugger/registers.ui
|
debugger/registers.ui
|
||||||
hotkeys.ui
|
hotkeys.ui
|
||||||
main.ui
|
main.ui
|
||||||
config/controller_config.ui)
|
)
|
||||||
|
|
||||||
if(USE_QT5)
|
create_directory_groups(${SRCS} ${HEADERS} ${UIS})
|
||||||
|
|
||||||
|
if (Qt5_FOUND)
|
||||||
qt5_wrap_ui(UI_HDRS ${UIS})
|
qt5_wrap_ui(UI_HDRS ${UIS})
|
||||||
else()
|
else()
|
||||||
qt4_wrap_ui(UI_HDRS ${UIS})
|
qt4_wrap_ui(UI_HDRS ${UIS})
|
||||||
endif()
|
endif()
|
||||||
|
|
||||||
add_executable(citra-qt ${SRCS} ${HEADERS} ${UI_HDRS})
|
add_executable(citra-qt ${SRCS} ${HEADERS} ${UI_HDRS})
|
||||||
if(APPLE)
|
target_link_libraries(citra-qt core common video_core qhexedit)
|
||||||
set(ICONV_LIBRARY iconv)
|
target_link_libraries(citra-qt ${OPENGL_gl_LIBRARY} ${CITRA_QT_LIBS})
|
||||||
else()
|
|
||||||
set(RT_LIBRARY rt)
|
|
||||||
endif()
|
|
||||||
|
|
||||||
target_link_libraries(citra-qt core common video_core qhexedit ${ICONV_LIBRARY} ${COREFOUNDATION_LIBRARY} ${QT_LIBRARIES} ${OPENGL_LIBRARIES} ${RT_LIBRARY} ${PNG_LIBRARIES})
|
if (APPLE)
|
||||||
if(USE_QT5)
|
target_link_libraries(citra-qt iconv ${COREFOUNDATION_LIBRARY})
|
||||||
target_link_libraries(citra-qt Qt5::Gui Qt5::Widgets Qt5::OpenGL)
|
elseif (WIN32)
|
||||||
|
target_link_libraries(citra-qt winmm)
|
||||||
|
else() # Unix
|
||||||
|
target_link_libraries(citra-qt rt)
|
||||||
endif()
|
endif()
|
||||||
|
|
||||||
#install(TARGETS citra-qt RUNTIME DESTINATION ${bindir})
|
#install(TARGETS citra-qt RUNTIME DESTINATION ${bindir})
|
||||||
|
@ -1,6 +1,8 @@
|
|||||||
|
# Generate cpp with Git revision from template
|
||||||
configure_file("${CMAKE_CURRENT_SOURCE_DIR}/scm_rev.cpp.in" "${CMAKE_CURRENT_SOURCE_DIR}/scm_rev.cpp" @ONLY)
|
configure_file("${CMAKE_CURRENT_SOURCE_DIR}/scm_rev.cpp.in" "${CMAKE_CURRENT_SOURCE_DIR}/scm_rev.cpp" @ONLY)
|
||||||
|
|
||||||
set(SRCS break_points.cpp
|
set(SRCS
|
||||||
|
break_points.cpp
|
||||||
console_listener.cpp
|
console_listener.cpp
|
||||||
extended_trace.cpp
|
extended_trace.cpp
|
||||||
file_search.cpp
|
file_search.cpp
|
||||||
@ -12,23 +14,25 @@ set(SRCS break_points.cpp
|
|||||||
memory_util.cpp
|
memory_util.cpp
|
||||||
misc.cpp
|
misc.cpp
|
||||||
msg_handler.cpp
|
msg_handler.cpp
|
||||||
string_util.cpp
|
|
||||||
scm_rev.cpp
|
scm_rev.cpp
|
||||||
|
string_util.cpp
|
||||||
symbols.cpp
|
symbols.cpp
|
||||||
thread.cpp
|
thread.cpp
|
||||||
timer.cpp
|
timer.cpp
|
||||||
utf8.cpp)
|
utf8.cpp
|
||||||
|
)
|
||||||
|
|
||||||
set(HEADERS atomic.h
|
set(HEADERS
|
||||||
|
atomic.h
|
||||||
atomic_gcc.h
|
atomic_gcc.h
|
||||||
atomic_win32.h
|
atomic_win32.h
|
||||||
bit_field.h
|
bit_field.h
|
||||||
break_points.h
|
break_points.h
|
||||||
chunk_file.h
|
chunk_file.h
|
||||||
|
common.h
|
||||||
common_funcs.h
|
common_funcs.h
|
||||||
common_paths.h
|
common_paths.h
|
||||||
common_types.h
|
common_types.h
|
||||||
common.h
|
|
||||||
console_listener.h
|
console_listener.h
|
||||||
cpu_detect.h
|
cpu_detect.h
|
||||||
debug_interface.h
|
debug_interface.h
|
||||||
@ -37,10 +41,11 @@ set(HEADERS atomic.h
|
|||||||
fifo_queue.h
|
fifo_queue.h
|
||||||
file_search.h
|
file_search.h
|
||||||
file_util.h
|
file_util.h
|
||||||
|
fixed_size_queue.h
|
||||||
hash.h
|
hash.h
|
||||||
linear_disk_cache.h
|
linear_disk_cache.h
|
||||||
log_manager.h
|
|
||||||
log.h
|
log.h
|
||||||
|
log_manager.h
|
||||||
math_util.h
|
math_util.h
|
||||||
mem_arena.h
|
mem_arena.h
|
||||||
memory_util.h
|
memory_util.h
|
||||||
@ -54,8 +59,12 @@ set(HEADERS atomic.h
|
|||||||
swap.h
|
swap.h
|
||||||
symbols.h
|
symbols.h
|
||||||
thread.h
|
thread.h
|
||||||
|
thread_queue_list.h
|
||||||
thunk.h
|
thunk.h
|
||||||
timer.h
|
timer.h
|
||||||
utf8.h)
|
utf8.h
|
||||||
|
)
|
||||||
|
|
||||||
|
create_directory_groups(${SRCS} ${HEADERS})
|
||||||
|
|
||||||
add_library(common STATIC ${SRCS} ${HEADERS})
|
add_library(common STATIC ${SRCS} ${HEADERS})
|
||||||
|
@ -1,14 +1,18 @@
|
|||||||
set(SRCS core.cpp
|
set(SRCS
|
||||||
core_timing.cpp
|
|
||||||
loader/elf.cpp
|
|
||||||
loader/loader.cpp
|
|
||||||
loader/ncch.cpp
|
|
||||||
mem_map.cpp
|
|
||||||
mem_map_funcs.cpp
|
|
||||||
system.cpp
|
|
||||||
arm/disassembler/arm_disasm.cpp
|
arm/disassembler/arm_disasm.cpp
|
||||||
arm/disassembler/load_symbol_map.cpp
|
arm/disassembler/load_symbol_map.cpp
|
||||||
file_sys/archive_romfs.cpp
|
arm/interpreter/mmu/arm1176jzf_s_mmu.cpp
|
||||||
|
arm/interpreter/mmu/cache.cpp
|
||||||
|
arm/interpreter/mmu/maverick.cpp
|
||||||
|
arm/interpreter/mmu/rb.cpp
|
||||||
|
arm/interpreter/mmu/sa_mmu.cpp
|
||||||
|
arm/interpreter/mmu/tlb.cpp
|
||||||
|
arm/interpreter/mmu/wb.cpp
|
||||||
|
arm/interpreter/mmu/xscale_copro.cpp
|
||||||
|
arm/interpreter/vfp/vfp.cpp
|
||||||
|
arm/interpreter/vfp/vfpdouble.cpp
|
||||||
|
arm/interpreter/vfp/vfpinstr.cpp
|
||||||
|
arm/interpreter/vfp/vfpsingle.cpp
|
||||||
arm/interpreter/arm_interpreter.cpp
|
arm/interpreter/arm_interpreter.cpp
|
||||||
arm/interpreter/armcopro.cpp
|
arm/interpreter/armcopro.cpp
|
||||||
arm/interpreter/armemu.cpp
|
arm/interpreter/armemu.cpp
|
||||||
@ -18,22 +22,7 @@ set(SRCS core.cpp
|
|||||||
arm/interpreter/armsupp.cpp
|
arm/interpreter/armsupp.cpp
|
||||||
arm/interpreter/armvirt.cpp
|
arm/interpreter/armvirt.cpp
|
||||||
arm/interpreter/thumbemu.cpp
|
arm/interpreter/thumbemu.cpp
|
||||||
arm/interpreter/vfp/vfp.cpp
|
file_sys/archive_romfs.cpp
|
||||||
arm/interpreter/vfp/vfpdouble.cpp
|
|
||||||
arm/interpreter/vfp/vfpinstr.cpp
|
|
||||||
arm/interpreter/vfp/vfpsingle.cpp
|
|
||||||
arm/interpreter/mmu/arm1176jzf_s_mmu.cpp
|
|
||||||
arm/interpreter/mmu/cache.cpp
|
|
||||||
arm/interpreter/mmu/maverick.cpp
|
|
||||||
arm/interpreter/mmu/rb.cpp
|
|
||||||
arm/interpreter/mmu/sa_mmu.cpp
|
|
||||||
arm/interpreter/mmu/tlb.cpp
|
|
||||||
arm/interpreter/mmu/wb.cpp
|
|
||||||
arm/interpreter/mmu/xscale_copro.cpp
|
|
||||||
hle/hle.cpp
|
|
||||||
hle/config_mem.cpp
|
|
||||||
hle/coprocessor.cpp
|
|
||||||
hle/svc.cpp
|
|
||||||
hle/kernel/address_arbiter.cpp
|
hle/kernel/address_arbiter.cpp
|
||||||
hle/kernel/archive.cpp
|
hle/kernel/archive.cpp
|
||||||
hle/kernel/event.cpp
|
hle/kernel/event.cpp
|
||||||
@ -48,27 +37,26 @@ set(SRCS core.cpp
|
|||||||
hle/service/ndm.cpp
|
hle/service/ndm.cpp
|
||||||
hle/service/service.cpp
|
hle/service/service.cpp
|
||||||
hle/service/srv.cpp
|
hle/service/srv.cpp
|
||||||
|
hle/config_mem.cpp
|
||||||
|
hle/coprocessor.cpp
|
||||||
|
hle/hle.cpp
|
||||||
|
hle/svc.cpp
|
||||||
hw/gpu.cpp
|
hw/gpu.cpp
|
||||||
hw/hw.cpp
|
hw/hw.cpp
|
||||||
hw/ndma.cpp)
|
hw/ndma.cpp
|
||||||
|
loader/elf.cpp
|
||||||
|
loader/loader.cpp
|
||||||
|
loader/ncch.cpp
|
||||||
|
core.cpp
|
||||||
|
core_timing.cpp
|
||||||
|
mem_map.cpp
|
||||||
|
mem_map_funcs.cpp
|
||||||
|
system.cpp
|
||||||
|
)
|
||||||
|
|
||||||
set(HEADERS core.h
|
set(HEADERS
|
||||||
core_timing.h
|
|
||||||
loader/elf.h
|
|
||||||
loader/loader.h
|
|
||||||
loader/ncch.h
|
|
||||||
mem_map.h
|
|
||||||
system.h
|
|
||||||
arm/disassembler/arm_disasm.h
|
arm/disassembler/arm_disasm.h
|
||||||
arm/disassembler/load_symbol_map.h
|
arm/disassembler/load_symbol_map.h
|
||||||
arm/interpreter/arm_interpreter.h
|
|
||||||
arm/interpreter/arm_regformat.h
|
|
||||||
arm/interpreter/armcpu.h
|
|
||||||
arm/interpreter/armdefs.h
|
|
||||||
arm/interpreter/armemu.h
|
|
||||||
arm/interpreter/armmmu.h
|
|
||||||
arm/interpreter/armos.h
|
|
||||||
arm/interpreter/skyeye_defs.h
|
|
||||||
arm/interpreter/mmu/arm1176jzf_s_mmu.h
|
arm/interpreter/mmu/arm1176jzf_s_mmu.h
|
||||||
arm/interpreter/mmu/cache.h
|
arm/interpreter/mmu/cache.h
|
||||||
arm/interpreter/mmu/rb.h
|
arm/interpreter/mmu/rb.h
|
||||||
@ -78,27 +66,48 @@ set(HEADERS core.h
|
|||||||
arm/interpreter/vfp/asm_vfp.h
|
arm/interpreter/vfp/asm_vfp.h
|
||||||
arm/interpreter/vfp/vfp.h
|
arm/interpreter/vfp/vfp.h
|
||||||
arm/interpreter/vfp/vfp_helper.h
|
arm/interpreter/vfp/vfp_helper.h
|
||||||
|
arm/interpreter/arm_interpreter.h
|
||||||
|
arm/interpreter/arm_regformat.h
|
||||||
|
arm/interpreter/armcpu.h
|
||||||
|
arm/interpreter/armdefs.h
|
||||||
|
arm/interpreter/armemu.h
|
||||||
|
arm/interpreter/armmmu.h
|
||||||
|
arm/interpreter/armos.h
|
||||||
|
arm/interpreter/skyeye_defs.h
|
||||||
|
arm/arm_interface.h
|
||||||
file_sys/archive.h
|
file_sys/archive.h
|
||||||
file_sys/archive_romfs.h
|
file_sys/archive_romfs.h
|
||||||
hle/config_mem.h
|
|
||||||
hle/coprocessor.h
|
|
||||||
hle/hle.h
|
|
||||||
hle/svc.h
|
|
||||||
hle/kernel/address_arbiter.h
|
hle/kernel/address_arbiter.h
|
||||||
hle/kernel/archive.h
|
hle/kernel/archive.h
|
||||||
|
hle/kernel/event.h
|
||||||
hle/kernel/kernel.h
|
hle/kernel/kernel.h
|
||||||
hle/kernel/mutex.h
|
hle/kernel/mutex.h
|
||||||
hle/kernel/shared_memory.h
|
hle/kernel/shared_memory.h
|
||||||
hle/kernel/thread.h
|
hle/kernel/thread.h
|
||||||
hle/function_wrappers.h
|
|
||||||
hle/service/apt.h
|
hle/service/apt.h
|
||||||
hle/service/fs.h
|
hle/service/fs.h
|
||||||
hle/service/gsp.h
|
hle/service/gsp.h
|
||||||
hle/service/hid.h
|
hle/service/hid.h
|
||||||
|
hle/service/ndm.h
|
||||||
hle/service/service.h
|
hle/service/service.h
|
||||||
hle/service/srv.h
|
hle/service/srv.h
|
||||||
|
hle/config_mem.h
|
||||||
|
hle/coprocessor.h
|
||||||
|
hle/function_wrappers.h
|
||||||
|
hle/hle.h
|
||||||
|
hle/svc.h
|
||||||
hw/gpu.h
|
hw/gpu.h
|
||||||
hw/hw.h
|
hw/hw.h
|
||||||
hw/ndma.h)
|
hw/ndma.h
|
||||||
|
loader/elf.h
|
||||||
|
loader/loader.h
|
||||||
|
loader/ncch.h
|
||||||
|
core.h
|
||||||
|
core_timing.h
|
||||||
|
mem_map.h
|
||||||
|
system.h
|
||||||
|
)
|
||||||
|
|
||||||
|
create_directory_groups(${SRCS} ${HEADERS})
|
||||||
|
|
||||||
add_library(core STATIC ${SRCS} ${HEADERS})
|
add_library(core STATIC ${SRCS} ${HEADERS})
|
||||||
|
@ -1,29 +1,42 @@
|
|||||||
set(SRCS clipper.cpp
|
set(SRCS
|
||||||
|
renderer_opengl/generated/gl_3_2_core.c
|
||||||
|
renderer_opengl/renderer_opengl.cpp
|
||||||
|
renderer_opengl/gl_shader_util.cpp
|
||||||
|
debug_utils/debug_utils.cpp
|
||||||
|
clipper.cpp
|
||||||
command_processor.cpp
|
command_processor.cpp
|
||||||
primitive_assembly.cpp
|
primitive_assembly.cpp
|
||||||
rasterizer.cpp
|
rasterizer.cpp
|
||||||
utils.cpp
|
utils.cpp
|
||||||
vertex_shader.cpp
|
vertex_shader.cpp
|
||||||
video_core.cpp
|
video_core.cpp
|
||||||
renderer_opengl/generated/gl_3_2_core.c
|
)
|
||||||
renderer_opengl/renderer_opengl.cpp
|
|
||||||
renderer_opengl/gl_shader_util.cpp
|
|
||||||
debug_utils/debug_utils.cpp)
|
|
||||||
|
|
||||||
set(HEADERS clipper.h
|
set(HEADERS
|
||||||
command_processor.h
|
debug_utils/debug_utils.h
|
||||||
math.h
|
|
||||||
primitive_assembly.h
|
|
||||||
rasterizer.h
|
|
||||||
utils.h
|
|
||||||
video_core.h
|
|
||||||
renderer_base.h
|
|
||||||
vertex_shader.h
|
|
||||||
video_core.h
|
|
||||||
renderer_opengl/generated/gl_3_2_core.h
|
renderer_opengl/generated/gl_3_2_core.h
|
||||||
renderer_opengl/renderer_opengl.h
|
|
||||||
renderer_opengl/gl_shader_util.h
|
renderer_opengl/gl_shader_util.h
|
||||||
renderer_opengl/gl_shaders.h
|
renderer_opengl/gl_shaders.h
|
||||||
debug_utils/debug_utils.h)
|
renderer_opengl/renderer_opengl.h
|
||||||
|
clipper.h
|
||||||
|
command_processor.h
|
||||||
|
gpu_debugger.h
|
||||||
|
math.h
|
||||||
|
pica.h
|
||||||
|
primitive_assembly.h
|
||||||
|
rasterizer.h
|
||||||
|
renderer_base.h
|
||||||
|
utils.h
|
||||||
|
vertex_shader.h
|
||||||
|
video_core.h
|
||||||
|
)
|
||||||
|
|
||||||
|
create_directory_groups(${SRCS} ${HEADERS})
|
||||||
|
|
||||||
add_library(video_core STATIC ${SRCS} ${HEADERS})
|
add_library(video_core STATIC ${SRCS} ${HEADERS})
|
||||||
|
|
||||||
|
if (PNG_FOUND)
|
||||||
|
target_link_libraries(video_core ${PNG_LIBRARIES})
|
||||||
|
include_directories(${PNG_INCLUDE_DIRS})
|
||||||
|
add_definitions(${PNG_DEFINITIONS})
|
||||||
|
endif()
|
||||||
|
Loading…
Reference in New Issue
Block a user