Change the order of tests in sub GetXsltDir, so that it tests relative to the root directory before using the current dir (which will always exist)
Improved debug output when unable to open some of the files.
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE SystemDefinition [
<!ELEMENT SystemDefinition (systemModel?,SystemBuild?)>
<!ATTLIST SystemDefinition
name CDATA #REQUIRED
schema CDATA #REQUIRED>
<!ELEMENT systemModel (layer+)>
<!ELEMENT layer (block*|collection*)*>
<!ATTLIST layer
name CDATA #REQUIRED
long-name CDATA #IMPLIED
levels NMTOKENS #IMPLIED
span CDATA #IMPLIED>
<!ELEMENT block (subblock*|collection*)*>
<!ATTLIST block
levels NMTOKENS #IMPLIED
span CDATA #IMPLIED
level NMTOKEN #IMPLIED
name CDATA #REQUIRED
long-name CDATA #IMPLIED>
<!ELEMENT subblock (collection)*>
<!ATTLIST subblock
name CDATA #REQUIRED
long-name CDATA #IMPLIED>
<!ELEMENT collection (component)*>
<!ATTLIST collection
name CDATA #REQUIRED
long-name CDATA #IMPLIED
level NMTOKEN #IMPLIED>
<!ELEMENT component (unit)*>
<!ATTLIST component
name CDATA #REQUIRED
long-name CDATA #IMPLIED
deprecated CDATA #IMPLIED
introduced CDATA #IMPLIED
contract CDATA #IMPLIED
plugin (Y|N) 'N'
filter CDATA #IMPLIED
class NMTOKENS #IMPLIED
supports CDATA #IMPLIED
purpose (optional|mandatory|development) 'optional'>
<!ELEMENT unit EMPTY>
<!ATTLIST unit
mrp CDATA #IMPLIED
filter CDATA #IMPLIED
bldFile CDATA #IMPLIED
root CDATA #IMPLIED
version NMTOKEN #IMPLIED
prebuilt NMTOKEN #IMPLIED
late (Y|N) #IMPLIED
priority CDATA #IMPLIED>
<!ELEMENT SystemBuild (option*|target+|targetList+|list+|configuration+)*>
<!ATTLIST SystemBuild schema CDATA #REQUIRED>
<!ELEMENT list (ref+)>
<!ATTLIST list
name ID #REQUIRED
description CDATA #REQUIRED>
<!ELEMENT ref EMPTY>
<!ATTLIST ref item CDATA #REQUIRED>
<!ELEMENT targetList EMPTY>
<!ATTLIST targetList
name ID #REQUIRED
description CDATA #REQUIRED
target IDREFS #REQUIRED>
<!ELEMENT target EMPTY>
<!ATTLIST target
name ID #REQUIRED
abldTarget CDATA #REQUIRED
description CDATA #REQUIRED>
<!ELEMENT option EMPTY>
<!ATTLIST option
name ID #REQUIRED
abldOption CDATA #REQUIRED
description CDATA #REQUIRED
enable (Y|N) #REQUIRED>
<!ELEMENT configuration (listRef+|ref+|task+)*>
<!ATTLIST configuration
name ID #REQUIRED
description CDATA #REQUIRED
filter CDATA #REQUIRED>
<!ELEMENT task (listRef*,(buildLayer|specialInstructions))>
<!ELEMENT listRef EMPTY>
<!ATTLIST listRef list CDATA #REQUIRED>
<!ELEMENT buildLayer EMPTY>
<!ATTLIST buildLayer
command CDATA #REQUIRED
targetList IDREFS #IMPLIED
unitParallel (Y|N) #REQUIRED
targetParallel (Y|N) 'N'>
<!ELEMENT specialInstructions EMPTY>
<!ATTLIST specialInstructions
name CDATA #REQUIRED
cwd CDATA #REQUIRED
root CDATA #IMPLIED
command CDATA #REQUIRED>
]>
<SystemDefinition schema="2.0.1" name="Symbian^3">
<systemModel>
<layer name="os" long-name="OS" levels="hw services">
<block name="graphics" level="services" long-name="Graphics" levels="adaptation engines internal-adaptations device-interface internal-utils app-if">
<collection name="graphicsresourceservices" long-name="Graphics Resource Services" level="engines">
<component name="graphicsresource" long-name="Graphics Resource" introduced="tb92" purpose="optional">
<unit bldFile="/sf/os/graphics/graphicsresourceservices/graphicsresource/group" mrp="/sf/os/graphics/graphicsresourceservices/graphicsresource/group/graphics_graphicsresource.mrp"/>
</component>
<component name="graphicsresourceadaptation" long-name="Graphics Resource Adaptation" introduced="tb92" purpose="optional">
<unit bldFile="/sf/os/graphics/graphicsresourceservices/graphicsresourceadaptation/group" mrp="/sf/os/graphics/graphicsresourceservices/graphicsresourceadaptation/group/graphics_graphicsresourceadapter.mrp"/>
</component>
</collection>
<collection name="graphicsutils" long-name="Graphics Utils" level="engines">
<component name="commongraphicsheaders" long-name="Common Graphics Headers" introduced="tb92" purpose="mandatory">
<unit bldFile="/sf/os/graphics/graphicsutils/commongraphicsheaders/group" mrp="/sf/os/graphics/graphicsutils/commongraphicsheaders/group/graphics_commonheader.mrp"/>
</component>
</collection>
<collection name="graphicshwdrivers" long-name="Graphics Hardware Drivers" level="adaptation">
<component name="displayldd" long-name="Display Drivers" introduced="tb92" purpose="optional">
<unit bldFile="/sf/os/kernelhwsrv/kernel/eka/drivers/display" mrp="/sf/os/kernelhwsrv/kernel/eka/drivers/display/base_e32_drivers_display.mrp"/>
</component>
<component name="surfacemgr" long-name="Surface Manager" introduced="tb92" purpose="optional">
<unit bldFile="/sf/os/graphics/graphicshwdrivers/surfacemgr/group" mrp="/sf/os/graphics/graphicshwdrivers/surfacemgr/group/graphics_surfacemanager.mrp"/>
</component>
</collection>
<collection name="graphicstest" long-name="Graphics Test" level="app-if">
<component name="graphicstestharness" long-name="Graphics Test Harness" introduced="8.1" purpose="development">
<unit mrp="/sf/os/graphics/graphicstest/graphicstestharness/group/graphics_testharness.mrp"/>
</component>
<component name="uibench" long-name="UI Bench" introduced="9.2" purpose="development">
<unit bldFile="/sf/os/graphics/graphicstest/uibench/group" mrp="/sf/os/graphics/graphicstest/uibench/group/graphics_ui_bench.mrp"/>
</component>
</collection>
<collection name="graphics_info" long-name="Graphics Info" level="app-if">
<component name="graphicsdocs" long-name="Graphics Documentation" purpose="development" class="doc">
<unit mrp="/sf/os/graphics/graphics_info/graphicsdocs/graphics_documentation.mrp"/>
</component>
<component name="graphics_metadata" long-name="Graphics Metadata" introduced="tb91" purpose="development" class="config PC">
<unit mrp="/sf/os/graphics/graphics_info/graphics_metadata/graphics_metadata.mrp"/>
</component>
</collection>
<collection name="windowing" long-name="Windowing" level="app-if">
<component name="n:windowserver" long-name="Window Server" purpose="mandatory">
<!-- intentionally not for the foundation despite being a mandatory component -->
<unit bldFile="/sf/os/graphics/windowing/windowserver/group" mrp="/sf/os/graphics/windowing/windowserver/group/graphics_wserv.mrp"/>
</component>
</collection>
<collection name="printingservices" long-name="Printing Services" level="app-if">
<component name="printerdriversupport" long-name="Printer Driver Support" purpose="optional">
<unit bldFile="/sf/os/graphics/printingservices/printerdriversupport/group" mrp="/sf/os/graphics/printingservices/printerdriversupport/group/graphics_pdrstore.mrp"/>
</component>
<component name="printerdrivers" long-name="Printer Drivers" purpose="optional" plugin="Y">
<unit bldFile="/sf/os/graphics/printingservices/printerdrivers/group" mrp="/sf/os/graphics/printingservices/printerdrivers/group/graphics_printdrv.mrp"/>
</component>
</collection>
<collection name="fbs" long-name="Font and Bitmap Server" level="device-interface">
<component name="fontandbitmapserver" long-name="Font and Bitmap Server" purpose="mandatory">
<unit bldFile="/sf/os/graphics/fbs/fontandbitmapserver/group" mrp="/sf/os/graphics/fbs/fontandbitmapserver/group/graphics_fbserv.mrp"/>
</component>
</collection>
<collection name="opengles" long-name="OpenGLES" level="internal-adaptations">
<component name="openglesinterface" long-name="OpenGL ES Interface" introduced="8.0" purpose="optional">
<unit bldFile="/sf/os/graphics/opengles/openglesinterface/group" mrp="/sf/os/graphics/opengles/openglesinterface/group/graphics_openglesheaders.mrp"/>
</component>
</collection>
<collection name="openvg" long-name="OpenVG" level="internal-adaptations">
<component name="openvginterface" long-name="OpenVG Interface" introduced="tb91" purpose="optional">
<unit bldFile="/sf/os/graphics/openvg/openvginterface/group" mrp="/sf/os/graphics/openvg/openvginterface/group/graphics_openvgheaders.mrp"/>
</component>
</collection>
<collection name="egl" long-name="EGL" level="internal-adaptations">
<component name="eglinterface" long-name="EGL Interface" introduced="tb91" purpose="optional">
<unit bldFile="/sf/os/graphics/egl/eglinterface/group" mrp="/sf/os/graphics/egl/eglinterface/group/graphics_eglheaders.mrp"/>
</component>
</collection>
<collection name="graphicsdeviceinterface" long-name="Graphics Device Interface" level="device-interface">
<component name="gdi" long-name="GDI" purpose="mandatory">
<unit bldFile="/sf/os/graphics/graphicsdeviceinterface/gdi/group" mrp="/sf/os/graphics/graphicsdeviceinterface/gdi/group/graphics_gdi.mrp"/>
</component>
<component name="bitgdi" long-name="BitGDI" purpose="mandatory">
<unit bldFile="/sf/os/graphics/graphicsdeviceinterface/bitgdi/group" mrp="/sf/os/graphics/graphicsdeviceinterface/bitgdi/group/graphics_bitgdi.mrp"/>
</component>
<component name="colourpalette" long-name="Colour Palette" introduced="7.0s" purpose="optional">
<unit bldFile="/sf/os/graphics/graphicsdeviceinterface/colourpalette/group" mrp="/sf/os/graphics/graphicsdeviceinterface/colourpalette/group/graphics_palette.mrp"/>
</component>
<component name="screendriver" long-name="Screen Driver" introduced="6.1" purpose="optional" plugin="Y">
<unit bldFile="/sf/os/graphics/graphicsdeviceinterface/screendriver/group" mrp="/sf/os/graphics/graphicsdeviceinterface/screendriver/group/graphics_screendriver.mrp"/>
</component>
<component name="directgdi" long-name="DirectGDI" introduced="tb92" purpose="optional">
<unit bldFile="/sf/os/graphics/graphicsdeviceinterface/directgdi/group" mrp="/sf/os/graphics/graphicsdeviceinterface/directgdi/group/graphics_directgdi.mrp"/>
</component>
<component name="directgdiinterface" long-name="DirectGDI Interface" introduced="tb92" purpose="optional">
<unit bldFile="/sf/os/graphics/graphicsdeviceinterface/directgdiinterface/group" mrp="/sf/os/graphics/graphicsdeviceinterface/directgdiinterface/group/graphics_directgdiheaders.mrp"/>
</component>
<component name="directgdiadaptation" long-name="DirectGDI Adaptation" introduced="tb92" purpose="optional">
<unit bldFile="/sf/os/graphics/graphicsdeviceinterface/directgdiadaptation/group" mrp="/sf/os/graphics/graphicsdeviceinterface/directgdiadaptation/group/graphics_directgdiadapter.mrp"/>
</component>
</collection>
<collection name="graphicstools" long-name="Graphics Tools" level="internal-utils">
<component name="gdi_tools" long-name="GDI Tools" purpose="development" class="PC">
<unit bldFile="/sf/os/graphics/graphicstools/gdi_tools/group" mrp="/sf/os/graphics/graphicstools/gdi_tools/group/graphics_gditools.mrp"/>
</component>
</collection>
<collection name="graphicsapitest" long-name="Graphics API Tests" level="app-if">
<component name="graphicssvs" long-name="Graphics Verification Suite" introduced="tb91" purpose="development">
<unit mrp="/sf/os/graphics/graphicsapitest/graphicssvs/group/graphicssvs.mrp"/>
</component>
<component name="screendriverhaitest" long-name="Screen Driver HAI Tests" introduced="tb91" purpose="development">
<unit mrp="/sf/os/graphics/graphicsapitest/screendriverhaitest/group/screendriverhaitest.mrp"/>
</component>
</collection>
<collection name="s60">
<component name="graphics">
<unit bldFile="/sf/os/graphics/group" mrp=""/>
</component>
<component name="graphics_plat">
<unit bldFile="/sf/os/graphics/group/../graphics_plat/group" mrp=""/>
</component>
<component name="graphics_m3g_api">
<unit bldFile="/sf/os/graphics/group/../graphics_plat/m3g_core_api/group" mrp=""/>
</component>
<component name="graphics_m3g">
<unit bldFile="/sf/os/graphics/group/../m3g/m3gcore11/group" mrp=""/>
</component>
<component name="graphics_acceleration_vgi">
<unit bldFile="/sf/os/graphics/group/../graphicsaccelaration/vgi/group" mrp=""/>
</component>
<component name="sf_openvg11">
<unit bldFile="/sf/os/graphics/openvg/openvginterface/group/openvg11" mrp=""/>
</component>
</collection>
</block>
</layer>
</systemModel>
</SystemDefinition>