pocket newLISP?

Started by HPW, January 13, 2004, 11:05:15 PM

Previous topic - Next topic

Lutz

#15
Great work by Luis Carvalho to make this work thanks to Alexander Mamaich for his help and thanks to you Hans-Peter for initiating this.



Changes are small enough to incorporate them into the next release. I do not own a pocketpc but perhaps with Luis and Hans-Peter pending issues (if they surface) can be worked out.



Where can I contact Luis Luis and Alexander to thank them and discuss a couple of questions about the pocket PC platform?



Lutz

HPW

#16
Hello Lutz,



Thanks for the plan to integrate the changes.



Luis:  kozure at cox dot net



Alexander:  mamaich at uymail dot com



I hope to get some hardware soon. Maybe I can get one from a co-worker in the office to start.
Hans-Peter

HPW

#17
Taking a look at your changes in 8.1.4 I see that you did not make one change in nl-sock.c



#ifdef WINCE
fPtr->_file = handle;
fPtr->_flags = 0xFFFF;
#endif


Is it obsolet?

Or forgotten?
Hans-Peter

Lutz

#18
oops, I missed this change, I put a corrected nl-sock.c in http://newlisp.org/downloads/WinCE/">http://newlisp.org/downloads/WinCE/



If anybody want to compile it, I can put an executable in the same directory.



Lutz

Lutz

#19
There is some simplifying, I want to do in the #define/#ifdef parts for MinGW/Borland/PocketPC. It's all a bit messy, but I need to install the tools and need somebody to test.



Lutz

HPW

#20
>oops, I missed this change, I put a corrected nl-sock.c in http://newlisp.org/downloads/WinCE/">http://newlisp.org/downloads/WinCE/


Quote
> Taking a look/diff at Lutz changes in 8.1.4 I see that he did not

> make one change in nl-sock.c

>

> code:

>

> #ifdef WINCE

> fPtr->_file = handle;

> fPtr->_flags = 0xFFFF;

> #endif

>

> If it is needed you should add it again.



I was just testing something and ended up forgetting to cut this piece

of code off. Happy to know that Lutz did it.



Cheers,

K, thanks for the advice though.



--

Life is the childhood of our immortality.

-- Goethe



--

Luis Carvalho (Kozure)

kozure at cox dot net

PGP key: A616822D


So the change seems to be obsolet.



>It's all a bit messy, but I need to install the tools and need somebody to test.



I have asked Luis to make a new compile and test.


Quote
From:  "Luis Carvalho (Kozure)" <kozure@c...>

Date:  Sat Aug 21, 2004  11:47 pm

Subject:  Re: [pocketgcc] Re: newLISP compile possible?



 

ADVERTISEMENT

 

 

Hallo,



<snip>

> (What the best pocket-hardware for PGCC? Any recomodations?)



I use Dell Axim X30, and I'm very happy with it.



> Do I need something different than your source-package?



No, you just need newLISP > 8.1.4. I tested it and it compiled

out-of-the-box with Mamaich's PocketGCC.



> What must I install from Mamaich?



http://mamaich.kasone.com/ppc/arm-wince-pe.rar">http://mamaich.kasone.com/ppc/arm-wince-pe.rar



Go to his page for further details on installation. You'll also need

Cygwin (on your computer) and PocketConsole (on your to-be PPC).



> How can I get the best start with PocketGCC?



Hack newLISP to squash bugs.



> Thanks a lot again!



Bitte.



Cheers,

K, and watch for off-topics.



--

Life is the childhood of our immortality.

-- Goethe



--

Luis Carvalho (Kozure)

kozure at cox dot net

PGP key: A616822D
Hans-Peter

Lutz

#21
I got http://mamaich.kasone.com/ppc/arm-wince-pe.rar">http://mamaich.kasone.com/ppc/arm-wince-pe.rar  and installed in under my CYGWIN installation in /usr/local like recommended in Maimach's readme file, but I had to do several changes how to include files to make it compile without a warnings.



But I still canot link:

-------------------------------------------------------------------------------

arm-wince-pe-gcc -staticlibs newlisp.o nl-symbol.o nl-math.o nl-list.o nl-liststr.o nl-string.o nl-filesys.o nl-sock.o nl-import

l.o nl-web.o nl-matrix.o nl-debug.o pcre.o win32-util.o -o newlisp.exe

o(.text+0x0):newlisp.c: multiple definition of `main'

al/lib/gcc-lib/arm-wince-pe/3.3.3/../../../../arm-wince-pe/lib/crt0.o(.text+0x2c): first defined here

al/lib/gcc-lib/arm-wince-pe/3.3.3/../../../../arm-wince-pe/lib/crt0.o(.text+0x6c): undefined reference to `WinMain'

: ld returned 1 exit status

 *** [default] Error 1

 Leaving directory `/home/Lutz/newlisp-8.1.5'

* [wince] Error 2

--------------------------------------------------------------------------------



it is complaining, that 'main' is already defined and that 'WinMain' is not defined.



Is Luis perhaps using an older arm-wince-pe.rar ? My compile is behaving very differently.



Lutz

HPW

#22
I reposted your post in the pocketGCC forum:



http://groups.yahoo.com/group/pocketgcc/">http://groups.yahoo.com/group/pocketgcc/



Waiting for Luis answer.
Hans-Peter

HPW

#23
The last answers:


Quote
From:  "Alexander M." <mamaich@u...>

Date:  Mon Aug 23, 2004  12:49 am

Subject:  Re: newLISP compile possible?

 

>

> it is complaining, that 'main' is already defined and that 'WinMain'

> is not definded.



To fix this you may add "-target=win" or "-target=con" GCC command

line parameter. Or you can install update

http://mamaich.kasone.com/ppc/specs.rar">http://mamaich.kasone.com/ppc/specs.rar, it tries to guess the program

entry point.


Quote
From:  "Luis Carvalho (Kozure)" <kozure@c...>

Date:  Mon Aug 23, 2004  1:52 am

Subject:  Re: [pocketgcc] Re: newLISP compile possible?



Hallo,



> Is Luis perhaps using an older arm-wince-pe.rar ? My compile is

> behaving very differently.



I think I used the last version, but applied all patches provided by

Mamaich, i.e. {libcfix, libcfix1, specs}.rar. Also, I had to comment out

some definitions on sys/wcetypes.h to avoid redefinition errors, like

HMODULE and HINSTANCE.



Sorry for the offtopic guys...

<offtopic>

I tested the last version of newLISP, including the qa file, and

everything was almost perfect, with the exception of xml-parse that

raised an exception and crashed newlisp. I tried to write to Lutz, but

the mail keeps bouncing back. Can I forward it to you so that you can

pass it to Lutz?

</offtopic>



Asko, I'll test LuaX as soon as I have time. I'm still trying to develop

a numerical package for Lua (that I'll try to port to wince if I get g77

to work), and I'll give LuaX a chance as soon as I'm finished.



Mamaich, I agree with you on the PPC specs. But, hey, I'm a cheap guy. :)



Cheers,

K, and a slow starter.



--

Life is the childhood of our immortality.

-- Goethe



--

Luis Carvalho (Kozure)

kozure at cox dot net

PGP key: A616822D


Quote
From:  "Alexander M." <mamaich@u...>

Date:  Mon Aug 23, 2004  8:18 am

Subject:  G77 binaries. (Re: newLISP compile possible?)

 

> Asko, I'll test LuaX as soon as I have time. I'm still trying to

develop

> a numerical package for Lua (that I'll try to port to wince if I get

g77

> to work), and I'll give LuaX a chance as soon as I'm finished.



I've uploaded a compiled Cygwin version of G77 compiler and other

tools. Compiler is probably working.

http://mamaich.kasone.com/g77_objc.rar">http://mamaich.kasone.com/g77_objc.rar 6,249,571 bytes.

Archive contains all GNU compilers I was able to build and all

libraries I have. It also has an updated static libc.a with a test

implementation of fork() function, though it is still unfinished.



To install - decompress it to your /usr/ directory (archuive already

contains "local" subdirectory. It would overwrite some of your files,

so do the backup.



To compile ObjectiveC program:

gcc test.m -lobjc



To compile G77 program you should edit "specs" file and remove

"-include fixincl.h" from it (F771 does not support this switch), then

run it as following:

gcc hello.f -lfrtbegin -lg2c -target=con

You have to specify "-target=con" when main() function is located

inside library (this is true for G77). In such case compiler cannot

guess the correct target.

The archive already contains a modified "specs" file. If you use it,

then when you compile normal C/C++ programs you have to add " -include

fixincl.h" to the end of every GCC command line.

Later I'll modify G77 sources so that it would ignore "-include"

command line.



Archive contains 2 examples.

It also contains a Java compiler and an updated GDB debugger. I have

not tested them.
Hans-Peter

Lutz

#24
Thanks Hans-Peter, Luis and Alexander, how strange that the email to me bounced, I have had no problems receiving email otherwise. Again my address is: lutz at nuevatec dot com and the word 'newlisp' or 'consulting' must be included in the subject line, unless I have registered your email addresses, which I did for Hans-Peter, Luis and Alexander).



The '-target=con' option did the job, thanks. I can make a clean compile/link now with the latest (August 22, 2004) arm-wince-pe.rar and un-patched.



I have put changed files and a compiled executable for the ARM PPC in:



http://newlisp.org/downloads/WinCE/">http://newlisp.org/downloads/WinCE/



Remember I can *not* test the executable, as I don't have a PPC.



Lutz



PS: net work functions are not tested in the current qa

Lutz

#25
I put a new nl-xml.c in http://newlisp.org/downloads/WinCE/">http://newlisp.org/downloads/WinCE/ which might solve the xml-parse problem on the PPC (and Sparc). The newlisp.exe is also redone with the new nl-xml.c



Lutz

HPW

#26
I have asked Luis to test the new EXE.



I have started to do some research for PPC-hardware.

Since the new VGA-based PPC are on the horizon, it

maybe worth to wait the time they get into the markets.



Luis and Alexander gave some advice about their hardware

(Dell X30 and imate Pocket).



As always get as much speed and memory as possible! ;-)

Dream-PPC: VGA/624MHZ/128MB RAM

Pocket Windows 2003 SecondEdition
Hans-Peter

HPW

#27
Quote
From:  "Luis Carvalho (Kozure)" <kozure@c...>

Date:  Tue Aug 24, 2004  4:44 pm

Subject:  Re: newLISP compile possible?



Hallo,



Sorry again for the offtopic...



> Lutz get his compiler to work and after I had also problems

> with xml-parse on Solaris Sparc, he thinks that he found the problem.

> He compiles the new EXE and post all changed sources here:

>

> http://newlisp.org/downloads/WinCE/">http://newlisp.org/downloads/WinCE/

>

> Can you test the new EXE with the qa file and give info about results.

> Lutz also registered your and Alexander's email to get always through

> his mail-filter.



Everything works right now. I'll tried to write to you and Lutz again,

with no success. Please tell him that qa has only minor problems:



- test-exec and test-process, simply because windows mobile does not

contain native _ls_ and _cat_.



- test-pipe, probably because pipe is not properly ported yet. Check the

compilation flag I put in nl-sock.c regarding this.



xml-parse works now.



Cheers,

K, I think spam is a big problem in Deutschland... :)



--

Life is the childhood of our immortality.

-- Goethe



--

Luis Carvalho (Kozure)

kozure at cox dot net

PGP key: A616822D


So xml-parse is working and all other problems have their explanation.



So no more experimental?



;-) Still no PPC-Hardware.



No idea with the mail-problem.

I have no personel mail-filter. (Maybe t-online does some)
Hans-Peter

Lutz

#28
Thanks again to Luis. I am glad 'xml-parse' now works on both, Sparc and PPC, probably it was a byte-order problem.



I am currently working on a platform independent QA file, which also gives more diagnostics on failure and keeps on testing although a function has failed. I have got it more or less working for Win32 and Linux, but still have problems on BSD. Its mainly test routines where 'process' or 'exec' are involved, where the timing and handshaking is hard to get right.



The next qa by default will not test pipe, process, exec and udp functions but all other net-working functions (they are not tested currently).



Supplying an extra option it will also test pipe, process, exec and udp. I can test udp functions only when I have 'process' to start a second newlisp session.



I will mark the PPC version as non-experimental in the next version and document what should not be expected to work. It will also get it,s OS Id as 7 in 'sys-info'.



Lutz