mirror of
https://github.com/simple64/simple64.git
synced 2026-07-11 01:24:00 +02:00
update raphnet
This commit is contained in:
@@ -2,4 +2,4 @@
|
||||
*.so
|
||||
*.o
|
||||
*.swp
|
||||
/projects/unix/_obj*/
|
||||
build/
|
||||
|
||||
@@ -0,0 +1,47 @@
|
||||
cmake_minimum_required(VERSION 3.20)
|
||||
|
||||
project(simple64-input-raphnetraw LANGUAGES C)
|
||||
|
||||
set(CMAKE_CXX_STANDARD 17)
|
||||
set(CMAKE_CXX_STANDARD_REQUIRED ON)
|
||||
|
||||
include(CheckIPOSupported)
|
||||
check_ipo_supported(RESULT ENABLE_IPO)
|
||||
if(ENABLE_IPO)
|
||||
message("Interprocedural optimizations enabled")
|
||||
endif(ENABLE_IPO)
|
||||
|
||||
if(ENABLE_IPO AND (CMAKE_BUILD_TYPE STREQUAL "Release"))
|
||||
set(CMAKE_INTERPROCEDURAL_OPTIMIZATION ON)
|
||||
endif()
|
||||
|
||||
include_directories(../mupen64plus-core/src/api)
|
||||
|
||||
find_package(PkgConfig REQUIRED)
|
||||
|
||||
add_library(simple64-input-raphnetraw SHARED
|
||||
src/plugin_front.c
|
||||
src/plugin_back.c
|
||||
src/gcn64lib.c
|
||||
src/gcn64.c
|
||||
src/hexdump.c
|
||||
)
|
||||
|
||||
if (WIN32)
|
||||
target_sources(simple64-input-raphnetraw PRIVATE
|
||||
src/osal_dynamiclib_win32.c
|
||||
)
|
||||
pkg_check_modules(HIDAPI REQUIRED hidapi)
|
||||
endif (WIN32)
|
||||
|
||||
if (UNIX)
|
||||
target_sources(simple64-input-raphnetraw PRIVATE
|
||||
src/osal_dynamiclib_unix.c
|
||||
)
|
||||
pkg_check_modules(HIDAPI REQUIRED hidapi-hidraw)
|
||||
endif (UNIX)
|
||||
|
||||
set_target_properties(simple64-input-raphnetraw PROPERTIES PREFIX "")
|
||||
target_compile_options(simple64-input-raphnetraw PRIVATE -march=x86-64-v3 ${HIDAPI_CFLAGS})
|
||||
target_link_options(simple64-input-raphnetraw PRIVATE -march=x86-64-v3)
|
||||
target_link_libraries(simple64-input-raphnetraw PRIVATE ${HIDAPI_LIBRARIES})
|
||||
@@ -128,10 +128,10 @@ ifeq ($(OS), OSX)
|
||||
|
||||
ifeq ($(CPU), X86)
|
||||
ifeq ($(ARCH_DETECTED), 64BITS)
|
||||
CFLAGS += -arch x86_64 -mmacosx-version-min=11.0 -isysroot $(OSX_SDK_PATH)
|
||||
CFLAGS += -arch x86_64 -mmacosx-version-min=10.5 -isysroot $(OSX_SDK_PATH)
|
||||
LDLIBS += -ldl
|
||||
else
|
||||
CFLAGS += -mmmx -msse -fomit-frame-pointer -arch i686 -mmacosx-version-min=11.0 -isysroot $(OSX_SDK_PATH)
|
||||
CFLAGS += -mmmx -msse -fomit-frame-pointer -arch i686 -mmacosx-version-min=10.5 -isysroot $(OSX_SDK_PATH)
|
||||
LDLIBS += -ldl -read_only_relocs suppress
|
||||
endif
|
||||
endif
|
||||
@@ -252,16 +252,16 @@ OBJDIRS = $(dir $(OBJECTS))
|
||||
$(shell $(MKDIR) $(OBJDIRS))
|
||||
|
||||
# build targets
|
||||
TARGET = simple64-input-raphnetraw$(POSTFIX).$(SO_EXTENSION)
|
||||
TARGET = mupen64plus-input-raphnetraw$(POSTFIX).$(SO_EXTENSION)
|
||||
|
||||
targets:
|
||||
@echo "simple64-input-raphnetraw makefile. "
|
||||
@echo "Mupen64Plus-input-raphnetraw makefile. "
|
||||
@echo " Targets:"
|
||||
@echo " all == Build Mupen64Plus raphnetraw input plugin"
|
||||
@echo " clean == remove object files"
|
||||
@echo " rebuild == clean and re-build all"
|
||||
@echo " install == Install simple64 raphnetraw input plugin"
|
||||
@echo " uninstall == Uninstall simple64 raphnetraw input plugin"
|
||||
@echo " install == Install Mupen64Plus raphnetraw input plugin"
|
||||
@echo " uninstall == Uninstall Mupen64Plus raphnetraw input plugin"
|
||||
@echo " Options:"
|
||||
@echo " BITS=32 == build 32-bit binaries on 64-bit machine"
|
||||
@echo " APIDIR=path == path to find Mupen64Plus Core headers"
|
||||
|
||||
Reference in New Issue
Block a user