Linker Error - Unknown Error

Everything else that doesn't fall into one of the other PB categories.
akj
Enthusiast
Enthusiast
Posts: 668
Joined: Mon Jun 09, 2003 10:08 pm
Location: Nottingham

Linker Error - Unknown Error

Post by akj »

After using Windows ME for years I have now decided to use Windows XP instead, but I am having a major problem with PureBasic (4.30).

Every time I try to run or compile any PB program I ALWAYS get the error dialogue box:
Linker Error
Unknown error

In fact the problem is identical to that reported here:
http://www.purebasic.fr/english/viewtopic.php?t=36081
I have compared the list of files on this post with my own and they appear identical.

But in my case there is a major difference in that I have only just installed Windows XP and have not been surfing the internet, so that the resolution in the above post of a virus does not apply. I did not even visit the internet to install PureBasic as the installation file was already downloaded on an external USB disc drive.

The situation was that initially PB was working perfectly correctly, but I accidently deleted a few of the library files. To overcome this I reinstalled PB [from the same installation file as used previously] and then the linker error message (Unknown error) started happening.
I then completely uninstalled and reinstalled PB, but to no avail.
I am very reluctant to reinstall Windows XP and start afresh, so does anyone have any ideas I could try?

The only extra clue I have is that it may be related to CRTDLL.DLL as that was mentioned in the XP Event Viewer (Applications) at about the time I first had this linker problem. But the file has not been subsequently mentioned.
Anthony Jordan
freak
PureBasic Team
PureBasic Team
Posts: 5962
Joined: Fri Apr 25, 2003 5:21 pm
Location: Germany

Post by freak »

Did you check the free disk space as Fred suggests in the linked thread ?
quidquid Latine dictum sit altum videtur
akj
Enthusiast
Enthusiast
Posts: 668
Joined: Mon Jun 09, 2003 10:08 pm
Location: Nottingham

Post by akj »

@freak,

Yes I did. The C: partition has 1.25 GB free and the H: partition on which PureBasic is installed has 1.67 GB free.


For some obscure reason the Windows Event Viewer no longer shows the records relating to CRTDLL.DLL but I took some written notes at the time and these mention:

Error C0000005 Access violation
CRTDLL ! strstr()

But this may be unrelated to my PB problem. I just don't know.


EDIT:
I've just discovered something interesting and relevant:

If I hide POLINK.EXE (by renaming it and rebooting the PC) and then try to run or compile any PB source file, I still get the same error! This tells me that despite the wording of the error message, it cannot be the linker that is causing the error. So presumably it is the compiler (or possibly the resource compiler). Perhaps the message simply means that the compiler cannot find the linker.

Is there any way of discovering the command line that the compiler is using to invoke the linker?
Anthony Jordan
freak
PureBasic Team
PureBasic Team
Posts: 5962
Joined: Fri Apr 25, 2003 5:21 pm
Location: Germany

Post by freak »

Maybe this is an access right issue. Where did you install PureBasic ? (try in a non-system location, like your user folder for a test)

Also you could try to run the pbcompiler.exe from a commandline. Sometimes the output there gives a bit more information than the IDE provides.

> Is there any way of discovering the command line that the compiler is using to invoke the linker?

Not directly. You could write a short program that displays its commandline and replace the polink.exe with it to see what is passed. For that you first need to be able to compile though :)
quidquid Latine dictum sit altum videtur
akj
Enthusiast
Enthusiast
Posts: 668
Joined: Mon Jun 09, 2003 10:08 pm
Location: Nottingham

Post by akj »

@ freak

Thank you for your brilliant analysis!
PB Programs now compile correctly when PureBasic is installed in the folder:
C:\Documents and Settings\<my_username>\PureBasic 430

However, for backup and recovery reasons, I definitely do not want PureBasic to be installed on the C: partition.

Have you any idea how I can change access rights to enable PB to be installed in my H: partition? Please bear in mind that I am very new to XP (Pro 2002 with SP2) and that I have never before played with Windows access rights and I don't even know where to begin.
Anthony Jordan
akj
Enthusiast
Enthusiast
Posts: 668
Joined: Mon Jun 09, 2003 10:08 pm
Location: Nottingham

Post by akj »

I have found a resolution to this problem which is to merely run PBCOMPILER.EXE in Windows 98/ME compatibility mode. Everything then seems to be perfectly OK.

Many thanks for your help, freak, as you pointed me in the right direction.
Anthony Jordan
Post Reply