Domanda

I have this in my .inf:

[Strings]
Driver_Name = "Our driver, build version 1112"

For some reason (better SVN hook compatibility - want to assing build number at each time I commit .sys), want this to be:

[Strings]
DrvVer = "1111";
Driver_Name = "Our driver, build version %DrvVer"

Unfortunately, this doesn't get processed, so %DrvVer% remains in place; the other idea is to use "%Driver_Name% %DrvVer%" construct outside of [Strings], but don't sure how to join this parts, too.

È stato utile?

Soluzione

im not familiar with SVN hooks but maybe some info about INF files will help you.

as far as i know %strings% are not interpreted within the String section.

If you want to concat them "%Driver_Name% %DrvVer%" is already the correct syntax, but it doesnt work within the strings section

i wonder why you are putting the version in the strings section. microsoft already implemented a special Version section for INF files. please take a look at this links:

INF Version Section

INF DriverVer

you could lay out your INF like this:

[Strings]
DrvVer = 1111
BuildDate = 01/11/2011

[Version]
DriverVer=%BuildDate%,%DrvVer%
DriverPackageDisplayName="our driver, build version %DrvVer%"

it should work and looks more standard

Autorizzato sotto: CC-BY-SA insieme a attribuzione
Non affiliato a StackOverflow
scroll top