May 24, 2022, 03:30:40 AM

News:

IonicWind Snippit Manager 2.xx Released!  Install it on a memory stick and take it with you!  With or without IWBasic!


Preview Version instructions

Started by Ionic Wind Support Team, May 29, 2007, 11:32:09 PM

Previous topic - Next topic

0 Members and 1 Guest are viewing this topic.

ExMember001

May 31, 2007, 04:57:47 PM #25 Last Edit: May 31, 2007, 05:01:55 PM by KrYpT
ok thanx , its what i was thinkin too...
will need to install that linux ;)
just need an answer to one question about installing ubuntu if you dont mind...
I'm working on a Mobile computer with a recover partition...when the computer boot
the recover system give me a 2 secs bootscreen to recover my system to default
if i install ubuntu in dual boot with the default system (windows xp home edition).. will this affect the recover bootscreen?


Doc

Quoteif i install ubuntu in dual boot with the default system (windows xp home edition).. will this affect the recover bootscreen?

I'm guessing that not all systems are alike but I recently purchased a Compaq desktop that had Vista on it. Ubuntu 7.04 is now the only OS installed on it and even the recovery partition is gone, but it still shows the recovery option available at boot up.

-Doc-

ExMember001

thanks David
Ubuntu installed now in another partition
recovery option is availlable in grub :P cool!!

ExMember001

working now ;)
must be the live cd ...

ExMember001

here's a little screen of the Heapsort

ExMember001

is the FILEREQUEST command working?
because i'm having problem... ;)

Ionic Wind Support Team

Not yet.  What is working is the compiler itself, 99% of the shell (console) commands. the basic GUI system for managing windows, a few control types, the font subsystem, etc.

The dialog based commands will take a while.  The file dialog, font dialog, etc all relied on direct Win32 calls to create them.  And they will be worked on after more of the control types are finished. 

Working on the multiline edit control now, harder than it sounds since there isn't a simple multiline edit control in GTK like there is in Windows. In Windows the difference between a single line edit and a multiline edit control is just a style bit.  In GTK it is a completely different control requiring allocating text buffers, a separate function set, etc.  To keep the syntax the same I have to simulate the functionality of the Windows control.

Paul.
Ionic Wind Support Team

ExMember001

ok thanks Paul.
I'm trying to build a little launcher for the compiler.
is there a gtk function to start another application, like the system() ...
im into looking in http://developer.gnome.org/doc/API/
for reference but didnt find anything similar...

Ionic Wind Support Team

The SYSTEM command should work.   You can create a detached process using the & symbol as a parameter. 
Ionic Wind Support Team

ExMember001

ok thank you.
i should try it before asking next time ;)

jerryclement

 ;D  I finally found some time this am and ran heapsort without a hitch, well, I did have to learn how to be a superuser with Konsole. I'm using Mepis 6.0 based on Ubuntu 7 I think.

Great!  Next I will try out KrYpT's program to launch a program easier!!

Thanks Paul for the opportunity to try EBasic out now.  I was using Gambas in Linux but am much more comfortable with EBasic!

Jerry Clement
Jerry - Newbie from TN

Doc

Hummm... it's been awhile since we've heard much.
Anything new and exciting going on with the Linux version?

-Doc-

Allan

Paul,

I would like to ask if your Linux compiler works with other libraries yet?

for example could the libX11.so.6 be used now?

Allan

Ionic Wind Support Team

Yes.  Just declare the function as extern and include the library in the linker command.  That particular one is already linked against due to GTK being used.

Paul.
Ionic Wind Support Team

Allan

Paul

QuoteWhat is working is the compiler itself...

Could the compiler be used to make a library as it is?

Ionic Wind Support Team

Yes.  Just use AR which comes on every linux system.  Which is how I create the static ebstdlib library. 

Ionic Wind Support Team

Allan

Paul, Thanks for your reply.

My Last Question....

Are Class Objects (as in EBasic Windows) available now??

Ionic Wind Support Team

Windows work fine.  But OOP isn't in the linux parser yet.
Ionic Wind Support Team

Allan

Thank you Paul for the info.

Look forward to seeing your Linux at work? 

Will it be added to your downloads on the main web page?

Allan

Ionic Wind Support Team

Ionic Wind Support Team

Allan

No Sweat - she's apples - Allan

:)  ;D  :D

Allan

QuotePaul

Quote
What is working is the compiler itself...

Could the compiler be used to make a library as it is?

QuoteYes.  Just use AR which comes on every linux system.  Which is how I create the static ebstdlib library. 

Another question please...

' abclib.eba

GLOBAL GetNumber
sub GetNumber(x:int),Int
def y:int
y = x * 2
return y
endsub

GLOBAL UndoNumber
sub UndoNumber(x:int),Int
def y:int
if x <> 0
y = x / 2
else
y = -1
endif
return y
endsub


ebparse "abclib.eba" "abclib.o"

ar -rcs libabclib.a abclib.o

Is that functional now or still to come?


Ionic Wind Support Team

Allan,
ar is a linux command, and has always been working ;)

So I guest I would need clarification of your question.  Can you make libraries in Linux, yes.

Although it is kind of strange to have a library with just one object file in it.  Normally you would want each function in its own source file so any linker that is using the static library can use just the functions referenced in the target executable.

also you don't need the quotes.  It is just

ebparse blah.eba blah.o

When I build the library for Emergence I use:

ar -rcs libebasic.a *.o

in the directory that all of the object files are, one for each command in the language.

Paul.
Ionic Wind Support Team

Allan

Paul,

I am just doing a test to get the procedures right before building a real library.  I wanted the library because it would be used in more than one program.

I suppose the object file 'abclib.o' could be used instead of making a library.

Here is the code I wrote to use the library I had created and placed in /usr/lib - set as 'root'

$main

$USE "/usr/lib/libabclib.a"



DECLARE extern GetNumber(x:int),int

DECLARE extern UndoNumber(x:int),int



def win:window



OPENWINDOW win,0,0,260,160,@SIZE|@MINBOX|@MAXBOX,0,"Test - Library abclib",&mainwindow

CONTROL win,@STATIC,"Number",58,37,45,18,0x50000000,1

CONTROL win,@EDIT,"4",105,34,70,20,0x50000000|@CTEDITRO,2

CONTROL win,@STATIC,"Answer",58,66,45,18,0x50000000,3

CONTROL win,@EDIT,"",105,65,70,20,0x50000000|@CTEDITRO,4

CONTROL win,@BUTTON,"Get Number",30,113,70,26,0x50000000,5

CONTROL win,@BUTTON,"Undo Number",151,114,70,26,0x50000000,6



run = 1

'process messages until someone closes us

WAITUNTIL run = 0

CLOSEWINDOW win

END



sub mainwindow

select @MESSAGE

case @IDCLOSEWINDOW

run = 0

case @IDCREATE

CenterWindow win

CASE @IDCONTROL

IF @NOTIFYCODE = 0

SELECT @CONTROLID

CASE 5

GOSUB WorkGetNum

CASE 6

GOSUB WorkUndoNum

ENDSELECT

ENDIF

endselect

return

endsub



sub WorkGetNum

Def a:int

Def b:int

def text:string

text = Getcontroltext(win, 2)

a = val(text)

b = GetNumber(a)

text = str$(b)

setcontroltext win, 4, ltrim$(text)

return

endsub



sub WorkUndoNum

Def a:int

def b:int

def text:string

text = getcontroltext(win, 2)

a = val(text)

b = UndoNumber(a)

text = str$(b)

setcontroltext win, 4, ltrim$(text)

return

endsub





I am getting link errors. I must be doing something wrong:

QuoteCompiling...

testlib.eba

No Errors



Linking...

/home/bpak/EBasic_Linux/MyProgs/testlib.o: In function `WorkGetNum.bf':
/home/bpak/EBasic_Linux/MyProgs/testlib.asm:(.text+0x3d5): undefined reference to `GetNumber'
/home/bpak/EBasic_Linux/MyProgs/testlib.o: In function `WorkUndoNum.bf':
/home/bpak/EBasic_Linux/MyProgs/testlib.asm:(.text+0x4b2): undefined reference to `UndoNumber'
Error(s) linking testlib.eba


Hope that makes it more clear what I am trying to do?

Thank you.

Ionic Wind Support Team

Allan,
I'll look when I get back into Linux.  Had Windows work to do over the last few days.

I don't see any complaints by the linker that it couldn't find the file.  Case looks correct.

Paul.
Ionic Wind Support Team