Output exe filename from a delphi build?

How can i find out the resulting application exe filename + path when doing a delphi build ? I know delphi has properties like DCC_DependencyCheckOutputName or if that's not avalible that you can use outputdir + rootfilename(dprfile) + '.exe' or something along those lines. I just kinda wondered how one should be getting this on a normal way in finalbuilder ?

The reason i ask is because i do a loop (iteration) build and in each iteration i also execute signtool.exe to sign our newly builded exectuables, it should only be done on .dll and .exe files but i can't seem to find a good way to figure out the resulting exe or dll filename when doing a delphi build.

Any idea's ?

thanks

Hi

There are two ways I can think of :

1) Check the file extension of the delphi project file, if it's dpr then it's an exe or a dll, if it's dpk then it's a package. Determining if it's a dll or exe would require reading the first line of the project file to see if it's a program or a library. 

2)  read the dproj file DCC_DependencyCheckOutputName. I have attached an example on how to do this. 

Hi thanks for the example and for giving the idea of looking at the dpr file i hadn’t thought of that being an option (it would just require checking if it’s a program or library) but i think i’ll use the dependency one, we used it before but i just wasn’t sure on how to easily get this in final builder. Thanks again