summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDaniel Zaoui <daniel.zaoui@samsung.com>2015-07-27 14:41:11 +0300
committerDaniel Zaoui <daniel.zaoui@samsung.com>2015-12-02 09:43:21 +0200
commitcc60f4ffbf5f2ea8e7274dd89dd81c2efa044293 (patch)
tree25a0eaf13164c89a557260a88d661a3a4aa5bb0f
parentb120f9044d3b8f06d93d19da8c35c5633306b0bb (diff)
Fix H include file generation
-rw-r--r--src/bin/ea_cgen/ea_cgen.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/src/bin/ea_cgen/ea_cgen.c b/src/bin/ea_cgen/ea_cgen.c
index 8a36765..f8c1e05 100644
--- a/src/bin/ea_cgen/ea_cgen.c
+++ b/src/bin/ea_cgen/ea_cgen.c
@@ -775,6 +775,7 @@ _session_generate()
775 if (session_ctx.c_output) 775 if (session_ctx.c_output)
776 { 776 {
777 char *h_filename = strdup(session_ctx.filename); 777 char *h_filename = strdup(session_ctx.filename);
778 char *h_basename = basename(h_filename);
778 int len = strlen(session_ctx.filename); 779 int len = strlen(session_ctx.filename);
779 if (h_filename[len - 2] == '.' && h_filename[len - 1] == 'c') h_filename[len - 2] = '\0'; 780 if (h_filename[len - 2] == '.' && h_filename[len - 1] == 'c') h_filename[len - 2] = '\0';
780 eina_strbuf_append_printf(session_ctx.buf, 781 eina_strbuf_append_printf(session_ctx.buf,
@@ -784,7 +785,7 @@ _session_generate()
784 "#include <Elementary.h>\n" 785 "#include <Elementary.h>\n"
785 "#include \"elm_widget_container.h\"\n" 786 "#include \"elm_widget_container.h\"\n"
786 "#include \"elm_interface_scrollable.h\"\n\n" 787 "#include \"elm_interface_scrollable.h\"\n\n"
787 "#include \"%s.h\"\n\n", h_filename); 788 "#include \"%s.h\"\n\n", h_basename);
788 free(h_filename); 789 free(h_filename);
789 790
790 eina_strbuf_append(session_ctx.buf, eina_strbuf_string_get(resources_buf)); 791 eina_strbuf_append(session_ctx.buf, eina_strbuf_string_get(resources_buf));