Permalink
Browse files

- added custom install options. workarea creates an empty config.h,

  and configure creates a config.h that sets the default scheme heap
  path and scheme-script name based on the actual configuration.
    configure, newrelease, workarea, checkin,
    c/Mf-base, scheme.c, main.c,
    Mf-install.in
- renamed the installed example directory from lib to examples.
    Mf-install.in,
    scheme.1.in
- added force option to gzip during man page install to prevent gzip from
  asking for permission to overwrite existing man page files.
    Mf-install.in
- removed ~/lib/csv%v/%m from the default scheme heap path on unix-like
  systems.  documented inclusion of %x\..\..\boot\%m in the Windows
  default scheme heap path.
    main.c,
    use.stex
- added new configuration options: --installbin, --installlib,
  --installschemename, --installpetitename, and --installscriptname.
    configure
- updated the example library link to the nanopass framework.
    CONTRIBUTING.md
- now cleaning up petite.1 and scheme.1 left behind by make install
    Makefile-workarea.in, checkin
- now removing workarea after cleaning csug and release_notes so
  Mf-stex (included from csug/Makefile and release_notes/Makefile)
  doesn't complain trying to determine the machine type.
    Makefile.in
- added installsh support for --ifdiff so the csug make file can use it
  for the install target.
    installsh,
    csug/Makefile
- added instructions for building (cross-compiling) a boot file for
  a supported machine type for which a boot file is not built by default.
    BUILDING
  • Loading branch information...
1 parent 40c1541 commit df4194c83a9e67d1ec20165fc3e2def4ed8e8986 Andy Keep committed May 6, 2016
Showing with 194 additions and 141 deletions.
  1. +9 −0 BUILDING
  2. +3 −3 CONTRIBUTING.md
  3. +35 −2 LOG
  4. +2 −1 c/Mf-base
  5. +0 −32 c/heappath.h.in
  6. +6 −1 c/main.c
  7. +14 −11 c/scheme.c
  8. +3 −2 checkin
  9. +63 −30 configure
  10. +9 −8 csug/Makefile
  11. +3 −2 csug/use.stex
  12. +1 −0 makefiles/Makefile-workarea.in
  13. +1 −1 makefiles/Makefile.in
  14. +28 −31 makefiles/Mf-install.in
  15. +11 −10 makefiles/installsh
  16. +0 −4 newrelease
  17. +3 −3 scheme.1.in
  18. +3 −0 workarea
View
@@ -150,6 +150,15 @@ The make file supports several targets:
boot and header files can be committed as well. 'make bootfiles'
can take 5 minutes or more.
+ 'make bootfiles' builds boot files for each machine type for which
+ a subdirectory exists in the top-level boot directory. to build
+ for a supported machine type that isn't built by default, simply
+ add the appropriate subdirectory, i.e., 'mkdir boot/$M', where M
+ is the machine type, before running 'make bootfiles'. You can
+ also run '(cd $W ; make -f Mf-boot $M.boot)', where W is the name
+ of a built work area for the host machine type, to build just the
+ boot files for machine-type M.
+
'make clean'
removes binaries from the workarea.
View
@@ -85,9 +85,9 @@ Please keep in mind the following guidance when preparing contributions:
of their own. If you are contributing a significant extension built
using Chez Scheme, consider whether your contribution is such an
independent project. An example of such a project is the [Nanopass
- Framework](http://github.com/akeep/nanopass-framework) which is
- both used by Chez Scheme and was initially written using Chez Scheme,
- but evolves separately.
+ Framework](http://github.com/nanopass/nanopass-framework-scheme)
+ which is both used by Chez Scheme and was initially written using
+ Chez Scheme, but evolves separately.
Before investing significant effort preparing a contribution,
consider running the idea by one of the committers for additional
View
@@ -104,5 +104,38 @@
configure, makefiles/Makefile.in,
csug/Makefile, copyright.stex, csug.stex,
release_notes/Makefile
-- added custom install options.
- configure newrelease scheme.c heappath.h.in
+- added custom install options. workarea creates an empty config.h,
+ and configure creates a config.h that sets the default scheme heap
+ path and scheme-script name based on the actual configuration.
+ configure, newrelease, workarea, checkin,
+ c/Mf-base, scheme.c, main.c,
+ Mf-install.in
+- renamed the installed example directory from lib to examples.
+ Mf-install.in,
+ scheme.1.in
+- added force option to gzip during man page install to prevent gzip from
+ asking for permission to overwrite existing man page files.
+ Mf-install.in
+- removed ~/lib/csv%v/%m from the default scheme heap path on unix-like
+ systems. documented inclusion of %x\..\..\boot\%m in the Windows
+ default scheme heap path.
+ main.c,
+ use.stex
+- added new configuration options: --installbin, --installlib,
+ --installschemename, --installpetitename, and --installscriptname.
+ configure
+- updated the example library link to the nanopass framework.
+ CONTRIBUTING.md
+- now cleaning up petite.1 and scheme.1 left behind by make install
+ Makefile-workarea.in, checkin
+- now removing workarea after cleaning csug and release_notes so
+ Mf-stex (included from csug/Makefile and release_notes/Makefile)
+ doesn't complain trying to determine the machine type.
+ Makefile.in
+- added installsh support for --ifdiff so the csug make file can use it
+ for the install target.
+ installsh,
+ csug/Makefile
+- added instructions for building (cross-compiling) a boot file for
+ a supported machine type for which a boot file is not built by default.
+ BUILDING
View
@@ -27,7 +27,7 @@ kernelsrc=statics.c segment.c alloc.c symbol.c intern.c gcwrapper.c gc-ocd.c gc-
kernelobj=${kernelsrc:%.c=%.$o} ${mdobj}
-kernelhdr=system.h types.h version.h globals.h externs.h segment.h gc.c sort.h thread.h itest.c
+kernelhdr=system.h types.h version.h globals.h externs.h segment.h gc.c sort.h thread.h config.h itest.c
mainsrc=main.c
@@ -44,6 +44,7 @@ rootsrc=$(shell cd ../../c; echo *)
${rootsrc}: ; ln -s ../../c/$@ $@
scheme.o: itest.c
+scheme.o main.o: config.h
${kernelobj}: system.h types.h version.h externs.h globals.h segment.h thread.h sort.h
${kernelobj}: ${Include}/equates.h ${Include}/scheme.h
${mainobj}: ${Include}/scheme.h
View
@@ -1,32 +0,0 @@
-/* heappath.h
- * Copyright 1984-2016 Cisco Systems, Inc.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-/* This file sets the default search path for the scheme boot directory. */
-
-#define SEARCHPATHMAXSIZE 8192
-#ifdef WIN32
-
-#define SEARCHPATHSEP ';'
-/* by default, look in executable directory or in parallel boot directory */
-#define defaultsystemheappath "%x;%x\\..\\..\\boot\\%m"
-
-#else /* not WIN32: */
-
-#define SEARCHPATHSEP ':'
-/* keep in sync with scheme.1 */
-#define defaultsystemheappath "/usr/lib/csv%v/%m:/usr/local/lib/csv%v/%m"
-
-#endif
View
@@ -25,6 +25,7 @@
#include <string.h>
#include <stdio.h>
#include "scheme.h"
+#include "config.h"
/****
CUSTOM_INIT may be defined as a function with the signature shown to
@@ -45,6 +46,10 @@
#define ABNORMAL_EXIT ((void (*)(void))0)
#endif /* ABNORMAL_EXIT */
+#ifndef SCHEME_SCRIPT
+#define SCHEME_SCRIPT "scheme-script"
+#endif
+
static const char *path_last(const char *p) {
const char *s;
#ifdef WIN32
@@ -92,7 +97,7 @@ int main(int argc, const char *argv[]) {
Sscheme_init(ABNORMAL_EXIT);
- if (strcmp(path_last(execpath), "scheme-script") == 0) {
+ if (strcmp(path_last(execpath), SCHEME_SCRIPT) == 0) {
if (argc < 2) {
(void) fprintf(stderr,"%s requires program-path argument\n", execpath);
exit(1);
View
@@ -15,6 +15,7 @@
*/
#include "system.h"
+#include "config.h"
#include <setjmp.h>
#include <limits.h>
#ifdef WIN32
@@ -403,29 +404,31 @@ static const char *path_last(p) const char *p; {
return p;
}
-#include "heappath.h"
+#define SEARCHPATHMAXSIZE 8192
#ifdef WIN32
+#ifndef DEFAULT_HEAP_PATH
+/* by default, look in executable directory or in parallel boot directory */
+#define DEFAULT_HEAP_PATH "%x;%x\\..\\..\\boot\\%m"
+#endif
+#define SEARCHPATHSEP ';'
static char *get_defaultheapdirs() {
char *result;
static char defaultheapdirs[SEARCHPATHMAXSIZE];
char key[PATH_MAX];
snprintf(key, PATH_MAX, "HKEY_LOCAL_MACHINE\\Software\\Chez Scheme\\csv%s\\HeapSearchPath", VERSION);
result = S_GetRegistry(defaultheapdirs, SEARCHPATHMAXSIZE, key);
- if (result == NULL) result = defaultsystemheappath;
+ if (result == NULL) result = DEFAULT_HEAP_PATH;
return result;
}
#else /* not WIN32: */
+#define SEARCHPATHSEP ':'
+#ifndef DEFAULT_HEAP_PATH
+#define DEFAULT_HEAP_PATH "/usr/lib/csv%v/%m:/usr/local/lib/csv%v/%m"
+#endif
+
static char *get_defaultheapdirs() {
- static char defaultheapdirs[SEARCHPATHMAXSIZE];
- const char *home;
-
- if ((home = S_homedir()) != NULL &&
- (snprintf(defaultheapdirs, SEARCHPATHMAXSIZE, "%s/lib/csv%%v/%%m:%s",
- home, defaultsystemheappath) < SEARCHPATHMAXSIZE))
- return defaultheapdirs;
- else
- return defaultsystemheappath;
+ return DEFAULT_HEAP_PATH;
}
#endif /* WIN32 */
View
@@ -90,6 +90,7 @@ echo '*** running "make clean" in source directories ***'
foreach x ($sdirs)
switch ($x)
case .:
+ (cd $W; /bin/rm -f petite.1 scheme.1)
(cd $W; /bin/rm -f Make.out)
case unicode:
case unicode/UNIDATA:
@@ -121,7 +122,7 @@ end
set sfiles = ()
foreach x ($tmpsfiles)
- if ("$x" == "./Makefile" || "$x" == "./Mf-install" || "$x" == "./Mf-boot") then
+ if ("$x" == "./Makefile" || "$x" == "./Mf-install" || "$x" == "./Mf-boot" || "$x" == "c/config.h") then
set ignorefiles = ($ignorefiles $x)
else
cmp $W/$x $x >& /dev/null
@@ -190,7 +191,7 @@ set RESPONSE = ""
while ("$RESPONSE" != "y")
echo -n "proceed with check in? (y/n): "
set RESPONSE = $<
- if ("$RESPONSE" == "n") goto error
+ if ("$RESPONSE" == "n") exit 0
end
set oldsfiles = ()
Oops, something went wrong.

0 comments on commit df4194c

Please sign in to comment.