[retro-gtk/c-port: 6/39] Manually define retro-gtk.h



commit 142d016b142ce8e40a42626053608bea4ee9b721
Author: Adrien Plazas <kekun plazas laposte net>
Date:   Wed Sep 6 10:10:15 2017 +0200

    Manually define retro-gtk.h

 retro-gtk/Makefile.am |    7 ++-----
 retro-gtk/retro-gtk.h |   12 ++++++++++++
 2 files changed, 14 insertions(+), 5 deletions(-)
---
diff --git a/retro-gtk/Makefile.am b/retro-gtk/Makefile.am
index ad059da..9cd1454 100644
--- a/retro-gtk/Makefile.am
+++ b/retro-gtk/Makefile.am
@@ -96,7 +96,7 @@ libretro_gtk_la_VALAFLAGS = \
        --target-glib 2.32 \
        --library retro-gtk-0.12 \
        --vapi retro-gtk-0.12.vapi \
-       -H retro-gtk.h \
+       -H retro-gtk-vala.h \
        -h retro-gtk-internal.h \
        -X -fPIC -X -shared \
        $(NULL)
@@ -106,15 +106,12 @@ libretro_gtk_la_LIBADD = $(RETRO_GTK_LIBS)
 retro_gtkincludedir = $(includedir)/retro-gtk-0.12
 retro_gtkinclude_HEADERS = \
        retro-gtk.h \
+       retro-gtk-vala.h \
        retro-option.h \
        retro-options.h \
        retro-variable.h \
        $(NULL)
 
-# Add unstable API guard
-$(outdir)/retro-gtk.h:
-       sed -i "s/#define __RETRO_GTK_H__/#define __RETRO_GTK_H__\n\n#ifndef 
RETRO_GTK_USE_UNSTABLE_API\n#error    retro-gtk is unstable API. You must define RETRO_GTK_USE_UNSTABLE_API 
before including retro-gtk.h\n#endif/" $@
-
 # Introspection
 -include $(INTROSPECTION_MAKEFILE)
 
diff --git a/retro-gtk/retro-gtk.h b/retro-gtk/retro-gtk.h
new file mode 100644
index 0000000..a520b61
--- /dev/null
+++ b/retro-gtk/retro-gtk.h
@@ -0,0 +1,12 @@
+// This file is part of retro-gtk. License: GPL-3.0+.
+
+#ifndef __RETRO_GTK_H__
+#define __RETRO_GTK_H__
+
+#ifndef RETRO_GTK_USE_UNSTABLE_API
+#error    retro-gtk is unstable API. You must define RETRO_GTK_USE_UNSTABLE_API before including retro-gtk.h
+#endif
+
+#include "retro-gtk-vala.h"
+
+#endif


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]