(index ("install-extension" 0) ("install-program" 1092) ("install-script" 1322) ("standard-extension" 1581) ("run" 2266) ("compile" 2626) ("patch" 2734) ("copy-file" 3143) ("move-file" 3341) ("remove-file*" 3538) ("find-library" 3689) ("find-header" 4113) ("try-compile" 4285) ("create-directory/parents" 4882) ("extension-name-and-version" 5074) ("version>=?" 5365) ("installation-prefix" 5888) ("program-path" 6173) ("setup-root-directory" 6505) ("setup-install-mode" 6674) ("host-extension" 6907))
(def (sig (procedure "(install-extension ID FILELIST [INFOLIST])" (id install-extension))) (p "Installs the extension library with the name " (tt "ID") ". All files given in the list of strings " (tt "FILELIST") " will be copied to the extension repository. It should be noted here that the extension id has to be identical to the name of the file implementing the extension. The extension may load or include other files, or may load other extensions at runtime specified by the " (tt "require-at-runtime") " property.") (p (tt "FILELIST") " may be a filename, a list of filenames, or a list of pairs of the form " (tt "(SOURCE DEST)") " (if you want to copy into a particular sub-directory - the destination directory will be created as needed). If " (tt "DEST") " is a relative pathname, it will be copied into the extension repository.") (p "The optional argument " (tt "INFOLIST") " should be an association list that maps symbols to values, this list will be stored as " (tt "ID.setup-info") " at the same location as the extension code. Currently the following properties are used:"))
(def (sig (procedure "(install-program ID FILELIST [INFOLIST])" (id install-program))) (p "Similar to " (tt "install-extension") ", but installs an executable program in the executable path (usually " (tt "/usr/local/bin") ")."))
(def (sig (procedure "(install-script ID FILELIST [INFOLIST])" (id install-script))) (p "Similar to " (tt "install-program") ", but additionally changes the file permissions of all files in " (tt "FILELIST") " to executable (for installing shell-scripts)."))
(def (sig (procedure "(standard-extension ID [VERSION] #!key info)" (id standard-extension))) (p "A convenience procedure that combines the compilation and installation of a simple single-file extension. This is roughly equivalent to:") (pre " (compile -s -O3 -d1 ID.scm -j ID)\n (compile -s -O3 -d0 ID.import.scm)\n \n (install-extension\n  'ID\n  '(\"ID.so\" \"ID.import.so\")\n  '((version VERSION)\n    ... `INFO' ...\n    ))") (p (tt "VERSION") " may be " (tt "#f") " or can be omitted, in that case the version obtained from where the extension has been retrieved wil be taken. If installed directly from a local directory, the version will default to " (tt "\"unknown\"") "."))
(def (sig (syntax "(run FORM ...)" (id run))) (p "Runs the shell command " (tt "FORM") ", which is wrapped in an implicit " (tt "quasiquote") ". " (tt "(run (csc ...))") " is treated specially and passes " (tt "-v") " (if " (tt "-verbose") " has been given to " (tt "chicken-install") ") and " (tt "-feature compiling-extension") " options to the compiler."))
(def (sig (syntax "(compile FORM ...)" (id compile))) (p "Equivalent to " (tt "(run (csc FORM ...))") "."))
(def (sig (procedure "(patch WHICH REGEX SUBST)" (id patch))) (p "Replaces all occurrences of the regular expression " (tt "REGEX") " with the string " (tt "SUBST") ", in the file given in " (tt "WHICH") ". If " (tt "WHICH") " is a string, the file will be patched and overwritten. If " (tt "WHICH") " is a list of the form " (tt "OLD NEW") ", then a different file named " (tt "NEW") " will be generated."))
(def (sig (procedure "(copy-file FROM TO)" (id copy-file))) (p "Copies the file or directory (recursively) given in the string " (tt "FROM") " to the destination file or directory " (tt "TO") "."))
(def (sig (procedure "(move-file FROM TO)" (id move-file))) (p "Moves the file or directory (recursively) given in the string " (tt "FROM") " to the destination file or directory " (tt "TO") "."))
(def (sig (procedure "(remove-file* PATH)" (id remove-file*))) (p "Removes the file or directory given in the string " (tt "PATH") ", if it exists."))
(def (sig (procedure "(find-library NAME PROC)" (id find-library))) (p "Returns " (tt "#t") " if the library named " (tt "libNAME.[a|so]") " (unix) or " (tt "NAME.lib") " (windows) could be found by compiling and linking a test program. " (tt "PROC") " should be the name of a C function that must be provided by the library. If no such library was found or the function could not be resolved, " (tt "#f") " is returned."))
(def (sig (procedure "(find-header NAME)" (id find-header))) (p "Returns " (tt "#t") " if a C include-file with the given name is available, or " (tt "#f") " otherwise."))
(def (sig (procedure "(try-compile CODE #!key cc cflags ldflags compile-only c++)" (id try-compile))) (p "Returns " (tt "#t") " if the C code in " (tt "CODE") " compiles and links successfully, or " (tt "#f") " otherwise. The keyword parameters " (tt "cc") " (compiler name, defaults to the C compiler used to build this system), " (tt "cflags") " and " (tt "ldflags") " accept additional compilation and linking options. If " (tt "compile-only") " is true, then no linking step takes place. If the keyword argument " (tt "c++") " is given and true, then the code will be compiled in C++ mode."))
(def (sig (procedure "(create-directory/parents PATH)" (id create-directory/parents))) (p "Creates the directory given in the string " (tt "PATH") ", with all parent directories as needed."))
(def (sig (parameter "extension-name-and-version" (id extension-name-and-version))) (p "Returns a list containing the name and version of the currently installed extension as strings. If the setup script is not invoked via " (tt "chicken-install") ", then name and version will be empty."))
(def (sig (procedure "(version>=? V1 V2)" (id version>=?))) (p "Compares the version numbers " (tt "V1") " and " (tt "V2") " and returns " (tt "#t") " if " (tt "V1") " is \"less\" than " (tt "V2") " or " (tt "#f") " otherwise. A version number can be an integer, a floating-point number or a string. " (tt "version>=?") " handles dot-separated version-indicators of the form " (tt "\"X.Y. ..\"") ".") (p "If one version number is the prefix of the other, then the shorter version is considered \"less\" than the longer."))
(def (sig (procedure "(installation-prefix)" (id installation-prefix))) (p "An alternative installation prefix that will be prepended to extension installation paths if specified. It is set by the " (tt "-prefix") " option or environment variable " (tt "CHICKEN_INSTALL_PREFIX") "."))
(def (sig (parameter "(program-path [PATH])" (id program-path))) (p "Holds the path where executables are installed and defaults to either " (tt "$CHICKEN_PREFIX/bin") ", if the environment variable " (tt "CHICKEN_PREFIX") " is set or the path where the CHICKEN binaries (" (tt "chicken") ", " (tt "csi") ", etc.) are installed."))
(def (sig (parameter "(setup-root-directory [PATH])" (id setup-root-directory))) (p "Contains the path of the directory where " (tt "chicken-install") " was invoked."))
(def (sig (parameter "(setup-install-mode [BOOL])" (id setup-install-mode))) (p "Reflects the setting of the " (tt "-no-install") " option, i.e. is " (tt "#f") ", if " (tt "-no-install") " was given to " (tt "chicken-install") "."))
(def (sig (parameter "host-extension" (id host-extension))) (p "For a cross-compiling CHICKEN, when compiling an extension, then it should be built for the host environment (as opposed to the target environment). This parameter is controlled by the " (tt "-host") " command-line option. A setup script should perform the proper steps of compiling any code by passing " (tt "-host") " when invoking " (tt "csc") " or using the " (tt "compile") " macro."))
