#538 Adding an external DLL/export symbol name does not work

open
nobody
None
5
2011-05-13
2011-05-13
No

OS: WinXO Pro
NASM Version: 2.09.08
NASM Binaries: http://www.nasm.us/pub/nasm/releasebuilds/2.09.08/
Command line: nasm -f win32 test2.nasm -o test2.obj
NASMENV: <n/a>

test2.nasm:6: error: unrecognized export qualifier `Cumba'

Discussion

  • Kasper Christensen

    Sourcecode

     
  • Kasper Christensen

    I accidentally hit the submit button. The error message should have been:
    test2.nasm:6: error: unrecognized export qualifier `MyCumbaFunction'.

     
  • Kasper Christensen

    • summary: External DLL symbol name does not work --> Adding an external DLL/export symbol name does not work
     
  • Frank Kotler

    Frank Kotler - 2011-05-13

    Okay... "export" is documented as a "format-specific" directive for "-f obj"... and you can give it a second parameter, as you've done. It does not appear to be documented at all as a "-f win32" directive. It is accepted in "-f win32" (I don't know what it does), but only with one parameter, apparently. Can you live with "Cumba"?

    Best,
    Frank

     
  • Frank Kotler

    Frank Kotler - 2011-05-13

    Looking again at your test2.nasm, the section declarations look like they're for "-f obj". Can ya live with "-f obj" instead of "-f win32"? Assembles without error in "-f obj" format...

    Best,
    Frank

     
  • Nobody/Anonymous

    win32 doesn't support anything other than

    <code>export name</code>

    So it should be obj format get used I think.

     
  • Kasper Christensen

    "Okay... "export" is documented as a "format-specific" directive for "-f obj"... and you can give it a second parameter, as you've done. It does not appear to be documented at all as a "-f win32" directive"

    -- My bad. I did a search for 'DLL' in the documentation and didn't realize the section I was reading about exporting was specific to the obj format. Unfortunately my linker (Visual Studio) apparently doesn't support this format, but I can just insert an EXPORTS-section in the .def file when I link it if I need a different name for the function.

    "win32 doesn't support anything other than <code>export name</code>"

    -- True, and as indicated by the above section this is actually also sufficient.

    Thanks for feedback!

     

Get latest updates about Open Source Projects, Conferences and News.

Sign up for the SourceForge newsletter:





No, thanks