Boris Gubenko wrote:
[...] I've asked our include file processing expert to look into this. I also asked if there is some other compiler option we can apply [...]
The trick here is to specify include directory in a Unix-style form pointing to the location of the source file. In this case, it would be: /INCLUDE="./modules" With this command line switch, the compiler is able to process a path relative to source file in '#include "../native.h"' directive. The quotas around "./modules" are necessary and cannot be omitted. Without quotas, the command line interpreted will interpret /modules as a separate command line switch instead of a value of the /INCLUDE switch. I modified build_vms.com script so that it defines cc command as having /INCLUDE switch above. I've attached modified script. It also fixes a bug in cleaning/restoring [.bootstrap_vms] directory which I overlooked in 2004 :-) With modified build_vms.com and build.jam sent in e-mail, I was able to build bootstrap jam which compiled all jam modules -- see below. I did not have to modify build.jam to specify /INCLUDE switch because, when executed from a script, the bootstrap jam "inherits" cc command defined by the script. Since I was using the 1.31.0 distribution which does not have the [.modules]order.c module, I did not get to the link phase. However, when I modified build.jam to remove order.c, I got the following error: $ MCR [.bootstrap_vms]jam0.exe -f x.jam --toolset=vmsdecc ...found 81 targets... ...updating 1 target... [COMPILE.LINK] [.bin_vms]bjam.exe %ILINK-F-OPENIN, error opening ") as input -RMS-F-SYN, file specification syntax error link /EXECUTABLE=[.bin_vms]bjam.exe /NOMAP /NODEBUG ") ...failed [COMPILE.LINK] [.bin_vms]bjam.exe... ...failed updating 1 target... $ It looks like build.jam still needs some work for VMS to eliminate ") in the link command. Boris $ @build_vms Removing previous boostrap directory... Creating boostrap directory... Building bootstrap jam... Cleaning any previous build... ...found 1 target... ...updating 1 target... ...updated 1 target... Building Boost.Jam... don't know how to make [.modules]order.c ...found 83 targets... ...updating 39 targets... ...can't find 1 target... ...can't make 2 targets... [COMPILE] [.bin_vms]command.o [COMPILE] [.bin_vms]compile.o [COMPILE] [.bin_vms]expand.o [COMPILE] [.bin_vms]glob.o [COMPILE] [.bin_vms]hash.o [COMPILE] [.bin_vms]hcache.o [COMPILE] [.bin_vms]headers.o [COMPILE] [.bin_vms]hdrmacro.o [COMPILE] [.bin_vms]jam.o [COMPILE] [.bin_vms]jambase.o [COMPILE] [.bin_vms]jamgram.o [COMPILE] [.bin_vms]lists.o [COMPILE] [.bin_vms]make.o [COMPILE] [.bin_vms]make1.o [COMPILE] [.bin_vms]newstr.o [COMPILE] [.bin_vms]option.o [COMPILE] [.bin_vms]parse.o [COMPILE] [.bin_vms]regexp.o [COMPILE] [.bin_vms]rules.o [COMPILE] [.bin_vms]scan.o [COMPILE] [.bin_vms]search.o [COMPILE] [.bin_vms]subst.o [COMPILE] [.bin_vms]timestamp.o [COMPILE] [.bin_vms]variable.o [COMPILE] [.bin_vms]modules.o [COMPILE] [.bin_vms]strings.o [COMPILE] [.bin_vms]filesys.o [COMPILE] [.bin_vms]builtins.o [COMPILE] [.bin_vms]pwd.o [COMPILE] [.bin_vms]class.o [COMPILE] [.bin_vms]native.o [COMPILE] [.bin_vms]modules_set.o [COMPILE] [.bin_vms]modules_path.o [COMPILE] [.bin_vms]modules_regex.o [COMPILE] [.bin_vms]modules_property-set.o [COMPILE] [.bin_vms]modules_sequence.o ...skipped modules_order.o for lack of [.modules]order.c... [COMPILE] [.bin_vms]execvms.o [COMPILE] [.bin_vms]filevms.o [COMPILE] [.bin_vms]pathvms.o ...skipped bjam.exe for lack of modules_order.o... ...skipped 2 targets... ...updated 39 targets... $ build_vms.com ------------- $ ! Copyright (C) Rene Rivera, Johan Nilsson, 2002-2003. $ ! $ ! 8-APR-2004 Boris Gubenko $ ! Miscellaneous improvements. $ ! $ ! Use, modification and distribution is subject to the $ ! Boost Software License, Version 1.0. (See accompanying file $ ! LICENSE_1_0.txt or http://www.boost.org/LICENSE_1_0.txt) $ ! $ ! bootstrap build script for Jam $ ! $ callerverify = 'f$verify(0) $ set = "set" $ set symbol /verb/scope=(nolocal,noglobal) $ on warning then continue $ say := write sys$output $ ! $ IF "" .NES. F$SEARCH("[.bootstrap_vms]*.*") $ THEN $ say "Cleaning previous boostrap files..." $ SET FILE/PROTECTION=(W:RWED) [.bootstrap_vms]*.*;* $ DELETE [.bootstrap_vms]*.*;* $ ENDIF $ ! $ IF "" .NES. F$SEARCH("bootstrap_vms.dir") $ THEN $ say "Removing previous boostrap directory..." $ SET FILE/PROT=(W:RWED) []bootstrap_vms.dir;1 $ DELETE []bootstrap_vms.dir;1 $ ENDIF $ ! $ say "Creating boostrap directory..." $ CREATE/DIR [.bootstrap_vms] $ ! $ say "Building bootstrap jam..." $ ! $ CC_FLAGS = "/DEFINE=VMS/WARN=NOINFO/PREFIX=(ALL,EXCEPT=GLOB)" + - "/OBJ=[.bootstrap_vms]/INCLUDE=""""./modules""""" $ cc := "cc''CC_FLAGS'" $ cc - builtins.c, - class.c, - command.c, - compile.c, - execvms.c, - expand.c, - filesys.c, - filevms.c, - glob.c, - hash.c, - hdrmacro.c, - headers.c, - jam.c, - jambase.c, - jamgram.c, - lists.c, - make.c, - make1.c, - modules.c, - native.c, - newstr.c, - option.c, - parse.c, - pathvms.c, - pwd.c, - regexp.c, - rules.c, - scan.c, - search.c, - strings.c, - subst.c, - timestamp.c, - variable.c, - [.modules]path.c, - [.modules]property-set.c, - [.modules]regex.c, - [.modules]sequence.c, - [.modules]set.c $ ! $ libr/create [.bootstrap_vms]libjam0.olb [.bootstrap_vms]*.obj $ link/exec=[.bootstrap_vms]jam0.exe - [.bootstrap_vms]libjam0.olb/include=jam/lib $ ! $ say "Cleaning any previous build..." $ ! $ MCR [.bootstrap_vms]jam0.exe -f build.jam --toolset=vmsdecc clean $ ! $ say "Building Boost.Jam..." $ ! $ MCR [.bootstrap_vms]jam0.exe -f build.jam --toolset=vmsdecc $ ! $ unused = f$verify(callerverify) $ exit