From cccfdbe2c4e5f24bc51b9e300072213c4af0434e Mon Sep 17 00:00:00 2001 From: Matthew Flatt Date: Sat, 6 Nov 2010 22:08:15 -0600 Subject: [PATCH] misc clean-up related to build changes --- collects/scribblings/main/license.scrbl | 46 -- src/README | 5 +- src/configure | 29 +- src/gracket/Makefile.in | 1 - src/gracket/gc2/Makefile.in | 1 - src/mac/racket/simpledrop.cpp | 578 ------------------------ src/mac/racket/simpledrop.h | 13 - src/plot/Makefile.in | 14 +- src/racket/configure.ac | 16 +- src/worksp/README | 34 +- src/worksp/libgracket/libgracket.vcproj | 216 --------- 11 files changed, 30 insertions(+), 923 deletions(-) delete mode 100644 src/mac/racket/simpledrop.cpp delete mode 100644 src/mac/racket/simpledrop.h delete mode 100644 src/worksp/libgracket/libgracket.vcproj diff --git a/collects/scribblings/main/license.scrbl b/collects/scribblings/main/license.scrbl index 238a8bc869..a1371ebd0c 100644 --- a/collects/scribblings/main/license.scrbl +++ b/collects/scribblings/main/license.scrbl @@ -59,23 +59,6 @@ Racket software includes or extends the following copyrighted material: All rights reserved. } -@copyright{ - wxWindows - Copyright (c) 1994 - Artificial Intelligence Applications Institute, - The University of Edinburgh - All rights reserved. -} - -@copyright{ - wxWindows Xt - Copyright (c) 1994 - Artificial Intelligence Applications Institute, - The University of Edinburgh - Copyright (c) 1995 GNU (Markus Holzem) - All rights reserved. -} - @copyright{ Conservative garbage collector Copyright (c) 1988, 1989 Hans-J. Boehm, Alan J. Demers @@ -91,30 +74,6 @@ Racket software includes or extends the following copyrighted material: All rights reserved. } -@copyright{ - The A List - Copyright (c) 1997-2000 Kyle Hammond. - All rights reserved. -} - -@copyright{ - Independent JPEG Group library - Copyright (c) 1991-1998 Thomas G. Lane. - All rights reserved. -} - -@copyright{ - libpng - Copyright (c) 2000-2002 Glenn Randers-Pehrson - All rights reserved. -} - -@copyright{ - zlib - Copyright (c) 1995-2002 Jean-loup Gailly and Mark Adler - All rights reserved. -} - @copyright{ GNU MP Library Copyright (c) 1992, 1993, 1994, 1996 @@ -132,11 +91,6 @@ Racket software includes or extends the following copyrighted material: Copyright (c) 2003-2005 Hewlett-Packard Development Company, L.P. } -@copyright{ - GNU Classpath - GNU Public License with special exception -} - @copyright{ Clanbomber icon and Stop icons Everaldo Coelho diff --git a/src/README b/src/README index 4b33ddc871..96ecc5d1f0 100644 --- a/src/README +++ b/src/README @@ -28,7 +28,8 @@ To compile with Microsoft Visual C, read the instructions in To compile with Cygwin tools, follow the Unix instructions below, and be sure to configure with `--enable-shared'. The result is a Unix-style build, not a Windows-style build (e.g., Racket's `system-type' procedure -returns 'unix, not 'windows, and GRacket uses X11). +returns 'unix, not 'windows, and `racket/gui' uses Gtk instead of +Win32). ======================================================================== Compiling for Mac OS X @@ -50,7 +51,7 @@ the Unix instructions below, but note the following: `--disable-shared' is not supported. (Unless you use `--enable-xonx'...) - * To build an X11-based GRacket, run `configure' with the + * To build an X11- and Gtk-based GRacket, run `configure' with the `--enable-xonx' flag. Frameworks are not used for such builds, so --enable-shared is allowed. The `--enable-xonx' flag also affects the Racket build, so that `system-type' reports 'unix. Pre-built diff --git a/src/configure b/src/configure index 96d44ec0e4..2f0f9be01c 100755 --- a/src/configure +++ b/src/configure @@ -677,7 +677,6 @@ AR STATIC_AR ARFLAGS STRIP_DEBUG -WBUILD CC_FOR_BUILD REZ MZLINKER @@ -714,7 +713,6 @@ MRLIBINSTALL LIBFINISH MAKE_GRACKET MAKE_PLOT -MAKE_WBUILD MAKE_COPYTREE MAKE_FINISH WXPRECOMP @@ -1347,13 +1345,12 @@ Optional Features: --enable-bigendian assume "big" if endianness cannot be determined --enable-oskit compile OSKit-based Racket kernel --enable-smalloskit compile small OSKit-based Racket kernel - --enable-wbuild compile and use wbuild for .w sources --enable-perl use perl to regenerate certain sources --enable-gprof compile for profiling with gprof (gcc only) --enable-gcov compile to gather gcov statistics (gcc3 only) --enable-noopt drop -O C flags --enable-sdk= use Mac OS X 10.4 SDK directory - --enable-xonx compile X11 (not Quartz) GRacket for Mac OS X + --enable-xonx compile Unix style (e.g., use Gtk) for Mac OS X --enable-libfw install Mac OS X frameworks to /Library/Frameworks --enable-userfw install Mac OS X frameworks to ~/Library/Frameworks --enable-macprefix allow --prefix with a Mac OS X install @@ -1945,11 +1942,6 @@ if test "${enable_smalloskit+set}" = set; then fi -# Check whether --enable-wbuild was given. -if test "${enable_wbuild+set}" = set; then - enableval=$enable_wbuild; -fi - # Check whether --enable-perl was given. if test "${enable_perl+set}" = set; then enableval=$enable_perl; @@ -2201,7 +2193,7 @@ show_explicitly_enabled "${enable_cgcdefault}" "CGC as default" show_explicitly_disabled "${enable_docs}" "Documentation build" -show_explicitly_enabled "${enable_xonx}" "X-on-X" +show_explicitly_enabled "${enable_xonx}" "Unix style" show_explicitly_enabled "${enable_shared}" "Shared libraries" show_explicitly_disabled "${enable_gracket}" GRacket @@ -2233,7 +2225,6 @@ show_explicitly_enabled "${enable_pthread}" "pthreads" show_explicitly_enabled "${enable_oskit}" "OSKit" show_explicitly_enabled "${enable_smalloskit}" "OSKit small mode" -show_explicitly_enabled "${enable_wbuild}" "wbuild" show_explicitly_enabled "${enable_perl}" "Perl" show_explicitly_enabled "${enable_gprof}" "gprof" @@ -5282,15 +5273,9 @@ case $OS in if test "${CC}" = "gcc" ; then CC=gcc-4.0 fi - if test "${CXX}" = "g++" ; then - CXX=g++-4.0 - fi if test "${CPP}" = "gcc -E" ; then CPP="gcc-4.0 -E" fi - if test "${CXXCPP}" = "g++ -E" ; then - CXXCPP="g++-4.0 -E" - fi if test "${LD}" = "gcc" ; then LD=gcc-4.0 fi @@ -5362,8 +5347,6 @@ case $OS in NOT_OSX=".other" MZINSTALLTARGET=osx-install DYN_CFLAGS="" - enable_xrender=no - enable_cairo=no enable_pthread=no if test "${enable_libfw}" = "yes" ; then FRAMEWORK_INSTALL_DIR=/Library/Frameworks @@ -9195,8 +9178,6 @@ LIBS="$LIBS $EXTRALIBS" - - @@ -9962,7 +9943,6 @@ AR!$AR$ac_delim STATIC_AR!$STATIC_AR$ac_delim ARFLAGS!$ARFLAGS$ac_delim STRIP_DEBUG!$STRIP_DEBUG$ac_delim -WBUILD!$WBUILD$ac_delim CC_FOR_BUILD!$CC_FOR_BUILD$ac_delim REZ!$REZ$ac_delim MZLINKER!$MZLINKER$ac_delim @@ -9996,6 +9976,7 @@ WXLIBS!$WXLIBS$ac_delim WXVARIANT!$WXVARIANT$ac_delim ICP!$ICP$ac_delim MRLIBINSTALL!$MRLIBINSTALL$ac_delim +LIBFINISH!$LIBFINISH$ac_delim _ACEOF if test `sed -n "s/.*$ac_delim\$/X/p" conf$$subs.sed | grep -c X` = 97; then @@ -10037,10 +10018,8 @@ _ACEOF ac_delim='%!_!# ' for ac_last_try in false false false false false :; do cat >conf$$subs.sed <<_ACEOF -LIBFINISH!$LIBFINISH$ac_delim MAKE_GRACKET!$MAKE_GRACKET$ac_delim MAKE_PLOT!$MAKE_PLOT$ac_delim -MAKE_WBUILD!$MAKE_WBUILD$ac_delim MAKE_COPYTREE!$MAKE_COPYTREE$ac_delim MAKE_FINISH!$MAKE_FINISH$ac_delim WXPRECOMP!$WXPRECOMP$ac_delim @@ -10074,7 +10053,7 @@ LIBOBJS!$LIBOBJS$ac_delim LTLIBOBJS!$LTLIBOBJS$ac_delim _ACEOF - if test `sed -n "s/.*$ac_delim\$/X/p" conf$$subs.sed | grep -c X` = 35; then + if test `sed -n "s/.*$ac_delim\$/X/p" conf$$subs.sed | grep -c X` = 33; then break elif $ac_last_try; then { { echo "$as_me:$LINENO: error: could not make $CONFIG_STATUS" >&5 diff --git a/src/gracket/Makefile.in b/src/gracket/Makefile.in index 725e5521a8..16746cda6e 100644 --- a/src/gracket/Makefile.in +++ b/src/gracket/Makefile.in @@ -27,7 +27,6 @@ NOOP = : ########################### CC = @CC@ LINKER = $(CC) -PERL = @PERL@ RANLIB = @RANLIB@ AR = @AR@ ARFLAGS = @ARFLAGS@ diff --git a/src/gracket/gc2/Makefile.in b/src/gracket/gc2/Makefile.in index ba76598226..a754d50d4a 100644 --- a/src/gracket/gc2/Makefile.in +++ b/src/gracket/gc2/Makefile.in @@ -20,7 +20,6 @@ PLTBUILDDIR = $(builddir)/../.. ########################### CC = @CC@ LINKER = $(CC) -PERL = @PERL@ RANLIB = @RANLIB@ AR = @AR@ ARFLAGS = @ARFLAGS@ diff --git a/src/mac/racket/simpledrop.cpp b/src/mac/racket/simpledrop.cpp deleted file mode 100644 index a3dd70b6f7..0000000000 --- a/src/mac/racket/simpledrop.cpp +++ /dev/null @@ -1,578 +0,0 @@ - -#ifdef WX_CARBON -# ifdef OS_X -# include -# else -# include -# endif -#else -# include -# include -# include -# include -#endif - -#ifndef FOR_STARTER -# include "scheme.h" -# include -# include -#else -# define scheme_malloc_atomic NewPtr -# define scheme_malloc NewPtr -# define memcpy(d, s, l) BlockMove(s, d, l) -# define malloc NewPtr - -extern int strlen(char *); -extern int isspace(int); -static void strcpy(char *s, char *d) -{ - while (*d) *(s++) = *(d++); - *s = 0; -} -#endif - -#include "simpledrop.h" - -#ifndef MZ_PRECISE_GC -# define GC_CAN_IGNORE /* empty */ -#endif - -int scheme_mac_ready, scheme_mac_argc = 0; -char **scheme_mac_argv; - -#ifdef OS_X -void GetStarterInfo(); -extern char *wxFSRefToPath(FSRef fsref); -#endif - -static char *ThisAppName(void) -{ -#ifndef FOR_STARTER -# ifdef OS_X - return "not used"; -# else - char *result, *dir; - OSErr err; - ProcessInfoRec info; - ProcessSerialNumber curPSN; - Str255 buffer; - int dlen; - - err = GetCurrentProcess(&curPSN); - - info.processInfoLength = sizeof(ProcessInfoRec); - info.processName = buffer; - info.processAppSpec = NULL; - - err = GetProcessInformation(&curPSN, &info); - - dir = scheme_os_getcwd(NULL, 0, NULL, 1); - dlen = strlen(dir); - - result = (char *)malloc(buffer[0] + dlen + 2); - memcpy(result, dir, dlen); - result[dlen] = ':'; - memcpy(result + dlen + 1, buffer + 1, buffer[0]); - result[buffer[0] + dlen + 1] = 0; - - return result; -# endif -#else - return "starter"; -#endif -} - -static void parse_commandline(char *s, char *src, int addon) -{ - GC_CAN_IGNORE char *token, *pos, ender; - int count = 0, i; - char *command[32]; - - token = s; - while (*token && (count < 32)) { - while (isspace(*token)) { - token++; - } - if (!*token) break; - - pos = token; - command[count] = pos; - while (*token && !isspace(*token)) { - if (*token == '"') { - ender = '"'; - token++; - } else if (*token == '\'') { - ender = '\''; - token++; - } else - ender = 0; - - if (ender) { - while (*token && (*token != ender)) { - *(pos++) = *(token++); - } - if (*token) - token++; - } else - *(pos++) = *(token++); - } - if (*token) - token++; - *pos = 0; - -#ifndef FOR_STARTER - if (src && !strcmp(command[count], "%%")) { - /* Replace %% with file name */ - command[count] = src; - } else if (src && (command[count][0] == '%') && (command[count][1]) == ':') { - /* Replace % with file directory */ - char *ss, *r; - int i; - i = strlen(command[count]) + strlen(src); - r = (char *)malloc(i + 1); - ss = scheme_strdup(src); - i = strlen(ss) - 1; - while (i && ss[i] != ':') { - i--; - } - ss[i + 1] = 0; - strcpy(r, ss); - strcat(r, command[count] + 2); - command[count] = r; - } -#endif - - count++; - } - - scheme_mac_argc = 1 + count + (addon ? 1 : 0); - scheme_mac_argv = (char **)malloc(scheme_mac_argc * sizeof(char *)); - scheme_mac_argv[0] = ThisAppName(); - for (i = 0; i < count; i++) { - scheme_mac_argv[i + 1] = (char *)malloc(strlen(command[i]) + 1); - strcpy(scheme_mac_argv[i + 1], command[i]); - } - if (addon) - scheme_mac_argv[count + 1] = src; -} - -extern void ParseLine(char *s, int *argc, char ***argv) -{ - parse_commandline(s, NULL, 0); - *argc = scheme_mac_argc; - *argv = scheme_mac_argv; -} - -static void Startup(char **argv, int argc) -{ - int i; - - scheme_mac_ready = 1; - - if (!argc) { - scheme_mac_argc = 1; - scheme_mac_argv = (char **)malloc(sizeof(char *)); - scheme_mac_argv[0] = ThisAppName(); - return; - } - - scheme_mac_argv = NULL; - -#if !defined(FOR_STARTER) && !defined(OS_X) - if (argc == 1) { - /* See if this file has startup flags */ - char buf[2048]; - FILE *f = fopen(argv[0], "r"); - buf[0] = 0; - if (f) { - fgets(buf, 2048, f); - fclose(f); - } - if (buf[0] == '#' && buf[1] == '!') { - GC_CAN_IGNORE char *s; - int l; - - s = buf + 2; - while (*s && !isspace(*s)) - s++; - while (*s && isspace(*s)) - s++; - - l = strlen(s); - while (l && isspace(s[l - 1])) { - --l; - s[l] = 0; - } - - if (*s) { - /* Yes, it does. */ - parse_commandline(s, argv[0], buf[2] == '!'); - } - } - } - - if (!scheme_mac_argv) { - scheme_mac_argc = (argc ? argc + 2 : 1); - scheme_mac_argv = (char **)malloc(scheme_mac_argc * sizeof(char *)); - for (i = 0; i < argc; i++) - scheme_mac_argv[i + 2] = argv[i]; - if (argc) - scheme_mac_argv[1] = "-F"; - - scheme_mac_argv[0] = ThisAppName(); - } -#else - scheme_mac_argc = argc + 1; - scheme_mac_argv = (char **)malloc(scheme_mac_argc * sizeof(char *)); - for (i = 0; i < argc; i++) { - scheme_mac_argv[i + 1] = argv[i]; - } - scheme_mac_argv[0] = ThisAppName(); -#endif -} - -static int gone = 0; - -#ifdef OS_X -extern char *scheme_mac_spec_to_path(FSSpec *spec); -#endif - -static pascal short DoNothing(const AppleEvent *a, AppleEvent *b, long c) -{ - return 0; -} - -static pascal OSErr OpenApplicationStuff(const AppleEvent *a, AppleEvent *b, long c) -{ - if (!gone) { - gone = 1; - Startup(NULL, 0); - } - - return 0; -} - -static pascal OSErr OpenFinderDoc(const AppleEvent *evt, AppleEvent *b, long c) -{ - AEDescList docList; - long count, size; - short i, j; - DescType retType; - AEKeyword keywd; - FSSpec fss; - FSRef fsref; - char **files, *fl; - OSErr err; - - AEGetParamDesc(evt, keyDirectObject, typeAEList, &docList); - AECountItems(&docList, &count); - if (gone) - files = (char **)scheme_malloc(sizeof(char *) * count); - else - files = (char **)malloc(sizeof(char *) * count); - j = 0; - for (i = 0; i < count; i++) { -#ifdef OS_X - err = AEGetNthPtr(&docList, i + 1, typeFSRef, &keywd, &retType, (Ptr)&fsref, sizeof(fsref), &size); -#else - err = errAECoercionFail; -#endif - if (err != noErr) { - if (err == errAECoercionFail) { - /* Try FSSpec: */ - FSSpec spec; - err = AEGetNthPtr(&docList, i + 1, typeFSS, &keywd, &retType, (Ptr)&fss, sizeof(FSSpec), &size); - if (err == noErr) { - fl = scheme_mac_spec_to_path(&spec); - } else { - fl = NULL; - } - } else { - fl = NULL; - } - } else { -#ifdef OS_X - fl = wxFSRefToPath(fsref); -#else - fl = NULL; -#endif - } - - if (fl) { - if (gone) - files[i + j] = fl; - else { - /* have to malloc everything */ - char *fl2; - fl2 = (char *)malloc(strlen(fl)+1); - memcpy(fl2, fl, strlen(fl)+1); - files[i + j] = fl2; - } - if (!files[i + j]) - --j; - } else - --j; - } - AEDisposeDesc(&docList); - - if (!gone) { - gone = 1; - Startup(files, count + j); - } else { - wxDrop_Runtime(files, count + j); - } - - return 0; -} - -static pascal OSErr CmdLineMessage(const AppleEvent *evt, AppleEvent *b, long c) -{ - AEDescList cmdList; - DescType retType; - AEKeyword keywd; - char *cmdLine; - long size; - - AEGetParamDesc(evt, keyDirectObject, typeAEList, &cmdList); - size = 1023; - cmdLine = (char *)malloc(size + 1); - AEGetNthPtr(&cmdList, 1, typeChar, &keywd, &retType, (Ptr)cmdLine, size, &size); - - cmdLine[size] = 0; - scheme_mac_ready = 1; - parse_commandline(cmdLine, NULL, 0); - - return 0; -} - -static pascal OSErr SetUpQuitMessage(const AppleEvent *a, AppleEvent *b, long c) -{ - wxDrop_Quit(); - return 0; -} - -static void Install(void) -{ - short err=0; - err = AEInstallEventHandler(kCoreEventClass, kAEOpenApplication, NewAEEventHandlerUPP(OpenApplicationStuff), 0, 0); - err = AEInstallEventHandler(kCoreEventClass, kAEOpenDocuments, NewAEEventHandlerUPP(OpenFinderDoc), 0, 0); - err = AEInstallEventHandler(kCoreEventClass, kAEPrintDocuments, NewAEEventHandlerUPP(DoNothing), 0, 0); - err = AEInstallEventHandler(kCoreEventClass, kAEQuitApplication, NewAEEventHandlerUPP(SetUpQuitMessage), 0, 0); - err = AEInstallEventHandler('PLT ', 'cmdl', NewAEEventHandlerUPP(CmdLineMessage), 0, 0); -} - -void wxDrop_GetArgs(int *argc, char ***argv, int *in_terminal) -{ - *in_terminal = 1; - - MZ_REGISTER_STATIC(scheme_mac_argv); - - Install(); - while (!scheme_mac_ready) { - EventRecord event; - - WaitNextEvent(highLevelEventMask, &event, 0x7FFFFFFF, 0L); - if (event.what == kHighLevelEvent) { - AEProcessAppleEvent(&event); - } - } - -#ifdef OS_X - { - int from_finder; - - from_finder = (((*argc) > 1) && (strncmp((*argv)[1],"-psn_",5) == 0)); - if (from_finder) { - /* Finder started app, or someone wants us to think so; set - *in_terminal to 0 and combine AE-based command-line with given - command line */ - int i, new_argc; - char **new_argv; - *in_terminal = 0; - new_argc = (scheme_mac_argc - 1) + ((*argc) - 2) + 1; - new_argv = (char **)malloc(new_argc * sizeof(char *)); - new_argv[0] = (*argv)[0]; - for (i = 2; i < (*argc); i++) { - new_argv[i - 1] = (*argv)[i]; - } - for (; i < new_argc + 1; i++) { - new_argv[i - 1] = scheme_mac_argv[i - (*argc) + 1]; - } - scheme_mac_argc = new_argc; - scheme_mac_argv = new_argv; - } else { - /* command-line start; no AE arguments */ - scheme_mac_argc = *argc; - scheme_mac_argv = *argv; - } - - GetStarterInfo(); - - /* Open the GRacket framework resources: */ - { - CFBundleRef fwBundle; - - fwBundle = CFBundleGetBundleWithIdentifier(CFSTR("org.racket-lang.GRacket")); - if (fwBundle) { - SInt16 refNum; - SInt16 lRefNum; - CFBundleOpenBundleResourceFiles(fwBundle, &refNum, &lRefNum); - } - } - - } -#endif - - *argc = scheme_mac_argc; - *argv = scheme_mac_argv; -} - -/**********************************************************************/ - -#ifdef OS_X - -#define BUFSIZE 1000 -#define RSRCNAME "starter-info" -#define EXECNAME "GRacket" - -static CFPropertyListRef getPropertyList() -{ - CFDataRef xmlData; - CFStringRef error; - CFPropertyListRef propertyList; - CFBundleRef appBundle; - CFURLRef myRef; - - // locate the starter's bundle: - appBundle = CFBundleGetMainBundle(); - - // get a URL for the named resource - myRef = CFBundleCopyResourceURL(appBundle, CFSTR(RSRCNAME), - NULL, NULL); - if (myRef == NULL) { - return NULL; - } - - // Load the XML data using its URL. - CFURLCreateDataAndPropertiesFromResource(kCFAllocatorDefault, myRef, - &xmlData, NULL, NULL, NULL); - - // convert to a Property List - propertyList = CFPropertyListCreateFromXMLData(kCFAllocatorDefault, xmlData, - kCFPropertyListImmutable, - &error); - if (error != NULL) { - return NULL; - } - - return propertyList; -} - -char *ConvertCFStringRef(CFStringRef str) -{ - static char buf[BUFSIZE]; - char *result; - Boolean success; - - success = CFStringGetCString(str,buf,BUFSIZE,kCFStringEncodingUTF8); - if (!success) { - return "???"; - } - result = (char *)malloc(strlen(buf) + 1); - strcpy(result,buf); - return result; -} - -char *ExeRelativeToAbsolute(char *p) -{ - CFBundleRef appBundle; - CFURLRef url; - CFStringRef str; - char *s, *a; - long len, len2; - - appBundle = CFBundleGetMainBundle(); - url = CFBundleCopyExecutableURL(appBundle); - str = CFURLCopyFileSystemPath(url, kCFURLPOSIXPathStyle); - - s = ConvertCFStringRef(str); - - len = strlen(s); - while (len && (s[len - 1] != '/')) { - --len; - } - - len2 = strlen(p); - - a = (char *)malloc(len + len2 + 1); - memcpy(a, s, len); - memcpy(a + len, p, len2 + 1); - - return a; -} - -void GetStarterInfo() -{ - int i; - CFPropertyListRef propertyList; - - propertyList = getPropertyList(); - - if (propertyList) { - CFStringRef execName; - CFArrayRef storedArgsArray; - CFIndex count; - char **storedArgs, *tmps, *orig_argv0 = NULL; - int name_offset; - - if (CFDictionaryContainsKey((CFDictionaryRef)propertyList, - (const void *)(CFSTR("executable name")))) { - execName = (CFStringRef)CFDictionaryGetValue((CFDictionaryRef)propertyList, - (CFSTR("executable name"))); - tmps = ConvertCFStringRef(execName); - if (tmps[0] != '/') { - /* Path is relative to this executable */ - tmps = ExeRelativeToAbsolute(tmps); - } - orig_argv0 = scheme_mac_argv[0]; - scheme_mac_argv[0] = tmps; - } - - if (CFDictionaryContainsKey((CFDictionaryRef)propertyList, - (const void *)CFSTR("stored arguments"))) { - storedArgsArray = (CFArrayRef)CFDictionaryGetValue((CFDictionaryRef)propertyList, - (CFSTR("stored arguments"))); - } else { - return; - } - - count = CFArrayGetCount(storedArgsArray); - - name_offset = (orig_argv0 ? 2 : 0); - - storedArgs = (char **)malloc(sizeof(char *) * (scheme_mac_argc + count + name_offset)); - - storedArgs[0] = scheme_mac_argv[0]; - if (orig_argv0) { - /* Preserve the "run" name for a launcher: */ - storedArgs[1] = "-N"; - storedArgs[2] = orig_argv0; - } - - for (i = 0; i < count; i++) { - CFStringRef arg; - char *tmps; - arg = (CFStringRef)CFArrayGetValueAtIndex(storedArgsArray,i); - tmps = ConvertCFStringRef(arg); - storedArgs[i + 1 + name_offset] = tmps; - } - for (i = 1; i < scheme_mac_argc; i++) { - storedArgs[count + i + name_offset] = scheme_mac_argv[i]; - } - - scheme_mac_argv = storedArgs; - scheme_mac_argc += count + name_offset; - } -} - -#endif diff --git a/src/mac/racket/simpledrop.h b/src/mac/racket/simpledrop.h deleted file mode 100644 index c9fc22d257..0000000000 --- a/src/mac/racket/simpledrop.h +++ /dev/null @@ -1,13 +0,0 @@ -/* Call to start: */ -extern void wxDrop_GetArgs(int *, char ***, int *in_terminal); - -/* You supply: */ -void wxDrop_Runtime(char **, int); -void wxDrop_Quit(void); - -/* Utility: */ -extern void ParseLine(char *, int *, char ***); - -extern int scheme_mac_ready; -extern int scheme_mac_argc; -extern char **scheme_mac_argv; diff --git a/src/plot/Makefile.in b/src/plot/Makefile.in index 14c0d190af..e52176c5b1 100644 --- a/src/plot/Makefile.in +++ b/src/plot/Makefile.in @@ -43,15 +43,21 @@ XCOLLECTS = -X ../racket/gc2/xform-collects CC = @CC@ +# This seems like a good idea, but it doesn't work with +# libtool as the compiler. So, we trust the configuration +# taht is built into dynext, instead. +# WITH-ENV = env CC="$(CC)" LD="@MZLINKER@" +WITH_ENV = + # In 3m mode, we can reply on an xform-collects setup 3m: - env CC="$(CC)" LD="@MZLINKER@" ../racket/racket3m $(XCOLLECTS) $(srcdir)/build.rkt "libplplot" $(PLPLOT_SRCS) - env CC="$(CC)" LD="@MZLINKER@" ../racket/racket3m $(XCOLLECTS) $(srcdir)/build.rkt "libfit" $(FIT_SRCS) + $(WITH_ENV) ../racket/racket3m $(XCOLLECTS) $(srcdir)/build.rkt "libplplot" $(PLPLOT_SRCS) + $(WITH_ENV) ../racket/racket3m $(XCOLLECTS) $(srcdir)/build.rkt "libfit" $(FIT_SRCS) # In just-cgc mode, it's slow to load build.rkt: cgc: - env CC="$(CC)" LD="@MZLINKER@" ../racket/racketcgc -c $(srcdir)/build.rkt "libplplot" $(PLPLOT_SRCS) - env CC="$(CC)" LD="@MZLINKER@" ../racket/racketcgc -c $(srcdir)/build.rkt "libfit" $(FIT_SRCS) + $(WITH_ENV) ../racket/racketcgc -c $(srcdir)/build.rkt "libplplot" $(PLPLOT_SRCS) + $(WITH_ENV) ../racket/racketcgc -c $(srcdir)/build.rkt "libfit" $(FIT_SRCS) install: cd ..; $(ICP) plot/libplplot@SO_SUFFIX@ "$(DESTDIR)$(libpltdir)/libplplot@SO_SUFFIX@" diff --git a/src/racket/configure.ac b/src/racket/configure.ac index 3c823e76d4..902d270c4b 100644 --- a/src/racket/configure.ac +++ b/src/racket/configure.ac @@ -56,7 +56,6 @@ AC_ARG_ENABLE(bigendian, [ --enable-bigendian assume "big" if endianness c AC_ARG_ENABLE(oskit, [ --enable-oskit compile OSKit-based Racket kernel]) AC_ARG_ENABLE(smalloskit, [ --enable-smalloskit compile small OSKit-based Racket kernel]) -AC_ARG_ENABLE(wbuild, [ --enable-wbuild compile and use wbuild for .w sources]) AC_ARG_ENABLE(perl, [ --enable-perl use perl to regenerate certain sources]) AC_ARG_ENABLE(gprof, [ --enable-gprof compile for profiling with gprof (gcc only)]) @@ -66,7 +65,7 @@ AC_ARG_ENABLE(noopt, [ --enable-noopt drop -O C flags]) AC_ARG_ENABLE(enable_sdk, [ --enable-sdk= use Mac OS X 10.4 SDK directory]) -AC_ARG_ENABLE(xonx, [ --enable-xonx compile X11 (not Quartz) GRacket for Mac OS X]) +AC_ARG_ENABLE(xonx, [ --enable-xonx compile Unix style (e.g., use Gtk) for Mac OS X]) AC_ARG_ENABLE(libfw, [ --enable-libfw install Mac OS X frameworks to /Library/Frameworks]) AC_ARG_ENABLE(libfw, [ --enable-userfw install Mac OS X frameworks to ~/Library/Frameworks]) AC_ARG_ENABLE(macprefix, [ --enable-macprefix allow --prefix with a Mac OS X install]) @@ -264,7 +263,7 @@ show_explicitly_enabled "${enable_cgcdefault}" "CGC as default" show_explicitly_disabled "${enable_docs}" "Documentation build" -show_explicitly_enabled "${enable_xonx}" "X-on-X" +show_explicitly_enabled "${enable_xonx}" "Unix style" show_explicitly_enabled "${enable_shared}" "Shared libraries" show_explicitly_disabled "${enable_gracket}" GRacket @@ -296,7 +295,6 @@ show_explicitly_enabled "${enable_pthread}" "pthreads" show_explicitly_enabled "${enable_oskit}" "OSKit" show_explicitly_enabled "${enable_smalloskit}" "OSKit small mode" -show_explicitly_enabled "${enable_wbuild}" "wbuild" show_explicitly_enabled "${enable_perl}" "Perl" show_explicitly_enabled "${enable_gprof}" "gprof" @@ -605,15 +603,9 @@ case $OS in if test "${CC}" = "gcc" ; then CC=gcc-4.0 fi - if test "${CXX}" = "g++" ; then - CXX=g++-4.0 - fi if test "${CPP}" = "gcc -E" ; then CPP="gcc-4.0 -E" fi - if test "${CXXCPP}" = "g++ -E" ; then - CXXCPP="g++-4.0 -E" - fi if test "${LD}" = "gcc" ; then LD=gcc-4.0 fi @@ -685,8 +677,6 @@ case $OS in NOT_OSX=".other" MZINSTALLTARGET=osx-install DYN_CFLAGS="" - enable_xrender=no - enable_cairo=no enable_pthread=no if test "${enable_libfw}" = "yes" ; then FRAMEWORK_INSTALL_DIR=/Library/Frameworks @@ -1132,7 +1122,6 @@ AC_SUBST(AR) AC_SUBST(STATIC_AR) AC_SUBST(ARFLAGS) AC_SUBST(STRIP_DEBUG) -AC_SUBST(WBUILD) AC_SUBST(CC_FOR_BUILD) AC_SUBST(REZ) AC_SUBST(MZLINKER) @@ -1177,7 +1166,6 @@ AC_SUBST(LIBFINISH) AC_SUBST(MAKE_GRACKET) AC_SUBST(MAKE_PLOT) -AC_SUBST(MAKE_WBUILD) AC_SUBST(MAKE_COPYTREE) AC_SUBST(MAKE_FINISH) diff --git a/src/worksp/README b/src/worksp/README index a8c5e86845..b2b11f2caa 100644 --- a/src/worksp/README +++ b/src/worksp/README @@ -54,7 +54,6 @@ racket\src\README if you don't know about the two variants.) The 3m build requires some parts of the CGC build: racket\src\worksp\racket - racket\src\worksp\wxutils racket\src\worksp\jpeg racket\src\worksp\png racket\src\worksp\zlib @@ -79,25 +78,13 @@ To build GRacketCGC, build the GRacket solution: [Again, switch to the "Release" configuration if necessary.] -The build processes for RacketCGC automatically builds +The build processes for RacketCGC and GRacketCGC automatically +builds libmzgc - makes racket\lib\libmzgcxxxxxxx.dll and racket\src\worksp\libmzgc\Release\libmzgcxxxxxxx.lib libracket - makes racket\lib\libracketxxxxxxx.dll and racket\src\worksp\mzsrc\Release\mzsrcxxxxxxx.lib -The build process for GRacketCGC automatically builds - libmzgc - as above - libracket - as above - libgracket - makes racket\lib\libgracketxxxxxxx.dll and - racket\src\worksp\libgracket\Release\libgracketxxxxxxx.lib - wxutils - makes racket\src\worksp\wxutils\Release\wxutils.lib - wxwin - makes racket\src\worksp\wxwin\Release\wxwin.lib - wxs - makes racket\src\worksp\wxs\Release\wxs.lib - wxme - makes racket\src\worksp\wxme\Release\wxme.lib - jpeg - makes racket\src\worksp\jpeg\Release\jpeg.lib - png - makes racket\src\worksp\jpeg\Release\png.lib - zlib - makes racket\src\worksp\jpeg\Release\zlib.lib - In addition, building RacketCGC executes racket\src\racket\dynsrc\mkmzdyn.bat which copies .exp, .obj, and .lib files into racket\lib\, and also @@ -106,12 +93,15 @@ copies DLLs from the "extradlls" directory to to racket\lib\. Finally, you must install pre-build DLLs that GRacket needs to run. The DLLs are available from - http://github.com/mflatt/gracket-libs/tree/master/win32/i386/?raw=true + http://download.racket-lang.org/libs/ and they must be installed into racket\lib +The "get-libs.rkt" script in "racket\src\gracket" can download the +libraries, and the script is used by "build.bat". + Building Racket3m and GRacket3m ------------------------------- @@ -127,10 +117,9 @@ After RacketCGC and GRacketCGC are built, you can can build 3m binaries: ..\..\..\racketcgc.exe -c make.rkt The resulting Racket.exe and GRacket.exe will appear in the top-level -"racket" directory, along with DLLs libracket3mxxxxxxx.dll and -libgracket3mxxxxxxx.dll in racket\lib. (There is no corresponding -libmzgc3mxxxxxxx.dll. Instead, it is merged with -libracket3mxxxxxxx.dll.) +"racket" directory, along with DLLs libracket3mxxxxxxx.dll in +racket\lib. (There is no corresponding libmzgc3mxxxxxxx.dll. +Instead, it is merged with libracket3mxxxxxxx.dll.) Building Collections and Other Executables ------------------------------------------ @@ -239,9 +228,8 @@ The result is mxmain.dll (no 3m suffix) in Finding DLLs ------------ -Since the DLLs libracket3mxxxxxxx.dll (or libmzgcxxxxxxx.dll and -libracketxxxxxxx.dll) and libgracket3mxxxxxxx.dll (or -libgracketxxxxxxx.dll) are installed into racket\lib\ instead of just +Since the DLL libracket3mxxxxxxx.dll (or libmzgcxxxxxxx.dll and +libracketxxxxxxx.dll) is installed into racket\lib\ instead of just racket\, the normal search path for DLLs would not find them when running "Racket.exe" or "GRacket.exe". To find the DLLs, the executables are "delayload" linked with the DLLs, and the executables diff --git a/src/worksp/libgracket/libgracket.vcproj b/src/worksp/libgracket/libgracket.vcproj deleted file mode 100644 index e89b6b005d..0000000000 --- a/src/worksp/libgracket/libgracket.vcproj +++ /dev/null @@ -1,216 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -