OMake Change Log
Jump to version
0.9.8.4,
0.9.8.3,
0.9.8.1,
0.9.8,
0.9.6.9,
0.9.6.8,
0.9.6.7,
0.9.6.6,
0.9.6.5,
0.9.6,
0.9.4,
0.9.3,
0.9.2.
See also the
brief summary change log.
- Fixed a file descriptor leak
- Fixed: $(OCAMLDEPFLAGS) should be passed to "ocamldep -modules"
- Other minor bug fixes
- The 3-place rules are now considered implicit and will be inherited by
subdirectories. This makes it easier to declare default rules for common
targets, such as
clean: %:
rm -f ...
- Allow .PHONY sections to have a body. A .PHONY
declaration with a body would create a default (implicit) rule for the newly
created phony target(s).
- Detect case-insensitive filesystems on Unix-like operating systems
(especially common under Mac OS X). This should make it possible to use
OCAMLDEP_MODULES_ENABLED=true under Unix-like operating systems
with case-insensitive filesystems.
- Changed the default value for the OCAMLDEP_MODULES_ENABLED to
$(OCAMLDEP_MODULES_AVAILABLE). In other words, ocamldep
-modules will be used whenever it is available (e.g. under OCaml 3.10
or if the bytecode executable distributed with OMake can be used).
- A number of performance improvements. In particular, the size of the
.omakedb should now be significantly smaller.
- Documentation improvements
OMake 0.9.8.2
The version number 0.9.8.2 was skipped.
- Additional “autoconfiguration” functionality:
- New functions in configure/Configure.om, including
ConfMsgChecking, ConfMsgResult, ConfMsgYesNo,
ConfMsgWarn, ConfMsgError, ConfMsgFound,
TryCompileC, TryLinkC, TryRunC,
RunCProg.
- Added configure/X.om with some basic tests for X
(experimental, not very well tested).
- A number of new built-in and standard library functions: join,
min, max, Map.keys, Map.values,
getpwnam, getpwuid, getpwents, getgrnam,
getgrgid, tgetstr, xterm-escape, prompt-invisible
- Improvements in -p/-P (“poll”) mode:
- Various errors in OMakefiles will now cause OMake to poll for
OMakefile changes after reporting the error, instead of aborting.
- Will watch “:optional:” and
“:exists:” dependencies (but will still ignore
“Delete” events for them).
- In implicit rules, allow the source files to contain more than one
instance of the % “wildcard” character.
- Significant improvements in the command line completion in the
interactive osh shell.
- build/C.om:
- Added StaticCXXLibrary function;
- Use /Fo and /Fe flags in place of -o on
Windows.
- build/LaTeX.om: added some support for MikTeX.
- A number of documentation improvements.
- A number of other improvements and bugfixes.
- The main change in this release is that the OMake values will now be
converted into the shell command lines directly (all the previous versions
of OMake should first "flatten" the value into a string and then perform
sh-like parsing of the resulting string). In particular, this means
that:
- All the special symbols in files and directory values will be
preserved.
- All the spaces inside the array elements will be preserved.
- All the special symbols in OMake-quoted values
($"..." and $'...') will be preserved.
- If the first element of the command line is a file value, neither
PATH- nor alias-expansion will be performed. Note - there will also be no
alias-expansion if the executable value contains quoted parts or starts
with a \.
- The Shell. aliases will now receive the values passed on the
shell command line as is, not the string-expanded version. Also, if some
of the arguments are the result of a glob-expansion, the alias function
will receive the appropriate file values, not the strings.
- OMake 0.9.8 will not be fully backwards-compatible with the earlier
releases.
- Major redesign of the OMake documentation (using HEVEA).
- The documentation is significantly expanded, examples added, bugs
fixed.
- There are now a number of indices, including a index of variables, an
index of functions, and an overall index.
- OCaml.om improvements:
- Implemented a new approach to computing the dependencies in OCaml
projects in OMake. In this approach a special version of ocamldep
is used to only extract the list of the external modules a file depends on
and then OMake is used to map those modules to files in the include path.
This eliminates the "standard" deficiency of having to generate all the
relevant OCaml source files before ocamldep is called. This
feature is considered highly experimental and is disabled by default. Use
the OCAMLDEP_MODULES_ENABLED variable to enable.
- Added support for the Menhir parser-generator (experimental).
- C.om improvements:
- Changed the CProgram function to consider LIBS to be the actual
library files (_without_ the extension) that need to be linked in.
- Improved the C scanner rule on Windows.
- LaTeX.om improvements:
- BSTINPUTS environment variable joins TEXINPUTS and
BIBINPUTS in the list of variables initialized from the OMake's
TEXINPUTS variable.
- The list of such variables is now configurable (TEXVARS variable
contains an array of names).
- More control over the OMake output and verbosity.
- By default, OMake is now much more silent ("-S
--progress" is enabled by default when it outputs to a terminal,
and "-S" is enabled in all other cases).
- Added a
--verbose option that would make OMake very verbose, when needed.
- Added an ability to postpone and/or repeat the rule execution output (so that, for example,
only the output of the rules that fail is printed, or the output of the
rules that failed is repeated at the end of the omake -k
execution). This feature is somewhat experimental and might change in the
future versions of OMake.
- Added the -o option for better control of OMake verbosity.
- Added three special .PHONY targets: .BUILD_BEGIN,
.BUILD_SUCCESS, and .BUILD_FAILURE.
.BUILD_BEGIN is built before anything else in your project. One
of .BUILD_SUCCESS or .BUILD_FAILURE is built when the
build for your project terminates.
Note:
- This feature is experimental and is likely to change in the
future versions of OMake.
- If you want to use these targets, you should probably add them to
your ~/.omakerc, rather than adding them directly to each of
the projects you work on.
- OMake will now save the .omakedb periodically, preventing the
state loss in case the OMake process dies unexpectedly (for example, when Cygwin
kills OMake after user presses Ctrl-C). The checkpointing interval may be
configured both at compile time and via the command line.
- The variables such as $< and $@ in rules and
% in implicit rules will no longer be expanded to strings; instead
they will be passed as Node ("file") values.
- Much better handling of the exit function, a number of bugs fixed.
- Implicit rules can no longer have target patterns referring to another
directories. See bug #456 for
detail.
- New functions: Shell.ln-or-cp, html-escaped,
string-escaped, encode-uri, decode-uri,
random, find-targets-in-path.
- Added an ability to turn a string into an input channel. This allows,
for example, to use an OMake variable as an input to built-in awk without having to
write it to a temporary file first.
- New flags added to built-in awk and grep.
- A large number of other bug fixes and improvements.
- Standard library improvements:
- Implemented Erick Tryzelaar's idea of having *Program and
*Library functions return the array with all the targets that it
have defined the rules for.
- Improved C++ support:
- Use g++ (when present) instead of gcc as
CXX.
- Allow .cc and .c++ extensions in addition to
.cpp
- Added CXXProgram and CXXProgramInstall functions.
- Improved OCaml support:
- Changed USE_OCAMLFIND to be always false by default.
- Added OCAMLC_EXISTS variable.
- Pervasives.om: use the built-in cat by default.
- Added a PID built-in variable.
- Bug fixes and improvements:
- Fixed problems with :value: dependencies in .INCLUDE
rules and :squash: dependencies in implicit rules.
- Added auto-rehashing on relative names in the PATH. In
addition, you can define AUTO_REHASH = true if
you want to auto-rehash on all directories in the path.
- Comments in OMakefiles are now parsed more consistently.
- Significantly improved the performance of the built-in find
command.
- Updated the default (sample) OMakefile.
- A number of documentation fixes and improvements.
- Improved the handling of the ".PHONY" nodes, fixing a few bugs where a
".PHONY" node was used in place of a file with the same name.
- Fixed a bug with PATH-expansion for pipelines being performed too early.
- Added a remove-project-directories function, which will prevent
the directories from being included even if there is a .SUBDIRS
command for any of them.
- OCaml.om: fixed the installation of .mli, .cmi files
(which is performed by the OCamlLibraryCopy function when
INSTALL_INTERFACES is enabled).
- A number of documentation fixes and other improvements.
- Added basic support for C++ (Issue 389)
- Portability improvements:
- More portable bootstrapping Makefile
- When lockf is not supported and we fail to lock the project because
of that, print a warning message and keep going (this is fairly safe). We
used to go into an infinite loop before.
- OCaml.om improvements:
- Added an OCAMLOPT_FOUND variable that can be used to tell whether
OCAMLOPT exists.
- Now by default, NATIVE_ENABLED and BYTE_ENABLED
variables will be set to enable the "best available" compilation mode:
- When OCAMLOPT is fould, the defaults are
NATIVE_ENABLED=true
BYTE_ENABLED=false
as before.
- Otherwise, the values are swapped.
- Allow the usage of OCamlLibraryInstall and
OCamlLibraryCopy when the destination directory is the same as
the source one.
- Fixed a (somewhat recently introduced) problem with OMake failing to
properly restart when the "-p"/"-P" filesystem watch is
used and OMake detects that one of the relevant OMake file have changed.
- Couple of "-w" option improvements.
- A number of minor documentation fixes.
- Made sure OMake compiles fine with both OCaml 3.08 and 3.09.
- A few minor bugfixes and improvements:
- Avoid giving bogus "These file are targeted separately, but appear
as effects of a single rule." warnings (thanks to Florian Hars for
reporting the problem).
- LaTeX rules: do not assume that .aux will always be created (based on
a patch by Cristian Tapus).
- Fixed ocamlfind support (based on a patch by Peter Jolly).
- Improved support for configure-style scripts in OMake (using the
run-once static. sections). OMake installation now includes a small
library of useful helpful configure functions and a number of examples
(ncurses, readline, fam).
- LaTeX rules improvements, including support for TeTeX v.3 and better
pdflatex support.
- The which function should now work correctly in Cygwin. Fixed
a number of issues related to using ocamlfind under Cygwin and
Windows.
- Fixed a number of bugs related to execution of complex shell
pipelines.
- New built-in functions: get-registry (Windows-only),
removeprefix, html-string.
- Fixed a problem with interactive osh sessions not handling the
return operator correctly.
- Improved handling of implicit :value: dependencies (implicit
value dependencies are added for all the “free”variables in
section eval). The free variable computation is more precise, and
the implicit dependencies are now allowed to contain undefined variables.
- The include foo directive will now try opening foo.om
before trying to open foo. Same is true for the .INCLUDE
rules.
- A number of documentation fixes.
- Significant changes in the setup for compiling OMake. No more autoconf,
bootstapping uses make to build a feature-limited bootstrapping binary and
the normal version of OMake is compiled using OMake itself. Makefiles are
now generated by OMake.
- Significant reorganization of the source three. Now the source three
has a reasonable directory structure, instead of a single flat directory
with all the files.
- A number of other improvements and bug fixes.
- Added "static" sections that are evaluated once. Values defined
in static sections are persistent across runs of omake. This is
convenient for implementing configure-style tests in omake files.
- Added :value: dependencies.
Value dependencies are specified using the :value: option in rules.
a: b c :value: $(X)
...
This rule specifies that "a" should be recompiled if the value of
$(X) changes (X does not have to be a filename). This is intended
to allow greater control over dependencies.
In addition, it can be used in place of other kinds of dependencies.
For example, the following rule:
a: b :exists: c
commands
is the same as
a: b :value: $(target-exists c)
commands
Notes:
- The values are arbitrary (they are not limited to variables)
- The values are evaluated at rule expansion time, so variables
like $@, $^, etc are legal.
One other significant difference is that the rule cache now uses a
digest of the rule commands text, not the text itself. This has an
impact on initial omake speed (I am not sure how significant it is)
but the cache is smaller. Also, "section eval" should now be
handled correctly.
- Significantly changed the meaning of the .SCANNER rules. Now the
.SCANNER rules are treated much more like normal rules.
Externally, a .SCANNER rule has the usual rule form:
.SCANNER: target: dependencies...
...scanner commands...
However, the scanner target is now decoupled from the
build target, allowing a scanner result to be used for multiple
build targets. For example, ocamldep produces dependencies
for .cmo and .cmx files simultaneously. They can share
the scanner rule by specifying an explicit :scanner: dependency.
.SCANNER: scan-ocaml-%.ml: %.ml
ocamldep $lt;
%.cmo: %.ml :scanner: scan-ocaml-%.ml
$(OCAMLC) ...
%.cmx %.o: %.ml :scanner: scan-ocaml-%.ml
$(OCAMLOPT) ...
The current convention is that scanner targets should be named
scan-<language>-<source-file>.
- Added file locking for the .omakedb and .omc files, so that multiple processes
can be run simultaneously.
- Fixed issues where files were being expanded during the string to array
conversion.
- Better accessibility of the build rules and dependencies from OMake scripts.
See documentation for the Target
object and the "Examining
the dependency graph" Section of the OMake Documentation for
more information.
- Improved the latex-related rules.
- Rule execution now fails when any shell command fails, even those in
nested sections.
- Regular expressions now handle \(...\) arguments correctly. Also, the
lexer has better performance, searching is now roughly linear time.
- Added .SUBDIRS bodies. If you don't want to write an
OMakefile for each subdirectory, you can define a .SUBDIRS
body that defines the it instead.
.SUBDIRS: foo boo
println(Current directory is $(CWD))
...normal configuration...
- Added the vmount function to define a "virtual mount" of one directory
over another. This adds a fairly simple way to define multiple versions
of a project. Suppose your source files are in a directory src/. Then
one easy way to compile a version of the project is the following.
vmount(-l, src, x86)
.SUBDIRS: x86
Files from the src directory are now automatically linked into the
x86 directory as needed. If you want to have multiple versions,
you can use multiple directories (and multiple vmounts).
- The Map object is now completely changed.
The keys are now "simple" values, not just strings. Simple
values include integers, floats, strings, arrays of simple
values, files, and directories.
Only the Map class has the map functions defined. If you want
to have, say, a File that also includes a Map, create a
subclass that extends both File and Map.
Literal string keys can be written in the form $|key...|.
This works both for definitions and uses. The usual modifiers
are allowed $,|key| and $`|key|.
X. =
extends $(Map)
$|key 1| = 1
$|key 2| = $|key 1| boo
$|key 2| += foo
- Bugs fixed: 158,
299, 315, 335, 338, 359, 376, 377, 379, 387, 393, 394, 397, 402, 403, 423,
425, 427, 428, 431, 441, 443, 445, 446, 447, 449, 452, 453, 454, 459, 462,
463, 464, 465, 466, 470, 471, 472, 473, 476, 477, 478, 480, 481, 482, 483,
487, 488, 489, 493
- Numerous other improvements.
OMake 0.9.5
The version number 0.9.5 was skipped.
- Portability improvements. OMake should now compile and work under Windows
2000, Windows NT and FreeBSD. A number of Windows-specific bugs are fixed.
A Windows installer is added.
- OMake now uses the built-in versions of the following commands:
cp, mv, mkdir, rm, rmdir,
chmod
- Improvements to the filesystem watch functionality. In particular,
the build will now restart if a change to one of the OMakefiles is
detected.
- Added a USE_OCAMLFIND variable that can be used to force or prohibit the
usage of ocamlfind in a project (by default USE_OCAMLFIND is set to true
iff the ocamlfind executable is found in path).
- Added a --force-dotomake option to create all .omc
and .omo files under $HOME/.omake/cache and a
--dotomake option to specify an alternative to
$HOME/.omake
- Added :squash: dependencies (that specify that the dependency must be
built, but when the dependency changes, it does not cause the target to be
rebuilt).
- OMake will now read ~/.omakeinit and ~/.omakerc files on startup.
- Improved the latex-related rules.
- Documentation improvements.
- Bugs fixed: 142, 153, 311, 313, 314, 316, 332, 333, 339, 350, 360, 361,
366, 367, 368, 374, 375.
- OMake now supports ocamlfind in its default configuration file
(thanks to Bardur Arantsson for the initial patch).
- OMake should now also work with OCaml 3.07 (in addition to 3.08).
- A large number of bug fixes, including:
- OMake should now compile correctly under Cygwin (thanks to
Peter Jolly who provided the patch),
- "double-colon" rules (that allow specifying multiple rules for
the same target) should now work correctly,
- kqueue-based file system monitoring (Mac OS X, FreeBSD) should
now work correctly
- array definitions should now work better.
- Added a work around for the command line length limitation of
lib.exe on Windows
- Filesystem monitoring functionality now provides a choice whether
to continue monitoring once the project is built successfully.
- Bugs fixed:
- "make install" will no longer create $HOME/.omake as root;
- the -custom option is now a part of
OCAML_BYTE_LINK_FLAGS and
can be easily disabled;
- omake should now allow specifying dependencies for the same file
more than once.
- The OMakeroot.src, OMakeroot.default and
OMakefile.default are now
under MIT license to allow users to freely borrow from them into their
own omake build files. (The rest of OMake is still under GPL).
- Fixed a number of typos and formatting errors in documentation.