diff --git a/Makefile.win b/Makefile.win index eb9f72d508..9e0865f178 100644 --- a/Makefile.win +++ b/Makefile.win @@ -142,7 +142,7 @@ else endif ifeq ($(HAVE_D3D9), 1) - OBJ += gfx/d3d9/d3d.o gfx/d3d9/d3d9_pc.o gfx/d3d9/render_chain.o + OBJ += gfx/d3d9/d3d.o gfx/d3d9/d3d9_pc.o gfx/d3d9/render_chain.o gfx/fonts/d3d_font.o gfx/fonts/d3d_w32_font.o DEFINES += -DHAVE_WIN32_D3D9 LIBS += -ld3d9 -lcg -lcgD3D9 -ld3dx9 -ldxguid endif diff --git a/gfx/d3d9/d3d.cpp b/gfx/d3d9/d3d.cpp index 7c7138a822..80cb0170fe 100644 --- a/gfx/d3d9/d3d.cpp +++ b/gfx/d3d9/d3d.cpp @@ -26,8 +26,6 @@ #include "../../compat/posix_string.h" #include "../../performance.h" -static void d3d_render_msg(void *data, const char *msg, void *userdata); - #ifndef _XBOX #define HAVE_MONITOR #define HAVE_WINDOW @@ -1139,4 +1137,4 @@ const video_driver_t video_d3d = { d3d_get_overlay_interface, #endif d3d_get_poke_interface -}; \ No newline at end of file +}; diff --git a/gfx/fonts/d3d_font.h b/gfx/fonts/d3d_font.h index 2a330a0429..999485efda 100644 --- a/gfx/fonts/d3d_font.h +++ b/gfx/fonts/d3d_font.h @@ -19,6 +19,10 @@ #include #include "../../boolean.h" +#ifdef __cplusplus +extern "C" { +#endif + typedef struct d3d_font_renderer { bool (*init)(void *data, const char *font_path, unsigned font_size); @@ -34,5 +38,9 @@ extern const d3d_font_renderer_t d3d_win32_font; const d3d_font_renderer_t *d3d_font_init_first(void *data, const char *font_path, unsigned font_size); +#ifdef __cplusplus +} +#endif + #endif diff --git a/gfx/fonts/d3d_w32_font.c b/gfx/fonts/d3d_w32_font.cpp similarity index 100% rename from gfx/fonts/d3d_w32_font.c rename to gfx/fonts/d3d_w32_font.cpp diff --git a/gfx/gfx_context.h b/gfx/gfx_context.h index 2afaa5dd68..9787c7929c 100644 --- a/gfx/gfx_context.h +++ b/gfx/gfx_context.h @@ -23,6 +23,10 @@ #include "../config.h" #endif +#ifdef __cplusplus +extern "C" { +#endif + #define MAX_EGLIMAGE_TEXTURES 32 enum gfx_ctx_api @@ -115,5 +119,9 @@ extern const gfx_ctx_driver_t gfx_ctx_null; const gfx_ctx_driver_t *gfx_ctx_find_driver(const char *ident); // Finds driver with ident. Does not initialize. const gfx_ctx_driver_t *gfx_ctx_init_first(enum gfx_ctx_api api, unsigned major, unsigned minor); // Finds first suitable driver and initializes. +#ifdef __cplusplus +} +#endif + #endif diff --git a/msvc/msvc-2010/RetroArch-msvc2010.vcxproj b/msvc/msvc-2010/RetroArch-msvc2010.vcxproj index 88c9cbf711..6aa989ca25 100644 --- a/msvc/msvc-2010/RetroArch-msvc2010.vcxproj +++ b/msvc/msvc-2010/RetroArch-msvc2010.vcxproj @@ -227,7 +227,7 @@ - + @@ -331,4 +331,4 @@ - \ No newline at end of file +