summaryrefslogtreecommitdiff
path: root/hw/xquartz
diff options
context:
space:
mode:
authorJeremy Huddleston <jeremyhu@apple.com>2011-04-24 21:35:04 -0700
committerJeremy Huddleston <jeremyhu@apple.com>2011-04-25 18:57:04 -0700
commitde4023f194c561b74f8fa904bea3dd5298230cd1 (patch)
tree5bf938dcc13ce11cc38b4a6f79394dd6248b1188 /hw/xquartz
parente466745109416a2fcdf5d7389c80b814a0363676 (diff)
XQuartz: Rename launchd-id-prefix to bundle-id-prefix
It's used many other places than just for launchd. Signed-off-by: Jeremy Huddleston <jeremyhu@apple.com>
Diffstat (limited to 'hw/xquartz')
-rw-r--r--hw/xquartz/X11Application.m2
-rw-r--r--hw/xquartz/bundle/Info.plist.cpp4
-rw-r--r--hw/xquartz/bundle/Makefile.am2
-rw-r--r--hw/xquartz/mach-startup/bundle-main.c18
-rw-r--r--hw/xquartz/mach-startup/launchd_fd.c4
-rw-r--r--hw/xquartz/mach-startup/stub.c2
-rw-r--r--hw/xquartz/pbproxy/Makefile.am2
-rw-r--r--hw/xquartz/pbproxy/app-main.m2
-rw-r--r--hw/xquartz/xpr/xprFrame.c2
9 files changed, 19 insertions, 19 deletions
diff --git a/hw/xquartz/X11Application.m b/hw/xquartz/X11Application.m
index 6f8943776..2a45cc5fa 100644
--- a/hw/xquartz/X11Application.m
+++ b/hw/xquartz/X11Application.m
@@ -1012,7 +1012,7 @@ void X11ApplicationMain (int argc, char **argv, char **envp) {
NSMaxY([[NSScreen mainScreen] visibleFrame]);
#ifdef HAVE_LIBDISPATCH
- eventTranslationQueue = dispatch_queue_create(LAUNCHD_ID_PREFIX".X11.NSEventsToX11EventsQueue", NULL);
+ eventTranslationQueue = dispatch_queue_create(BUNDLE_ID_PREFIX".X11.NSEventsToX11EventsQueue", NULL);
assert(eventTranslationQueue != NULL);
#endif
diff --git a/hw/xquartz/bundle/Info.plist.cpp b/hw/xquartz/bundle/Info.plist.cpp
index 99b184f6a..a4b8e1926 100644
--- a/hw/xquartz/bundle/Info.plist.cpp
+++ b/hw/xquartz/bundle/Info.plist.cpp
@@ -7,11 +7,11 @@
<key>CFBundleExecutable</key>
<string>X11</string>
<key>CFBundleGetInfoString</key>
- <string>LAUNCHD_ID_PREFIX.X11</string>
+ <string>BUNDLE_ID_PREFIX.X11</string>
<key>CFBundleIconFile</key>
<string>X11.icns</string>
<key>CFBundleIdentifier</key>
- <string>LAUNCHD_ID_PREFIX.X11</string>
+ <string>BUNDLE_ID_PREFIX.X11</string>
<key>CFBundleInfoDictionaryVersion</key>
<string>6.0</string>
<key>CFBundleName</key>
diff --git a/hw/xquartz/bundle/Makefile.am b/hw/xquartz/bundle/Makefile.am
index 8a206cf4b..6deecae55 100644
--- a/hw/xquartz/bundle/Makefile.am
+++ b/hw/xquartz/bundle/Makefile.am
@@ -1,7 +1,7 @@
include cpprules.in
CPP_FILES_FLAGS = \
- -DLAUNCHD_ID_PREFIX="$(LAUNCHD_ID_PREFIX)" \
+ -DBUNDLE_ID_PREFIX="$(BUNDLE_ID_PREFIX)" \
-DAPPLE_APPLICATION_NAME="$(APPLE_APPLICATION_NAME)"
if XQUARTZ_SPARKLE
diff --git a/hw/xquartz/mach-startup/bundle-main.c b/hw/xquartz/mach-startup/bundle-main.c
index d70cfd4fa..29890215a 100644
--- a/hw/xquartz/mach-startup/bundle-main.c
+++ b/hw/xquartz/mach-startup/bundle-main.c
@@ -88,7 +88,7 @@ asm (".desc ___crashreporter_info__, 0x10");
static const char *__crashreporter_info__base = "X.Org X Server " XSERVER_VERSION " Build Date: " BUILD_DATE;
-static char *launchd_id_prefix = NULL;
+static char *bundle_id_prefix = NULL;
static char *server_bootstrap_name = NULL;
#define DEBUG 1
@@ -491,7 +491,7 @@ static void setup_env(void) {
/* fallback to hardcoded value if we can't discover it */
if(!pds) {
- pds = LAUNCHD_ID_PREFIX".X11";
+ pds = BUNDLE_ID_PREFIX".X11";
}
server_bootstrap_name = strdup(pds);
@@ -502,12 +502,12 @@ static void setup_env(void) {
setenv("X11_PREFS_DOMAIN", server_bootstrap_name, 1);
len = strlen(server_bootstrap_name);
- launchd_id_prefix = malloc(sizeof(char) * (len - 3));
- if(!launchd_id_prefix) {
+ bundle_id_prefix = malloc(sizeof(char) * (len - 3));
+ if(!bundle_id_prefix) {
fprintf(stderr, "X11.app: Memory allocation error.\n");
exit(1);
}
- strlcpy(launchd_id_prefix, server_bootstrap_name, len - 3);
+ strlcpy(bundle_id_prefix, server_bootstrap_name, len - 3);
/* We need to unset DISPLAY if it is not our socket */
if(disp) {
@@ -519,7 +519,7 @@ static void setup_env(void) {
}
if(s && *s) {
- if(strcmp(launchd_id_prefix, "org.x") == 0 && strcmp(s, ":0") == 0) {
+ if(strcmp(bundle_id_prefix, "org.x") == 0 && strcmp(s, ":0") == 0) {
fprintf(stderr, "X11.app: Detected old style launchd DISPLAY, please update xinit.\n");
} else {
temp = (char *)malloc(sizeof(char) * len);
@@ -527,12 +527,12 @@ static void setup_env(void) {
fprintf(stderr, "X11.app: Memory allocation error creating space for socket name test.\n");
exit(1);
}
- strlcpy(temp, launchd_id_prefix, len);
+ strlcpy(temp, bundle_id_prefix, len);
strlcat(temp, ":0", len);
if(strcmp(temp, s) != 0) {
/* If we don't have a match, unset it. */
- fprintf(stderr, "X11.app: DISPLAY (\"%s\") does not match our id (\"%s\"), unsetting.\n", disp, launchd_id_prefix);
+ fprintf(stderr, "X11.app: DISPLAY (\"%s\") does not match our id (\"%s\"), unsetting.\n", disp, bundle_id_prefix);
unsetenv("DISPLAY");
}
free(temp);
@@ -632,7 +632,7 @@ int main(int argc, char **argv, char **envp) {
fprintf(stderr, "Waiting for startup parameters via Mach IPC.\n");
kr = mach_msg_server(mach_startup_server, mxmsgsz, mp, 0);
if (kr != KERN_SUCCESS) {
- fprintf(stderr, "%s.X11(mp): %s\n", LAUNCHD_ID_PREFIX, mach_error_string(kr));
+ fprintf(stderr, "%s.X11(mp): %s\n", BUNDLE_ID_PREFIX, mach_error_string(kr));
return EXIT_FAILURE;
}
diff --git a/hw/xquartz/mach-startup/launchd_fd.c b/hw/xquartz/mach-startup/launchd_fd.c
index 6dace8ea1..5c7e03cf3 100644
--- a/hw/xquartz/mach-startup/launchd_fd.c
+++ b/hw/xquartz/mach-startup/launchd_fd.c
@@ -69,11 +69,11 @@ int launchd_display_fd(void) {
return ERROR_FD;
}
- listening_fd_array = launch_data_dict_lookup(sockets_dict, LAUNCHD_ID_PREFIX":0");
+ listening_fd_array = launch_data_dict_lookup(sockets_dict, BUNDLE_ID_PREFIX":0");
if (NULL == listening_fd_array) {
listening_fd_array = launch_data_dict_lookup(sockets_dict, ":0");
if (NULL == listening_fd_array) {
- fprintf(stderr,"launchd check-in: No known sockets found to answer requests on! \"%s:0\" and \":0\" failed.\n", LAUNCHD_ID_PREFIX);
+ fprintf(stderr,"launchd check-in: No known sockets found to answer requests on! \"%s:0\" and \":0\" failed.\n", BUNDLE_ID_PREFIX);
return ERROR_FD;
}
}
diff --git a/hw/xquartz/mach-startup/stub.c b/hw/xquartz/mach-startup/stub.c
index 180456015..3653bca48 100644
--- a/hw/xquartz/mach-startup/stub.c
+++ b/hw/xquartz/mach-startup/stub.c
@@ -40,7 +40,7 @@
#include <sys/socket.h>
#include <sys/un.h>
-#define kX11AppBundleId LAUNCHD_ID_PREFIX".X11"
+#define kX11AppBundleId BUNDLE_ID_PREFIX".X11"
#define kX11AppBundlePath "/Contents/MacOS/X11"
static char *server_bootstrap_name = kX11AppBundleId;
diff --git a/hw/xquartz/pbproxy/Makefile.am b/hw/xquartz/pbproxy/Makefile.am
index 188664259..b8b95d232 100644
--- a/hw/xquartz/pbproxy/Makefile.am
+++ b/hw/xquartz/pbproxy/Makefile.am
@@ -1,5 +1,5 @@
AM_CPPFLAGS=-F/System/Library/Frameworks/ApplicationServices.framework/Frameworks \
- -DLAUNCHD_ID_PREFIX=\"$(LAUNCHD_ID_PREFIX)\"
+ -DBUNDLE_ID_PREFIX=\"$(BUNDLE_ID_PREFIX)\"
AM_CFLAGS=$(XPBPROXY_CFLAGS)
diff --git a/hw/xquartz/pbproxy/app-main.m b/hw/xquartz/pbproxy/app-main.m
index b00e90a6d..245d1bca0 100644
--- a/hw/xquartz/pbproxy/app-main.m
+++ b/hw/xquartz/pbproxy/app-main.m
@@ -34,7 +34,7 @@
#include <unistd.h> /*for getpid*/
#include <Cocoa/Cocoa.h>
-static const char *app_prefs_domain = LAUNCHD_ID_PREFIX".xpbproxy";
+static const char *app_prefs_domain = BUNDLE_ID_PREFIX".xpbproxy";
CFStringRef app_prefs_domain_cfstr;
/* Stubs */
diff --git a/hw/xquartz/xpr/xprFrame.c b/hw/xquartz/xpr/xprFrame.c
index 066cc0f81..5f6b1cb7b 100644
--- a/hw/xquartz/xpr/xprFrame.c
+++ b/hw/xquartz/xpr/xprFrame.c
@@ -477,7 +477,7 @@ xprInit(ScreenPtr pScreen)
assert((window_hash = x_hash_table_new(NULL, NULL, NULL, NULL)));
#ifdef HAVE_LIBDISPATCH
- assert((window_hash_serial_q = dispatch_queue_create(LAUNCHD_ID_PREFIX".X11.xpr_window_hash", NULL)));
+ assert((window_hash_serial_q = dispatch_queue_create(BUNDLE_ID_PREFIX".X11.xpr_window_hash", NULL)));
#else
assert(0 == pthread_mutex_init(&window_hash_mutex, NULL));
#endif