compiler failed on write

Linux specific forum
MVXA
User
User
Posts: 18
Joined: Tue Feb 22, 2005 11:09 pm
Contact:

compiler failed on write

Post by MVXA »

Hi,
yesterday i installed pb fpr linux on a root server and all worked pretty
fine. Now I tried to compile a testfile now and the compiler halts on this
message:

Code: Select all

******************************************
PureBasic 3.94 (Linux - x86)
******************************************

Loading external modules...
Starting compilation...
7 lines processed.
Creating the executable.
Error: Assembler
error: write failed.
I had already changed chmod to 777 and it doesn't help.
Someone got an idea?
Beach
Enthusiast
Enthusiast
Posts: 677
Joined: Mon Feb 02, 2004 3:16 am
Location: Beyond the sun...

Post by Beach »

You need to make sure you have the ability to create a file in the directory you are trying to compile your code. You can test this by creating an empty file by issuing "touch testfile.txt".

Also, can you compile the code if you are the root user?
-Beach
MVXA
User
User
Posts: 18
Joined: Tue Feb 22, 2005 11:09 pm
Contact:

Post by MVXA »

> touch testfile.txt
succeed.

> Also, can you compile the code if you are the root user?
i said on a root server, not on my root server :lol:. I'm not
the owner of the root. So I don't own the root account
Fred
Administrator
Administrator
Posts: 18162
Joined: Fri May 17, 2002 4:39 pm
Location: France
Contact:

Post by Fred »

can you write to /tmp ?
MVXA
User
User
Posts: 18
Joined: Tue Feb 22, 2005 11:09 pm
Contact:

Post by MVXA »

> can you write to /tmp ?
Yes, I'm able to write into the /tmp directory

I don't know why it works now (maybe because i uploaded PB for Linux
again) but the compiler still not works:

Code: Select all

******************************************
PureBasic 3.94 (Linux - x86)
******************************************

Loading external modules...
Starting compilation...
7 lines processed.
Creating the executable.
purebasic.o(.text+0x27): In function `main':
: undefined reference to `PB_PrintN'
purebasic.o(.text+0x34): In function `main':
: undefined reference to `PB_PrintN'
purebasic.o(.text+0x41): In function `main':
: undefined reference to `PB_PrintN'
purebasic.o(.text+0x4e): In function `main':
: undefined reference to `PB_PrintN'
purebasic.o(.text+0x7f): In function `main':
: undefined reference to `PB_PeekS'
purebasic.o(.text+0x95): In function `main':
: undefined reference to `PB_PrintN'
purebasic.o(.text+0xa8): In function `main':
: undefined reference to `PB_PrintN'
purebasic.o(.text+0xb5): In function `main':
: undefined reference to `PB_PrintN'
collect2: ld returned 1 exit status
Error: Linker
strange :?

here my test code (from Darkdragon):

Code: Select all

printn("CONTENT-TYPE: text/html"+chr(10)+chr(10))
printn("<!DOCTYPE HTML PUBLIC "+chr(34)+"-//W3C//DTD HTML 4.0//EN"+chr(34)+" "+chr(34)+"http://www.w3.org/TR/REC-html40/strict.dtd"+chr(34)+">"+chr(10))
printn("<html lang="+chr(34)+"en"+chr(34)+" dir="+chr(34)+"LTR"+chr(34)+">"+chr(10))
printn("<body>"+chr(10))
printn("Your IP: "+PeekS(getenv_("REMOTE_ADDR"))+chr(10))
printn("</body>"+chr(10))
printn("</html>"+chr(10)+chr(10))
MVXA
User
User
Posts: 18
Joined: Tue Feb 22, 2005 11:09 pm
Contact:

Post by MVXA »

it seems the server is blessed with a random function.
I did nothing and the Compiler gives me this output:

Code: Select all

******************************************
PureBasic 3.94 (Linux - x86)
******************************************

Loading external modules...
Starting compilation...
7 lines processed.
Creating the executable.
collect2: ld returned 1 exit status
Error: Linker
:lol:
dracflamloc
Addict
Addict
Posts: 1648
Joined: Mon Sep 20, 2004 3:52 pm
Contact:

Post by dracflamloc »

What version of the dev libs/gcc are you using?
Post Reply