The following environment variables control viewpathing behavior of the tools. These environment variables must be set to a non-null value to take effect.
NVPATH Enable viewpathing and should be a colon separated list of pathnames.
Enable the output of diagnostic information from programs that use viewpathing.
Disable viewpathing, even if NVPATH is set.
Disable a performance optimization where files which are opened for creation and not updating are not copied down the viewpath if they already exist.
This example requires three existing empty directories:
/test/local
/test/group
/test/global
</test>: pwd
/test
</test>: ls -Ag *
global:
total 2
-rw-rw-r-- 1 green 7 Feb 11 15:56 file1.c
group:
total 2
-rw-rw-r-- 1 green 15 Feb 11 15:58 file2.c
local:
total 2
-rw-rw-r-- 1 green 34 Feb 11 15:55 file3.c
</test>: cd local
</test/local>: setenv NVPATH "/test/local:/test/group:/test/global"
</test/local>: setenv GHS_VP_DEBUG 1
</test/local>: ax crv archive.a file1.c file2.c file3.c
ax: info: Viewpathing support is ON (FAST).
ax: info: Adding viewpath node 1: /test/local
ax: info: Adding viewpath node 2: /test/group
ax: info: Adding viewpath node 3: /test/global
a - file1.c
ax: info: Located file: /test/global/file1.c
a - file2.c
ax: info: Located file: /test/group/file2.c
a - file3.c
</test>: cd ..
</test>: ls -Ag *
global/:
total 2
-rw-rw-r-- 1 green 7 Feb 11 15:56 file1.c
group/:
total 2
-rw-rw-r-- 1 green 15 Feb 11 15:58 file2.c
local/:
total 4
-rw-rw-r-- 1 green 246 Feb 11 16:05 archive.a
-rw-rw-r-- 1 green 34 Feb 11 15:55 file3.c
</test>: cd local
</test/local>: ax tv archive.a
ax: info: Viewpathing support is ON (FAST).
ax: info: Adding viewpath node 1: /test/local
ax: info: Adding viewpath node 2: /test/group
ax: info: Adding viewpath node 3: /test/global
rw-rw-r-- 4025/28 7 Feb 11 15:56 1998 file1.c
rw-rw-r-- 4025/28 15 Feb 11 15:58 1998 file2.c
rw-rw-r-- 4025/28 34 Feb 11 15:55 1998 file3.c
</test/local>: echo "Completely new and larger file 1" > file1.c
</test/local>: ls -Ag
total 6
-rw-rw-r-- 1 green 246 Feb 11 16:05 archive.a
-rw-rw-r-- 1 green 32 Feb 11 16:09 file1.c
-rw-rw-r-- 1 green 34 Feb 11 15:55 file3.c
</test/local>: ax r archive.a file1.c
ax: info: Viewpathing support is ON (FAST).
ax: info: Adding viewpath node 1: /test/local
ax: info: Adding viewpath node 2: /test/group
ax: info: Adding viewpath node 3: /test/global
</test/local>: ax tv archive.a
ax: info: Viewpathing support is ON (FAST).
ax: info: Adding viewpath node 1: /test/local
ax: info: Adding viewpath node 2: /test/group
ax: info: Adding viewpath node 3: /test/global
rw-rw-r-- 4025/28 32 Feb 11 16:09 1998 file1.c
rw-rw-r-- 4025/28 15 Feb 11 15:58 1998 file2.c
rw-rw-r-- 4025/28 34 Feb 11 15:55 1998 file3.c