electron/rcedit

manifest always applied to resourcename [1]

tumagonx opened this issue · 6 comments

As according to MS Manifest Tool, dll should be MAKEINTRESOURCEW(2) and only exe that use MAKEINTRESOURCEW(1)

rescle.cc :

    (ru.Get()
      , RT_MANIFEST
      , MAKEINTRESOURCEW(1)
      , 1033 // this is hardcoded at 1033, ie, en-us, as that is what RT_MANIFEST default uses
      , &stringSection.at(0), sizeof(char) * stringSection.size())) {

      return false;
    }

If editing DLLs is within the scope of rcedit, perhaps we need a --dll flag?

run rcedit

Fatal error: You should specify a exe/dll file

yes DLLs is within the scope :)
and no not --dll but https://msdn.microsoft.com/en-us/library/ms809762.aspx
in Characteristics flag 0x2000 means it's dll

I ask because the description of the repository is

Command line tool to edit resources of exe

well, a dll is 99,99% an exe too, why not? and because of that --dll (by user) will cause inaccuracy, just my two cents. It's up to the developer...

Speaking for myself, feel free to file a pull request so that it autodetects whether it's a DLL or EXE and sets the appropriate magic number.

sorry i made lame C-ish patch barely based on that msdn article
rescle-manifest-dll.txt