change the way elm_main() must be declared (fix bug on Windows).

Instead of EAPI elm_main(***), it must be EAPI_MAIN elm_main(***) so that
it also work on Windows.

If someone knows sed a bit, can he also change all the examples ?



SVN revision: 62885
This commit is contained in:
Vincent Torri 2011-08-27 07:54:49 +00:00
parent ac5468e003
commit a1e841fcac
6 changed files with 11 additions and 14 deletions

View File

@ -21,10 +21,6 @@ AM_CPPFLAGS = \
@ELEMENTARY_EMAP_CFLAGS@ \
@EIO_CFLAGS@
if ELEMENTARY_WINDOWS_BUILD
AM_CPPFLAGS += -DELEMENTARY_BUILD
endif
noinst_PROGRAMS = \
widget_preview_button1 \
widget_preview_button2 \

View File

@ -5,7 +5,7 @@
# define __UNUSED__
#endif
EAPI int
EAPI_MAIN int
elm_main(int argc __UNUSED__, char **argv)
{
Evas_Object *win, *bg;

View File

@ -21,10 +21,6 @@ AM_CPPFLAGS = \
@ELEMENTARY_EMAP_CFLAGS@ \
@EIO_CFLAGS@
if ELEMENTARY_WINDOWS_BUILD
AM_CPPFLAGS += -DELEMENTARY_BUILD
endif
bin_PROGRAMS = @ELEMENTARY_TEST_PRG@ @ELEMENTARY_CONFIG_PRG@
if BUILD_QUICKLAUNCH
bin_PROGRAMS += elementary_quicklaunch elementary_run elementary_testql

View File

@ -2967,7 +2967,7 @@ _exit_timer(void *data __UNUSED__)
/* this is your elementary main function - it MUST be called IMMEDIATELY
* after elm_init() and MUST be passed argc and argv, and MUST be called
* elm_main and not be static - must be a visible symbol with EAPI infront */
EAPI int
EAPI_MAIN int
elm_main(int argc,
char **argv)
{

View File

@ -466,7 +466,7 @@ add_tests:
/* this is your elementary main function - it MUST be called IMMEDIATELY
* after elm_init() and MUST be passed argc and argv, and MUST be called
* elm_main and not be static - must be a visible symbol with EAPI infront */
EAPI int
EAPI_MAIN int
elm_main(int argc, char **argv)
{
Eina_Bool test_win_only = EINA_FALSE;

View File

@ -52,7 +52,7 @@ organisations behind this, as listed in the @ref authors page.
*
@code
#include <Elementary.h>
EAPI int
EAPI_MAIN int
elm_main(int argc, char **argv)
{
// create window(s) here and do any application init
@ -191,7 +191,7 @@ on_done(void *data, Evas_Object *obj, void *event_info)
elm_exit();
}
EAPI int
EAPI_MAIN int
elm_main(int argc, char **argv)
{
Evas_Object *win, *bg, *box, *lab, *btn;
@ -420,6 +420,11 @@ contact with the developers and maintainers.
# endif
#endif /* ! _WIN32 */
#ifdef _WIN32
# define EAPI_MAIN
#else
# define EAPI_MAIN EAPI
#endif
/* allow usage from c++ */
#ifdef __cplusplus
@ -12560,7 +12565,7 @@ extern "C" {
* @code
* #include <Elementary.h>
* #ifndef ELM_LIB_QUICKLAUNCH
* EAPI int
* EAPI_MAIN int
* elm_main(int argc, char **argv)
* {
* Ethumb_Client *client;