Welcome, Guest. Please login or register.
Amiga Kit Amiga Store Iridium Banner AMIStore App Store A1200/A600 4xIDE Interface

AuthorTopic: Starting Development in AROS  (Read 1462 times)

0 Members and 1 Guest are viewing this topic.

Offline Ranchu

Starting Development in AROS
« on: January 09, 2005, 12:09:30 PM »
I want to start developing some software utilities for AROS, however I'm having some difficulties getting the development environment set up.

I've got AROS running through Linux and I have downloaded the AROS source code but that's about as far as I got.  I tried to follow the development manual on the AROS website but got lost when they started talking about the build tools required.
 

Offline falemagn

Re: Starting Development in AROS
« Reply #1 on: January 09, 2005, 12:24:02 PM »
If you don't want to integrate your code into the AROS CVS (yet), all you need to do is set up a crosscompiler. In order to do that you can compile AROS itself, in which case the crosscompiler (a fake one, but which does the right job) is automatically set up for you under the

Code: [Select]

bin/linux-i386/tools/i386-linux/


directory, within the toplevel AROS source dir.

There you'll find i386-aros-gcc, i386-aros-ld and so on which you can use to make your own programs runnable under AROS.

Hope that helps.


 

Offline Ranchu

Re: Starting Development in AROS
« Reply #2 on: January 09, 2005, 12:28:50 PM »
I don't want to start work on AROS itself at this point, so I have no need for access to their CVS.

I'm need to set up the development environment so that I can write utilities for AROS.
 

Offline falemagn

Re: Starting Development in AROS
« Reply #3 on: January 09, 2005, 12:33:08 PM »
Quote

Ranchu wrote:
I don't want to start work on AROS itself at this point, so I have no need for access to their CVS.

I'm need to set up the development environment so that I can write utilities for AROS.


Yes, and what I told you applies perfectly well to your case: you said you aready have the AROS sources, so the fastest way for you to get ready is to compile those sources and get the (fake) crosscompiler from where I told you.

Alternatively, you can download the linux binary from the download page, and from there also download the SDK package. You'll unpack the SDK package somewhere, run the installation script in it and it will automatically set up for you the (fake) crosscompiler.
 

Offline Ranchu

Re: Starting Development in AROS
« Reply #4 on: January 10, 2005, 10:04:48 AM »
Okay I've installed the AROS SDK and put the bin folder in my path.

When I run
Code: [Select]
i386-aros-gcc -c hello.c it compiles fine but when i run
Code: [Select]
i386-aros-gcc -o hello hello.c it gives me the following error:

ld: cannot find -lgcc_s

Here is the output from
Code: [Select]
i386-aros-gcc -v hello.c

Reading specs from /usr/lib/gcc-lib/i486-slackware-linux/3.3.4/specs
Reading specs from /usr/share/aros-sdk/i386-aros/lib/gcc-lib/specs
Configured with: ../gcc-3.3.4/configure --prefix=/usr --enable-shared --enable-threads=posix --enable-__cxa_atexit --disable-checking --with-gnu-ld --verbose --target=i486-slackware-linux --host=i486-slackware-linux
Thread model: posix
gcc version 3.3.4
 /usr/lib/gcc-lib/i486-slackware-linux/3.3.4/cc1 -quiet -v -D__GNUC__=3 -D__GNUC_MINOR__=3 -D__GNUC_PATCHLEVEL__=4 -D__AROS__ -D__AROS__ -nostdinc -isystem /usr/share/aros-sdk/i386-aros/include -isystem /usr/lib/gcc-lib/i486-slackware-linux/3.3.4/include hello.c -quiet -dumpbase hello.c -auxbase hello -version -o /tmp/ccDz4jrR.s
GNU C version 3.3.4 (i486-slackware-linux)
        compiled by GNU C version 3.3.4.
GGC heuristics: --param ggc-min-expand=81 --param ggc-min-heapsize=96845
#include "..." search starts here:
#include <...> search starts here:
 /usr/share/aros-sdk/i386-aros/include
 /usr/lib/gcc-lib/i486-slackware-linux/3.3.4/include
End of search list.
 /usr/lib/gcc-lib/i486-slackware-linux/3.3.4/../../../../i486-slackware-linux/bin/as -V -Qy -o /tmp/ccmZorxF.o /tmp/ccDz4jrR.s
GNU assembler version 2.15.90.0.3 (i486-slackware-linux) using BFD version 2.15.90.0.3 20040415
 /usr/share/aros-sdk/i386-aros/lib/gcc-lib/collect-aros -m elf_i386 -L/usr/share/aros-sdk/i386-aros/lib /usr/share/aros-sdk/i386-aros/lib/startup.o -L/usr/lib/gcc-lib/i486-slackware-linux/3.3.4 -L/usr/lib/gcc-lib/i486-slackware-linux/3.3.4/../../../../i486-slackware-linux/lib -L/usr/lib/gcc-lib/i486-slackware-linux/3.3.4/../../.. /tmp/ccmZorxF.o -lgcc --as-needed -lgcc_s --no-as-needed -lamiga -larossupport -larosc -lm -lgcc --as-needed -lgcc_s --no-as-needed -lautoinit
ld: cannot find -lgcc_s

I'm running Slackware 10.0.

Any ideas?
 

Offline Eniodis

Re: Starting Development in AROS
« Reply #5 on: January 10, 2005, 10:28:58 AM »
I'm not an expert in AROS environnement but I can recommend you :
1. try > gcc hello.c
   it may give you an exe called by default 'a.out'

2. Your command line is wrong during the linking
   > gcc -o hello hell.o  (and not hello.c !!)


Regards
 

Offline falemagn

Re: Starting Development in AROS
« Reply #6 on: January 10, 2005, 12:07:59 PM »
Quote

Any ideas?


Yup, I forgot to add the -static flag to the line where the real gcc is invoked. I fixed this in the CVS, so tonight's build should be fine, but you can simply open the i386-aros-gcc file and add -static at the end of the command line it contains. Tell me if that works.
 

Offline Ranchu

Re: Starting Development in AROS
« Reply #7 on: January 11, 2005, 09:27:25 AM »
That seems to have fixed it falemagn.  I can now successfully compile and run a very simple program which outputs text to the console (the only library it uses is stdio).

However I'm now having a problem compiling the Zune "Hello World" example from AROS' website.  The error I get is:

There are undefined symbols in 'hello':
         U MUI_MakeObject
         U MUI_NewObject

Am I correct to assume there is a problem with my library files?  I'm using the AROS SDK downloaded a couple of days ago.
 

Offline falemagn

Re: Starting Development in AROS
« Reply #8 on: January 11, 2005, 06:20:22 PM »
Quote

However I'm now having a problem compiling the Zune "Hello World" example from AROS' website. The error I get is:

There are undefined symbols in 'hello':
U MUI_MakeObject
U MUI_NewObject


That's because those functions are in the libmui.a library, so you need to append -lmui at the end of the command line which you use to produce the executable. If this is not mentioned in the example, then there's a bug in the documentation.

However, you could avoid linking with that library if you do this

Code: [Select]

    #define MUIMASTER_YES_INLINE_STDARG


before including any header file related to Zune/MUI.
 

Offline Ranchu

Re: Starting Development in AROS
« Reply #9 on: January 12, 2005, 03:29:55 AM »
Thanks again falemagn, I'm starting to think you know this stuff ;-)

I'm not very familiar with the AmigaOS API (most of my programming has been in Windows and Linux).  What would you recommend as a resource?  I was thinking of buying a copy of the Amiga Development CD.
 

Offline falemagn

Re: Starting Development in AROS
« Reply #10 on: January 12, 2005, 05:52:36 PM »
Quote

Thanks again falemagn, I'm starting to think you know this stuff


Well, I better do, as I'm one of the AROS developers ;-)

Quote

I'm not very familiar with the AmigaOS API (most of my programming has been in Windows and Linux). What would you recommend as a resource? I was thinking of buying a copy of the Amiga Development CD.


That's certainly a good idea, yes.
 

Offline CoolCat

Re: Starting Development in AROS
« Reply #11 on: January 12, 2005, 06:04:15 PM »
innoideia was nice, but looks like it is closed now! =o(
http://utilitybase.com/article?action=show&id=68

ps: the rkms was online on net too...but i think it also went down
 

  • Guest
Re: Starting Development in AROS
« Reply #12 on: January 12, 2005, 11:22:15 PM »
Quote

CoolCat wrote:
innoideia was nice, but looks like it is closed now! =o(
http://utilitybase.com/article?action=show&id=68

ps: the rkms was online on net too...but i think it also went down


Brought back to life by the Wayback Machine! :-)

http://web.archive.org/web/20040216024756/www.innoidea.hu/subsites/amiga/developer/phpwebdev.php