summaryrefslogtreecommitdiff
path: root/plugins/dfnet
diff options
context:
space:
mode:
authorStelios Tsampas <loathingkernel@gmail.com>2017-07-31 16:14:45 +0300
committerStelios Tsampas <loathingkernel@gmail.com>2017-07-31 16:15:15 +0300
commit3912ad309e60ca9e97a72baa9a2e651c6a5ab198 (patch)
treeadd0d8226bdbb187512bf1a62162453228417497 /plugins/dfnet
parent01f49908879197b1715483321a9490dd71c8874b (diff)
downloadpcsxr-3912ad309e60ca9e97a72baa9a2e651c6a5ab198.tar.gz
* Import CMake build system from codeplex
Diffstat (limited to 'plugins/dfnet')
-rw-r--r--plugins/dfnet/CMakeLists.txt60
1 files changed, 60 insertions, 0 deletions
diff --git a/plugins/dfnet/CMakeLists.txt b/plugins/dfnet/CMakeLists.txt
new file mode 100644
index 00000000..9080b98c
--- /dev/null
+++ b/plugins/dfnet/CMakeLists.txt
@@ -0,0 +1,60 @@
+message("Configuring dfnet")
+
+include(GlibCompileResourcesSupport)
+
+#deps
+
+find_package(GLib REQUIRED)
+if(NOT GLib_FOUND)
+ message(FATAL_ERROR "GLIB2 library not found")
+endif(NOT GLib_FOUND)
+include_directories(${GLib_INCLUDE_DIRS})
+
+find_package(GTK3 REQUIRED)
+if(NOT GTK3_FOUND)
+ message(FATAL_ERROR "GTK3 library not found")
+endif(NOT GTK3_FOUND)
+include_directories(${GTK3_INCLUDE_DIRS})
+set(GTK_LIBRARIES ${GTK3_LIBRARY} ${GDK3_LIBRARY} ${GDKPixbuf_LIBRARY} ${Pango_LIBRARY} ${Cairo_LIBRARY} ${GObject_LIBRARY} ${GLib_LIBRARY} ${GIO_LIBRARY})
+
+
+#defs
+add_definitions(-DLOCALE_DIR="${CMAKE_INSTALL_FULL_DATAROOTDIR}/locale/" -DPSEMU_DATA_DIR="${CMAKE_INSTALL_FULL_DATAROOTDIR}/psemu" -DDEF_PLUGIN_DIR="${CMAKE_INSTALL_FULL_LIBDIR}/games/psemu")
+
+#sources
+set(PLUGIN_SRCS
+ cfg.c
+ dfnet.c
+ unix.c
+)
+
+set(GUI_SRCS
+ gui.c
+)
+
+
+#resources
+set(RESOURCE_LIST
+ ${CMAKE_CURRENT_SOURCE_DIR}/dfnet.ui
+)
+
+
+compile_gresources(RESOURCE_FILE
+ XML_OUT
+ TYPE EMBED_C
+ PREFIX /org/pcsxr/dfnet
+ SOURCE_DIR ${CMAKE_CURRENT_SOURCE_DIR}
+ RESOURCES ${RESOURCE_LIST})
+
+add_custom_target(dfnet_resource DEPENDS ${RESOURCE_FILE})
+
+include_directories(${CMAKE_SOURCE_DIR}/libpcsxcore)
+add_library(DFNet MODULE ${PLUGIN_SRCS})
+
+
+add_executable(cfgDFNet ${GUI_SRCS} ${RESOURCE_FILE})
+add_dependencies(cfgDFNet dfnet_resource)
+target_link_libraries(cfgDFNet ${GTK_LIBRARIES})
+
+install(TARGETS DFNet LIBRARY DESTINATION ${CMAKE_INSTALL_FULL_LIBDIR}/games/psemu)
+install(TARGETS cfgDFNet RUNTIME DESTINATION ${CMAKE_INSTALL_FULL_LIBDIR}/games/psemu)