From 0e7939a89ada17eaa5cfcba4ba04d18ef4584a9b Mon Sep 17 00:00:00 2001 From: Guilherme Iscaro Date: Tue, 17 Apr 2012 17:18:58 +0000 Subject: [PATCH] Fixing the eina_prefix example Patch by: Guilherme Iscaro SVN revision: 70279 --- legacy/eina/src/include/eina_prefix.h | 19 +++++++++++++------ 1 file changed, 13 insertions(+), 6 deletions(-) diff --git a/legacy/eina/src/include/eina_prefix.h b/legacy/eina/src/include/eina_prefix.h index 7ca21435dc..c668b0feb9 100644 --- a/legacy/eina/src/include/eina_prefix.h +++ b/legacy/eina/src/include/eina_prefix.h @@ -106,11 +106,12 @@ typedef struct _Eina_Prefix Eina_Prefix; * * Compile the following defining at compile time your prefixes like (example): * - * gcc appname.c -o appname \ - * -DPACKAGE_BIN_DIR=/usr/local/bin \ - * -DPACKAGE_LIB_DIR=/usr/local/lib \ - * -DPACKAGE_DATA_DIR=/usr/local/share/appname \ - * -DLOCALE_DIR=/usr/local/share/locale + * gcc appname.c -o appname + * -DPACKAGE_BIN_DIR=\\"/usr/local/bin\" + * -DPACKAGE_LIB_DIR=\\"/usr/local/lib\" + * -DPACKAGE_DATA_DIR=\\"/usr/local/share/appname\" + * -DLOCALE_DIR=\\"/usr/local/share/locale\" + * `pkg-config --cflags --libs eina` * * (of course add appropriate compile flags to linking etc. etc. and note that * locale dir is optional. if you don't need it provide data dir as the @@ -120,10 +121,14 @@ typedef struct _Eina_Prefix Eina_Prefix; * to using a unix-style relative path from that dir, eg directory/filename.png) * * @code + * #include + * * static Eina_Prefix *pfx = NULL; * - * int main(argc, char **argv) + * int main(int argc, char **argv) * { + * eina_init(); + * * pfx = eina_prefix_new(argv[0], main, "APPNAME", "appname", NULL, * PACKAGE_BIN_DIR, PACKAGE_LIB_DIR, * PACKAGE_DATA_DIR, LOCALE_DIR); @@ -133,6 +138,8 @@ typedef struct _Eina_Prefix Eina_Prefix; * printf("libraries are in: %s\n", eina_prefix_lib_get(pfx)); * printf("data files are in: %s\n", eina_prefix_data_get(pfx)); * eina_prefix_free(pfx); + * + * eina_shutdown(); * } * @endcode *