eolian gen2: generate stub headers
authorDaniel Kolesa <d.kolesa@osg.samsung.com>
Thu, 15 Sep 2016 14:36:24 +0000 (16:36 +0200)
committerDaniel Kolesa <d.kolesa@osg.samsung.com>
Fri, 7 Oct 2016 09:54:23 +0000 (11:54 +0200)
src/bin/eolian2/main.c

index d988761..88790b2 100644 (file)
@@ -244,6 +244,18 @@ _write_stub_header(const char *ofname, const char *ifname)
    INF("generating stuv header: %s", ofname);
    Eina_Strbuf *buf = eina_strbuf_new();
 
+   eo_gen_types_header_gen(ifname, buf, EINA_FALSE, EINA_FALSE);
+
+   Eina_Strbuf *cltd = eo_gen_class_typedef_gen(ifname);
+   if (cltd)
+     {
+        eina_strbuf_prepend_char(buf, '\n');
+        eina_strbuf_prepend(buf, eina_strbuf_string_get(cltd));
+        eina_strbuf_free(cltd);
+     }
+
+   buf = _include_guard(ifname, "STUBS", buf);
+
    Eina_Bool ret = _write_file(ofname, buf, EINA_FALSE);
    eina_strbuf_free(buf);
    return ret;