summary |
shortlog |
log |
commit | commitdiff |
tree
raw |
patch |
inline | side by side (from parent 1:
94809b0)
git-svn-id: https://navit.svn.sourceforge.net/svnroot/navit/trunk@4712
ffa7fe5e-494d-0410-b361-
a75ebd5db220
#ifdef __cplusplus
extern "C" {
#endif
#ifdef __cplusplus
extern "C" {
#endif
+extern int main_argc;
+extern char **main_argv;
extern struct config *config;
extern int config_empty_ok;
/* prototypes */
extern struct config *config;
extern int config_empty_ok;
/* prototypes */
gdb_program=g_strdup(program_name);
signal(SIGSEGV, sigsegv);
debug_hash=g_hash_table_new_full(g_str_hash, g_str_equal, g_free, NULL);
gdb_program=g_strdup(program_name);
signal(SIGSEGV, sigsegv);
debug_hash=g_hash_table_new_full(g_str_hash, g_str_equal, g_free, NULL);
+#ifdef __IPHONE_OS_VERSION_MIN_REQUIRED
+ debug_fp = stdout;
+#else
#include "debug.h"
#include "plugin.h"
#include "point.h"
#include "debug.h"
#include "plugin.h"
#include "point.h"
#endif
NSAutoreleasePool * pool = [[NSAutoreleasePool alloc] init];
#if USE_UIKIT
#endif
NSAutoreleasePool * pool = [[NSAutoreleasePool alloc] init];
#if USE_UIKIT
-#if 1
- int argc=2;
- char *argv[]={"Debug/navit.app/navit","-RegisterForSystemEvents",NULL};
-#else
- int argc=1;
- char *argv[]={"navit",NULL};
-#endif
- int retval = UIApplicationMain(argc, argv, nil, @"NavitAppDelegate");
+ int retval = UIApplicationMain(main_argc, main_argv, nil, @"NavitAppDelegate");
dbg(0,"retval=%d\n",retval);
#else
NavitAppDelegate * delegate = [[NavitAppDelegate alloc] init];
dbg(0,"retval=%d\n",retval);
#else
NavitAppDelegate * delegate = [[NavitAppDelegate alloc] init];
#ifdef HAVE_GETOPT_H
opterr=0; //don't bomb out on errors.
#endif /* _MSC_VER */
#ifdef HAVE_GETOPT_H
opterr=0; //don't bomb out on errors.
#endif /* _MSC_VER */
+ /* ingore iphone command line argument */
+ if (argc == 2 && !strcmp(argv[1],"-RegisterForSystemEvents"))
+ argc=1;
if (argc > 1) {
/* DEVELOPPERS : don't forget to update the manpage if you modify theses options */
while((opt = getopt(argc, argv, ":hvc:d:e:s:")) != -1) {
if (argc > 1) {
/* DEVELOPPERS : don't forget to update the manpage if you modify theses options */
while((opt = getopt(argc, argv, ":hvc:d:e:s:")) != -1) {