// DIE's signature file

init("library","Qt");

includeScript("Qt");

function detect(bShowType,bShowVersion,bShowOptions)
{
    if(aQt)
    {
        sVersion=PE.getPEFileVersion(PE.getFileDirectory()+"/"+aQt[0]);
        if(sVersion=="")
        {
            sVersion=(aQt[3]?aQt[3]:aQt[1])+".X";
        }
        if(aQt[2])
        {
            sOptions="debug";
        }
        bDetected=1;
    }

    if(!aQt&&PE.section[".rdata"])
    {
        var nVersionOffset=PE.findString(PE.section[".rdata"].FileOffset,PE.section[".rdata"].FileSize,"QWidget");
        if(nVersionOffset!=-1)
        {
            sVersion="x.xx";
            sOptions="static linked";
            bDetected=1;
        }
    }

    return result(bShowType,bShowVersion,bShowOptions);
}
