maemo.org - Talk

maemo.org - Talk (https://talk.maemo.org/index.php)
-   Development (https://talk.maemo.org/forumdisplay.php?f=13)
-   -   Technology Preview: MADDE (https://talk.maemo.org/showthread.php?t=38075)

danielwilms 2010-04-21 06:49

Re: Technology Preview: MADDE
 
Quote:

Originally Posted by Venemo (Post 619825)
Hi,

This may be the most idiot question ever, but...
MADDE is a cross-compiler, right?
So why isn't there any documentation about how to actually compile with it? I mean, without Qt Creator and stuff, to compile pure C and GTK applications.

Completing the documentation with a C example is a good argument. We will try to provide you one.

Daniel

danielwilms 2010-04-21 06:55

Re: Technology Preview: MADDE
 
Quote:

Originally Posted by tvogel (Post 586755)
I have a question about third-party libraries in madde in this new thread. This one is getting a bit long and mixed up for me.

As you saw in the thread, you are referring to, the third party library support is not completely solved yet, besides pointing directly to the library in your *.pro file. At least this works for me. We are discussing different options at the moment, and will document a conclusion soon. Still this is a tech-preview, and your feedback helped a lot to get the different perspectives.

Daniel

danielwilms 2010-04-21 08:37

Re: Technology Preview: MADDE
 
Quote:

Originally Posted by Venemo (Post 619825)
Hi,

This may be the most idiot question ever, but...
MADDE is a cross-compiler, right?
So why isn't there any documentation about how to actually compile with it? I mean, without Qt Creator and stuff, to compile pure C and GTK applications.


Thanks to Sampo, you will find the example now here!

Daniel

Venemo 2010-04-21 10:49

Re: Technology Preview: MADDE
 
Quote:

Originally Posted by danielwilms (Post 620623)
Thanks to Sampo, you will find the example now here!

Daniel

Thank you very much! :)
This is nice.

The next step would be getting MADDE to run the application on the device. Qt Creator is capable of it for Qt applications, but is there a way to do it manually?
(Without packaging and having to manually install the .deb on the N900, of course.)

If this is possible, I'd like to get Visual Studio to work with MADDE's compiler and run the application on the device.
If the above is possible, this will be an easy part.

A working debugger would also be great, but I think I'll manage without it.
(Even Qt Creator cant't debug the remote application.)

attila77 2010-04-21 10:49

Re: Technology Preview: MADDE
 
Quote:

Originally Posted by danielwilms (Post 620511)
As you saw in the thread, you are referring to, the third party library support is not completely solved yet, besides pointing directly to the library in your *.pro file. At least this works for me. We are discussing different options at the moment, and will document a conclusion soon. Still this is a tech-preview, and your feedback helped a lot to get the different perspectives.

Apropos feedback, I exchanged a few mails with Tomi Ollila (not sure if he's active on the forum) with regard to maybe having a version/option of MADDE without the rootstrap+toolchain stuff, for use in Python projects - the benefit is being able to execute & package Python code from a desktop Python IDE (via plugins, for example), basically what PluThon does but without the Eclipse+Sbrsh tie-in.

sampppa 2010-04-21 11:48

Re: Technology Preview: MADDE
 
Quote:

Originally Posted by Venemo (Post 620801)
Thank you very much! :)
This is nice.

The next step would be getting MADDE to run the application on the device. Qt Creator is capable of it for Qt applications, but is there a way to do it manually?
(Without packaging and having to manually install the .deb on the N900, of course.)

If this is possible, I'd like to get Visual Studio to work with MADDE's compiler and run the application on the device.
If the above is possible, this will be an easy part.

A working debugger would also be great, but I think I'll manage without it.
(Even Qt Creator cant't debug the remote application.)

Check this:
http://wiki.maemo.org/MADDE/Device_runtime

rontti 2010-04-21 13:07

Re: Technology Preview: MADDE
 
Quote:

Originally Posted by Venemo (Post 619825)
Hi,

This may be the most idiot question ever, but...
MADDE is a cross-compiler, right?
So why isn't there any documentation about how to actually compile with it? I mean, without Qt Creator and stuff, to compile pure C and GTK applications.

Its quite simple. When you have MADDE installed you are able to
compile like this.

Code:

  mad gcc -o foo foo.c
If you have no default target you can do

Code:

  mad -t <target_name> gcc -o foo foo.c
If you have our own Makefile you can do

Code:

  mad -t <target_name> make
Note that when you are using GCC's -I and -L options
all paths that starts with / are redirected into the used sysroot.
Target defines the sysroot.

For example following

Code:

mad -I /usr/include/mydir/ gcc -o foo foo.c
turns to be

Code:

mad -I <sysroot>/usr/include/mydir/ gcc -o foo foo.c

And finally gtk example.

Code:

mad gcc -o foo foo.c `mad pkg-config --cflags --libs gtk+-2.0'
And if you wanne see what options are really called use -v option as a first gcc option

Code:

sec-094:~ savanain$  mad gcc -v -I /usr/include/kala -I lohi -o foo foo.c
 command: /Users/savanain/.madde/0.6.19/toolchains/arm-2009q1-203-arm-none-linux-gnueabi_mac/bin/arm-none-linux-gnueabi-gcc
 arg 0: /Users/savanain/.madde/0.6.19/toolchains/arm-2009q1-203-arm-none-linux-gnueabi_mac/bin/arm-none-linux-gnueabi-gcc
 arg 1: --sysroot=/Users/savanain/.madde/0.6.19/sysroots/fremantle-arm-sysroot-2.2009-51-1-qt453/
 arg 2: -specs=/Users/savanain/.madde/0.6.19/targets/fremantle-qt-0951/specs
 arg 3: -v
 arg 4: -I
 arg 5: =usr/include/kala
 arg 6: -I
 arg 7: lohi
 arg 8: -o
 arg 9: foo
 arg 10: foo.c

Note that arg 1 and 2 are added.
arg 5 is modified. ( / is replaced by =)

Venemo 2010-04-21 15:20

Re: Technology Preview: MADDE
 
Quote:

Originally Posted by sampppa (Post 620884)

I already have, but I only used it for Qt Creator.

It is nice to see that it is possible to use MADDE without it.

rontti 2010-04-21 15:37

Re: Technology Preview: MADDE
 
Quote:

Originally Posted by Venemo (Post 621154)
I already have, but I only used it for Qt Creator.

It is nice to see that it is possible to use MADDE without it.

The instruction behind link are not anyhow related on QT. They are pure MADDE instructions. You don't need QT creater when you follow those instructions.

Venemo 2010-04-21 19:23

Re: Technology Preview: MADDE
 
Quote:

Originally Posted by rontti (Post 621172)
The instruction behind link are not anyhow related on QT. They are pure MADDE instructions. You don't need QT creater when you follow those instructions.

Yeah, but at first I didn't notice. :)
After Sampppa's post, I got it. :P


All times are GMT. The time now is 18:15.

vBulletin® Version 3.8.8