next | previous | forward | backward | up | top | index | toc | Macaulay2 web site
Macaulay2Doc > how Macaulay2 finds its files > currentLayout

currentLayout -- relative locations of Macaulay2 files


Macaulay2 comes with a variety of types of files, and some of them are associated with a particular Macaulay2 package. The hash table currentLayout is a translation table from names, corresponding to the various types of files, to directory paths. The directory paths are to be interpreted relative to the path stored in prefixDirectory. Each of the directories contained in the list prefixPath has its own layout, which will be detected at runtime. Some of the strings contain PKG as a substring, which should be replaced by the name of package whose files will be stored in that directory.

The hash table Layout contains the two possible values for currentLayout; corresponding to the two possible values for the SeparateExec option used with installPackage. The hash table Layout#2 is used if architecture dependent files are to be stored in a directory tree separate from the one used for architecture independent files. The hash table Layout#1 is used otherwise.

Basic Macaulay2 files are regarded as being associated with a special package called Core, and the corresponding documentation files are part of the package Macaulay2Doc.

i1 : Layout

o1 = HashTable{1 => HashTable{bin => bin/                                                    }                  }
                              common => 
                              data => share/
                              doc => share/doc/Macaulay2/
                              docdir => share/doc/Macaulay2/
                              emacs => share/emacs/site-lisp/
                              exec => 
                              factory gftables => share/Macaulay2/Core/factory/
                              info => share/info/
                              lib => lib/
                              libraries => lib/Macaulay2/lib/
                              man => share/man/
                              package => share/Macaulay2/PKG/
                              packagecache => lib/Macaulay2/PKG/cache/
                              packagedoc => share/doc/Macaulay2/PKG/
                              packageexampleoutput => share/doc/Macaulay2/PKG/example-output/
                              packagehtml => share/doc/Macaulay2/PKG/html/
                              packageimages => share/doc/Macaulay2/PKG/images/
                              packagelib => lib/Macaulay2/PKG/
                              packages => share/Macaulay2/
                              packagetests => share/doc/Macaulay2/PKG/tests/
                              program licenses => libexec/Macaulay2/program-licenses/
                              programs => libexec/Macaulay2/bin/
               2 => HashTable{bin => x86_64-Linux-Ubuntu-18.10/bin/                                            }
                              common => common/
                              data => common/share/
                              doc => common/share/doc/Macaulay2/
                              docdir => common/share/doc/Macaulay2/
                              emacs => common/share/emacs/site-lisp/
                              exec => x86_64-Linux-Ubuntu-18.10/
                              factory gftables => common/share/Macaulay2/Core/factory/
                              info => common/share/info/
                              lib => x86_64-Linux-Ubuntu-18.10/lib/
                              libraries => x86_64-Linux-Ubuntu-18.10/lib/Macaulay2/lib/
                              man => common/share/man/
                              package => common/share/Macaulay2/PKG/
                              packagecache => x86_64-Linux-Ubuntu-18.10/lib/Macaulay2/PKG/cache/
                              packagedoc => common/share/doc/Macaulay2/PKG/
                              packageexampleoutput => common/share/doc/Macaulay2/PKG/example-output/
                              packagehtml => common/share/doc/Macaulay2/PKG/html/
                              packageimages => common/share/doc/Macaulay2/PKG/images/
                              packagelib => x86_64-Linux-Ubuntu-18.10/lib/Macaulay2/PKG/
                              packages => common/share/Macaulay2/
                              packagetests => common/share/doc/Macaulay2/PKG/tests/
                              program licenses => x86_64-Linux-Ubuntu-18.10/libexec/Macaulay2/program-licenses/
                              programs => x86_64-Linux-Ubuntu-18.10/libexec/Macaulay2/bin/

o1 : HashTable
Here are the meanings of the keys used in currentLayout.
  • "bin" : executable files (M2)
  • "common" : architecture independent files
  • "data" : architecture independent data files
  • "doc" : documentation
  • "docdir" : documentation for Macaulay2 packages
  • "emacs" : emacs source files (*.el, *.elc)
  • "exec" : architecture dependent files
  • "factory gftables" : directory for files containing addition tables in small finite fields used by the library 'factory'
  • "info" : documentation in info form
  • "lib" : architecture dependent data and executable files
  • "libraries" : dynamically loadable libraries from third party packages linked with Macaulay2
  • "man" : man pages
  • "package" : additional source files for the Macaulay2 package PKG
  • "packagecache" : cached data files for the Macaulay2 package PKG
  • "packagedoc" : documentation for the Macaulay2 package PKG
  • "packageexampleoutput" : example output files for the Macaulay2 package PKG
  • "packagehtml" : html documentation for the Macaulay2 package PKG (*.html)
  • "packageimages" : images for the Macaulay2 package PKG (*.jpg)
  • "packagelib" : architecture dependent files for the Macaulay2 package PKG
  • "packages" : source files for Macaulay2 packages; this directory appears on the path
  • "packagetests" : test files for the Macaulay2 package PKG
  • "program licenses" : licenses for programs to be run by Macaulay2
  • "programs" : programs to be run by Macaulay2

See also

For the programmer

The object currentLayout is a hash table.