diff --git a/OpenChange/GNUmakefile b/OpenChange/GNUmakefile index 4914c132c..f128a6c47 100644 --- a/OpenChange/GNUmakefile +++ b/OpenChange/GNUmakefile @@ -129,7 +129,7 @@ TEST_TOOL_NAME += $(PLREADER_TOOL) ### cflags and libs LIBMAPI_CFLAGS = $(shell pkg-config libmapi --cflags) -LIBMAPISTORE_CFLAGS = $(shell pkg-config libmapistore --cflags) +LIBMAPISTORE_CFLAGS = $(shell pkg-config libmapistore --cflags) -DSAMBA_PREFIX="\"$(shell pkg-config libmapistore --variable=prefix)\"" ifeq ($(LIBMAPISTORE_CFLAGS),) all install:: diff --git a/OpenChange/MAPIStoreSOGo.m b/OpenChange/MAPIStoreSOGo.m index 6f1ca6a06..f8ae76660 100644 --- a/OpenChange/MAPIStoreSOGo.m +++ b/OpenChange/MAPIStoreSOGo.m @@ -70,7 +70,7 @@ sogo_backend_init (void) Class MAPIApplicationK; NSUserDefaults *ud; SoProductRegistry *registry; - char *argv0 = "openchange"; + char *argv[] = { SAMBA_PREFIX "/sbin/samba", NULL }; pool = [NSAutoreleasePool new]; @@ -79,7 +79,7 @@ sogo_backend_init (void) the encoding specified in the file. */ putenv ("GNUSTEP_STRING_ENCODING=NSUTF8StringEncoding"); - [NSProcessInfo initializeWithArguments: &argv0 + [NSProcessInfo initializeWithArguments: argv count: 1 environment: environ];