Fix Kart conflicts

Conflicts from d5c08ac03

Some parts are reworked into the new build system.
This commit is contained in:
James R 2021-11-25 04:02:38 -08:00
parent d5c08ac034
commit 9ae0e0a8d7
4 changed files with 55 additions and 8 deletions

View file

@ -128,13 +128,9 @@ if(${SRB2_CONFIG_HAVE_DISCORDRPC})
endif()
if(${DISCORDRPC_FOUND})
set(SRB2_HAVE_DISCORDRPC ON)
add_definitions(-DHAVE_DISCORDRPC)
add_definitions(-DUSE_STUN)
set(SRB2_DISCORDRPC_SOURCES discord.c stun.c)
set(SRB2_DISCORDRPC_HEADERS discord.h stun.h)
prepend_sources(SRB2_DISCORDRPC_SOURCES)
prepend_sources(SRB2_DISCORDRPC_HEADERS)
source_group("Discord Rich Presence" FILES ${SRB2_DISCORDRPC_SOURCES} ${SRB2_DISCORDRPC_HEADERS})
target_compile_definitions(SRB2SDL2 PRIVATE -DHAVE_DISCORDRPC)
target_compile_definitions(SRB2SDL2 PRIVATE -DUSE_STUN)
target_sources(SRB2SDL2 PRIVATE discord.c stun.c)
else()
message(WARNING "You have specified that Discord Rich Presence is available but it was not found.")
endif()

View file

@ -6,6 +6,7 @@ passthru_opts+=\
NONET NO_IPV6 NOHW NOMD5 NOPOSTPROCESSING\
MOBJCONSISTANCY PACKETDROP ZDEBUG\
HAVE_MINIUPNPC\
HAVE_DISCORDRPC TESTERS DEVELOP
# build with debugging information
ifdef DEBUGMODE
@ -59,6 +60,13 @@ ifdef HAVE_MINIUPNPC
libs+=-lminiupnpc
endif
ifdef HAVE_DISCORDRPC
$(eval $(call Propogate_flags,DISCORDRPC))
libs+=-ldiscord-rpc
opts+=-DUSE_STUN
sources+=discord.c stun.c
endif
# (Valgrind is a memory debugger.)
ifdef VALGRIND
VALGRIND_PKGCONFIG?=valgrind

View file

@ -30,6 +30,15 @@ libs+=-lws2_32
endif
endif
ifndef MINGW64
opts+=-I../libs/drmingw/include
libs+=-L../libs/drmingw/lib/win32 -lmgwhelp -lexchndl
endif
ifndef MINGW64
libs+=-Wl,--large-address-aware
endif
ifndef NONET
ifndef MINGW64 # miniupnc is broken with MINGW64
opts+=-I../libs -DSTATIC_MINIUPNPC
@ -37,6 +46,10 @@ libs+=-L../libs/miniupnpc/mingw$(32) -lws2_32 -liphlpapi
endif
endif
ifndef NO_DISCORDRPC
HAVE_DISCORDRPC=1
endif
ifndef MINGW64
32=32
x86=x86
@ -97,3 +110,8 @@ lib:=../libs/curl
CURL_opts:=-I$(lib)/include
CURL_libs:=-L$(lib)/lib$(32) -lcurl
$(eval $(call _set,CURL))
lib:=../libs/discord-rpc/win$(32)-dynamic
DISCORDRPC_opts:=-I$(lib)/include
DISCORDRPC_libs:=-L$(lib)/lib
$(eval $(call _set,DISCORDRPC))

View file

@ -5,15 +5,20 @@ d_net.c
d_netfil.c
d_netcmd.c
dehacked.c
deh_soc.c
deh_lua.c
deh_tables.c
z_zone.c
f_finale.c
f_wipe.c
g_demo.c
g_game.c
g_input.c
g_splitscreen.c
am_map.c
command.c
console.c
font.c
hu_stuff.c
y_inter.c
st_stuff.c
@ -26,6 +31,7 @@ m_cond.c
m_fixed.c
m_menu.c
m_misc.c
m_perfstats.c
m_random.c
m_queue.c
info.c
@ -58,9 +64,12 @@ r_sky.c
r_splats.c
r_things.c
r_textures.c
r_patch.c
r_patchrotation.c
r_picformats.c
r_portal.c
screen.c
taglist.c
v_video.c
s_sound.c
sounds.c
@ -71,7 +80,6 @@ http-mserv.c
i_tcp.c
lzf.c
vid_copy.s
b_bot.c
lua_script.c
lua_baselib.c
lua_mathlib.c
@ -83,5 +91,22 @@ lua_playerlib.c
lua_skinlib.c
lua_thinkerlib.c
lua_maplib.c
lua_taglib.c
lua_polyobjlib.c
lua_blockmaplib.c
lua_hudlib.c
k_kart.c
k_respawn.c
k_collide.c
k_color.c
k_race.c
k_battle.c
k_pwrlv.c
k_waypoint.c
k_pathfind.c
k_bheap.c
k_bot.c
k_botitem.c
k_botsearch.c
k_grandprix.c
k_hud.c