## filename-policy.api
## (C) 1999 Lucent Technologies, Bell Laboratories
## Author: Matthias Blume (blume@kurims.kyoto-u.ac.jp)
# Compiled by:
#
src/app/makelib/makelib.sublibstipulate
package ad = anchor_dictionary; # anchor_dictionary is from
src/app/makelib/paths/anchor-dictionary.pkgherein
api Filename_Policy {
# Given a file foo.pkg, where should the compiled .compiled file be put?
# Given a file Foo.lib, where should the library freezefile be put?
#
# 'Policy' objects provide a central way of
# specifying the answers to such questions.
#
# A Policy object is (internally) a record of functions,
# each of which accepts a sourcefile name as argument
# and returns the name for some derived file.
#
Policy;
policy: Policy;
# The following functions generate the names
# for the various derived files generated
# by the makelib/compiler system:
#
# .compiled files contain the object code from compiling
# one Mythryl sourcefile: They correspond to
# unix .o files.
#
# .frozen files (freezefiles -- Mythryl code libraries)
# contain all the .compiled files compiled by one
# .lib file: They correspond to unix .a or .so files.
#
# .index files summarize what the compiler learned while
# compiling one .lib file. They are purely for
# human consumption.
#
# .module_dependencies_summary files are an internal efficiency hack
# of no interest to the application programmer;
# they cache summary information about a Mythryl
# sourcefile.
#
# .version files are internal bookkeeping devices
# of no interest to the application programmer;
# they distinguish different versions of the
# same .compiled or .frozen file.
#
make_compiledfile_name: Policy -> ad::File -> String;
make_freezefile_name: Policy -> ad::File -> String;
make_indexfile_name: Policy -> ad::File -> String;
make_versionfile_name: Policy -> ad::File -> String;
#
make_module_dependencies_summaryfile_name: Policy -> ad::File -> String;
os_kind_to_string: platform_properties::os::Kind -> String;
};
end;