set mkdir;
set time-adjust-back;

if [not [defined search_path]] then search_path=;

search_list = .;
search_path = [tail [split ':' [search_path]]];
search_name = bl;
loop
{
	search_dir = [head [search_path]];
	if [not [search_dir]] then
		loopstop;
	search_path = [tail [search_path]];
	if [not [exists-symlink [search_name]]] then
	{
		ln -s [search_dir] [search_name]
			set clearstat;
	}
	else
	{
		if [not [exists [search_name]]] then
		{
			rm -f [search_name]
				set clearstat;
			ln -s [search_dir] [search_name]
				set clearstat;
		}
	}
	search_list = [search_list] [search_name];
	search_name = [search_name]bl;
}

if [match_mask %1C%2 [version]] then
{
	development = 1;
	integration = 0;
}
else
{
	development = 0;
	integration = 1;
}

version_short = [fromto %1.C%2 %1 [subst D C [version]]];
project_short = [fromto %.[version_short] % [project]];
all =;

#include-cooked-nowarn etc/Howto.conf
#include-cooked [resolve etc/sourcelist.cook]

if [not [defined all]] then all=;

all: [all];
{
}

etc/Howto.conf : etc/Howto.conf.in config.status
{
	CONFIG_FILES\=[target]\:[resolve etc/Howto.conf.in] CONFIG_HEADERS\=
		[pathname [resolve config.status]];
	rm -f config.log;
}

#include-cooked [resolve etc/configure.cook]
#include-cooked [resolve etc/archive.cook]
#include-cooked [resolve etc/functions.cook]
#include-cooked [resolve etc/build.cook]
#include-cooked [resolve etc/i18n.cook]
#include-cooked [resolve etc/makefile.cook]

