TOP ?= "@top_srcdir@" ;
BUILDTOP ?= "@top_builddir@" ;

SubDir TOP ;

IncludeDir ;
IncludeDir src ;

IncludeDir $(BUILDTOP) : : literal transient ;

CleanDir clean :
    out ;
Clean distclean :
    aclocal.m4
    config.h
    config.h.in~
    config.log
    config.status
    config.status.lineno
    config.cache
    configure.lineno
    Jamconfig
    Jamfile ;
CleanDir distclean :
    autom4te.cache ;
Depends distclean : clean ;

Clean maintainerclean :
  config.h.in
  configure ;
Depends maintainerclean : distclean ;

Help distclean : "Remove built targets and configuration" ;
Help maintainerclean :
    "Remove built targets, configuration, and generated files." ;

ApplicationIconDefault win32 : all : bullet_ico.ico : $(TOP) msvc ;

MsvcGenSubDir TOP msvc : common ;
MsvcGenSubDir TOP msvc 6 : 6 ;
MsvcGenSubDir TOP msvc 7 : 7 ;
MsvcGenSubDir TOP msvc 71 : 71 ;
MsvcGenSubDir TOP msvc sn71 : sn71 ;
MsvcGenSubDir TOP msvc 8 : 8 ;
MsvcGenTemplateDir TOP mk msvcgen ;
MsvcGenWorkspace bullet ;

# Set project-specific compiler and linker options for msvcgen.
MsvcGenConfig GL.AVAILABLE : yes ;
MsvcGenConfig GL.LFLAGS :  ;
MsvcGenConfig GL.LIBS : opengl32.lib ;
MsvcGenConfig GLUT.AVAILABLE : yes ;
MsvcGenConfig GLUT.CFLAGS : ;
MsvcGenConfig GLUT.LFLAGS : ;
MsvcGenConfig GLUT.INCDIRS : "../../Glut" ;
MsvcGenConfig GLUT.LIBDIRS : "../../Glut" ;
MsvcGenConfig GLUT.LIBS : glut32.lib ;
MsvcGenConfig GLEW.LIBS : glew32.lib ;

SubInclude TOP src ;
SubInclude TOP Extras ;
SubInclude TOP Demos ;

Depends install_config : [ DoInstall bullet.pc : $(libdir)/pkgconfig ] ;
