mirror of
https://github.com/libretro/RetroArch
synced 2025-01-28 14:54:03 +00:00
Only build D3D as C++ on Win32.
Fix a couple of headers with #ifdef __cplusplus.
This commit is contained in:
parent
df53e3eee4
commit
9f3af988f1
@ -117,7 +117,6 @@ else
|
||||
endif
|
||||
|
||||
ifeq ($(HAVE_D3D9), 1)
|
||||
CXX_BUILD = 1
|
||||
OBJ += gfx/d3d9/d3d9.o gfx/d3d9/render_chain.o
|
||||
DEFINES += -DHAVE_WIN32_D3D9
|
||||
LIBS += -ld3d9 -lcg -lcgD3D9 -ld3dx9 -ldxguid
|
||||
@ -217,12 +216,15 @@ endif
|
||||
|
||||
ifeq ($(DEBUG), 1)
|
||||
CFLAGS += -O0 -g
|
||||
CXXFLAGS += -O0 -g
|
||||
else
|
||||
CFLAGS += -O3
|
||||
CXXFLAGS += -O3
|
||||
LDCXXFLAGS += -s
|
||||
endif
|
||||
|
||||
CFLAGS += -Wall -Wno-unused-result -I.
|
||||
CXXFLAGS += -Wall -Wno-unused-result -I. -std=c++0x -D__STDC_CONSTANT_MACROS
|
||||
ifeq ($(CXX_BUILD), 1)
|
||||
CFLAGS += -std=c++0x -xc++ -D__STDC_CONSTANT_MACROS
|
||||
else
|
||||
@ -240,7 +242,7 @@ $(TARGET): $(OBJ)
|
||||
@$(if $(Q), $(shell echo echo CC $<),)
|
||||
|
||||
%.o: %.cpp
|
||||
$(Q)$(CXX) $(CFLAGS) $(DEFINES) -c -o $@ $<
|
||||
$(Q)$(CXX) $(CXXFLAGS) $(DEFINES) -c -o $@ $<
|
||||
@$(if $(Q), $(shell echo echo CXX $<),)
|
||||
|
||||
%.o: %.rc
|
||||
|
@ -17,6 +17,10 @@
|
||||
#ifndef __CONFIG_FILE_H
|
||||
#define __CONFIG_FILE_H
|
||||
|
||||
#ifdef __cplusplus
|
||||
extern "C" {
|
||||
#endif
|
||||
|
||||
#include <stdint.h>
|
||||
#include "../boolean.h"
|
||||
#include <stdio.h>
|
||||
@ -90,5 +94,9 @@ void config_file_dump(config_file_t *conf, FILE *file);
|
||||
// Also dumps inherited values, useful for logging.
|
||||
void config_file_dump_all(config_file_t *conf, FILE *file);
|
||||
|
||||
#ifdef __cplusplus
|
||||
}
|
||||
#endif
|
||||
|
||||
#endif
|
||||
|
||||
|
@ -16,6 +16,10 @@
|
||||
#ifndef __GFX_COMMON_H
|
||||
#define __GFX_COMMON_H
|
||||
|
||||
#ifdef __cplusplus
|
||||
extern "C" {
|
||||
#endif
|
||||
|
||||
#include <stddef.h>
|
||||
#include "../boolean.h"
|
||||
|
||||
@ -30,4 +34,8 @@ void gfx_window_title_reset(void);
|
||||
void gfx_set_dwm(void);
|
||||
#endif
|
||||
|
||||
#ifdef __cplusplus
|
||||
}
|
||||
#endif
|
||||
|
||||
#endif
|
||||
|
@ -16,6 +16,10 @@
|
||||
#ifndef __RARCH_SNES_TRACKER_H
|
||||
#define __RARCH_SNES_TRACKER_H
|
||||
|
||||
#ifdef __cplusplus
|
||||
extern "C" {
|
||||
#endif
|
||||
|
||||
#include <stdint.h>
|
||||
#include "../boolean.h"
|
||||
|
||||
@ -80,4 +84,8 @@ void state_tracker_free(state_tracker_t *tracker);
|
||||
|
||||
unsigned state_get_uniform(state_tracker_t *tracker, struct state_tracker_uniform *uniforms, unsigned elem, unsigned frame_count);
|
||||
|
||||
#ifdef __cplusplus
|
||||
}
|
||||
#endif
|
||||
|
||||
#endif
|
||||
|
Loading…
x
Reference in New Issue
Block a user