Reasm from commented file fails

Everything else that doesn't fall into one of the other PB categories.
BarryG
Addict
Addict
Posts: 4269
Joined: Thu Apr 18, 2019 8:17 am

Reasm from commented file fails

Post by BarryG »

Hi guys, I'm trying to rebuild my commented ASM source with this command-line, but it fails:

Code: Select all

D:\PureBasic\Compilers\pbcompiler.exe /reasm PureBasic.asm /linenumbering /thread /xp /icon "Includes\Icon.ico" /resource "Includes\Sounds\Sounds.rc" /exe "Rebuild.exe"
POLINK: error: Unresolved external symbol '_PB_StringBasePosition'.

Image

I'm not using any third-party libraries, and obviously the exe compiles normally from the IDE, so all paths in the resource file are correct, etc.

I'm running the command-line from a batch file in the source's folder. Anyone have any idea how to resolve this? Thanks.
User avatar
chi
Addict
Addict
Posts: 1087
Joined: Sat May 05, 2007 5:31 pm
Location: Austria

Re: Reasm from commented file fails

Post by chi »

I bet you didn't use the thread switch when you created the .asm file...

Code: Select all

D:\PureBasic\Compilers\pbcompiler.exe "Source.pb" /commented /thread /exe "Purebasic.exe" 
Et cetera is my worst enemy
BarryG
Addict
Addict
Posts: 4269
Joined: Thu Apr 18, 2019 8:17 am

Re: Reasm from commented file fails

Post by BarryG »

Bingo! The docs don't say to do that, though; so it's not obvious (as evidenced by me having to post the question). I thought "/commented" would just dump the source, and that "/reasm" would enable the thread-safety for it with "/thread". Had no idea that I had to use "/thread" to make "/commented" a thread-safe source. Thanks for helping again.
Post Reply