#============================================================================
# Main rules file - Includes all important rulefiles in correct order
# Copyright (C)2003 by Matze Braun <matzebraun@users.sourceforge.net>
#
#    This library is free software; you can redistribute it and/or modify it
#    under the terms of the GNU Library General Public License as published by
#    the Free Software Foundation; either version 2 of the License, or (at your
#    option) any later version.
#
#    This library is distributed in the hope that it will be useful, but
#    WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY
#    or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU Library General Public
#    License for more details.
#
#    You should have received a copy of the GNU Library General Public License
#    along with this library; if not, write to the Free Software Foundation,
#    Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
#
#============================================================================

# Enable if you want debug messages.
JAM_DEBUG ?= 1 ;

jamrulesdir = $(TOP)/mk/jam ;

# Utility and compatibility rules used by all other scripts.
include $(jamrulesdir)/jamcompatibility.jam ;
include $(jamrulesdir)/subdir.jam ;
include $(jamrulesdir)/property.jam ;

# This needs to be included before _and_ after all other includes (except the
# super low-level utility files above) since it optionally overrides built-in
# rules to glean information about targets being defined.
include $(jamrulesdir)/dump.jam ;

include $(jamrulesdir)/options.jam ;
include $(jamrulesdir)/variant.jam ;
include $(jamrulesdir)/resource.jam ;

include $(jamrulesdir)/helper.jam ;
include $(jamrulesdir)/help.jam ;
include $(jamrulesdir)/groups.jam ;
include $(jamrulesdir)/install.jam ;
include $(jamrulesdir)/clean.jam ;

include $(jamrulesdir)/objects.jam ;
include $(jamrulesdir)/compiler.jam ;
include $(jamrulesdir)/objectivec.jam ;
include $(jamrulesdir)/assembler.jam ;
include $(jamrulesdir)/bisonflex.jam ;
include $(jamrulesdir)/swig.jam ;
include $(jamrulesdir)/pythmod.jam ;
include $(jamrulesdir)/strip.jam ;

include $(jamrulesdir)/flags.jam ;
include $(jamrulesdir)/library.jam ;
include $(jamrulesdir)/static.jam ;
include $(jamrulesdir)/application.jam ;
include $(jamrulesdir)/plugin.jam ;
include $(jamrulesdir)/docs.jam ;
include $(jamrulesdir)/unittest.jam ;

# Include OS specific rules
switch $(TARGET.OS)
{
case WIN32 :
  include $(jamrulesdir)/win32.jam ;
case MACOS_X :
  include $(jamrulesdir)/macosx.jam ;
case UNIX :
  include $(jamrulesdir)/unix.jam ;
case * :
  echo "WARNING: TARGET.OS not defined. Using unix" ;
  include $(jamrulesdir)/unix.jam ;
}

# This needs to be included after all others because it overrides some of the
# earlier defined rules when enabled. It even overrides Win32 rules, so it
# needs to be after platform-specific includes, as well.
include $(jamrulesdir)/msvcgen.jam ;

# This needs to included be before _and_ after all other includes since it
# optionally overrides rules defined earlier.
include $(jamrulesdir)/dump.jam ;
