Compiler/assembler/interpreter On The Pandora


arrrgh said:
It would be much easier to compile on the PC and run on the Pandora than copying all your source onto the Pandora so you can compile it there. And there wouldn't be any advantage to compiling on the Pandora anyway.

Any suggestions for this? Compilers, settings etc. for PC with Linux/Windows?
 
Last edited by a moderator:
Why would they want to include a compiler? If one wants to compile stuff they have to get a compiler themself from the pandora repo. But a compiler is not necessary to use the device, nor is it necessary to show its features and its nothing to play around with when you get your device first (while you might want to play a minigame, watch a movie or so). A compiler will be used by far less than 50% of the users I think and bigger projects will be cross-compiled anyway. I'm also getting a compiler for myself, but I will probably use it seldomly (on the bus for example, when I don't have access to my cross-compiler).
But hey, I do have gcc on the beagleboard - never used it for anything useful except for a single bugpatch. Cross-compiling was just a lot easier and faster otherwise.
 
As someone who coded TI-Basic for years, it'll be nice to have a portable development system that I can use modern languages on. :p I doubt I'll have any trouble using the small keyboard and small screen (try using a 96x64 monochrome screen to develop stuff sometime, haha)
 
I'm bored so if this has already been said then sorry. hehehe
I'll do some development on the Pandora, but I wouldn't suggest to anyone to make it their primary development environment. Screen, keyboard, processor, memory, everything really doesn't lend itself to the task, bit of editing should be fine though. Cross compiling isn't hard and if it was, I'm sure as a community we can put something in place to make it easier.
What makes the Pandora more accessible to people to write programs for isn't the fact that you can compile on it, it's the open nature of the device itself.
Apart from freaks like calc84maniac :p
 
JackTheKnife said:
arrrgh said:
It would be much easier to compile on the PC and run on the Pandora than copying all your source onto the Pandora so you can compile it there. And there wouldn't be any advantage to compiling on the Pandora anyway.

Any suggestions for this? Compilers, settings etc. for PC with Linux/Windows?
This is probably what you're looking for. You will need to compile things like SDL yourself though.
 
Last edited by a moderator:
I never suggested gcc on the pandora is the most ideal environment for programming. But I do terminal stuff on my iPhone, and have programmed my TI calculator for years. The ability to program anywhere and everywhere is very appealing to me. The "bad keyboard" isn't about to stop me. Why are people arguing about this? You want it or you don't.

Me, I am really not a gamer. I want a pandora as a kind of super-iPhone gadget. I would love to use it for internet, pro-audio, and programming on-the-go. I would definitely love to play games on it, but most of my gaming is done at parties with 4 friends and a small TV (mario kart!).

EDIT: when i said "coming with a compiler" i did not know about the angstrom repoistory... i just wanted to know if it was available. obviously downloading it is much better than including it.
 
arrrgh said:
2. "Being the only games machine that ships with everything you need to write apps for it" is more of a gimmick

Nope. It's useful in a practical sense.

arrrgh said:
than something useful, because the Pandora is made for playing games,

It is made as both a games console and a UMPC / PDA / etc. Assumptions based on the prominant game control layout are false. A keyboard, touchscreen, bluetooth and wifi are included for this reason.

arrrgh said:
not typing for extended periods of time.

Did you miss the big keyboard? You can become pretty efficient at typing on small keys like these with practise. And who says you need to code for hours on end? Not that I can see too much of a problem with typing for hours on it, but most portable devices are used for small periods of time at a time. The battery life is of course much longer than a laptop also...

arrrgh said:
3. I don't get this. Will there be more written software because people who aren't clever enough

Don't make stupid assumptions, and chill the tone. An easier alternative to something unfamiliar (installing a cross-compiler and needed libs) is useful. If programmers can access programming tools more easily, more of them will do so. It's a fun demonstration anyway. "This thing is just as capable as a fully fledged PC, I can even develop and compile on it independant of any other machine"

arrrgh said:
to a) realise that trying to program on the Pandora is a bad idea

Your opinion. "Trying to program"? This thing is damn powerful for a handheld and ships with a full Linux distribution and a physical keyboard. It'll be as easy as compiling on a normal PC, why do you think this is any different? The same argument could be applied to a netbook... Sluggish performance, small keyboard and screen... Oh noes, that'll be horrible to do any development on!

arrrgh said:
and B) can't work out how to download and set up a compiler will be writing programs?

Wrong. See above. Don't be arrogant.

arrrgh said:
4. Unless your bug is strictly Pandora hardware related, compiling for a PC and debugging it there would be oh so much easier than trying to debug on the Pandora.

On the move, it's useful to have the ability. Why not? And why would it be much quicker to debug on the PC? Faster compiling sure, but the keyboard isn't that much better.

2 Compile Options > 1 Compile Option
 
Last edited by a moderator:
CC_machine said:
Nope. It's useful in a practical sense.
I disagree. It is useful to have available, pure gimmick to advertise it as available out of the box.
 
Last edited by a moderator:
calc84maniac said:
As someone who coded TI-Basic for years, it'll be nice to have a portable development system that I can use modern languages on. :p I doubt I'll have any trouble using the small keyboard and small screen (try using a 96x64 monochrome screen to develop stuff sometime, haha)
Same here. I used to write code all the time in my math classes. Wonderful language, that is, incredibly accessible and easy to learn.

Anyways, it shouldn't be that hard to thumb type, and I'm fairly sure that bluetooth keyboards will work just fine. Another perk of coding directly on the Pandora is that it will be much easier to test applications, especially applications that happen to include assembly code.
 
Last edited by a moderator:
I don't expect any sane person to code large scale applications / games from scratch directly on the Pandora (unless you live on a train/bus/plane a lot :p), but it would be incredibly useful to look at the code of an existing project you're working on and be able to do little things here and there on it while your on the go on the train or bus or at school/collage. Like light debugging, or other small scale programming and testing. THAT I do not think of as a gimmick at all. However, what is against having GCC compilers and so on, included by default on the Pandora NAND? 512 MB is a lot of space, 256MB MORE then what the Pandora was going to use anyway, so why not use the bonus 256MB for useful productivity tools too? It be a waste not taking advantage of that space.
 
I work in embedded systems development for a major European aerospace and industrial applications company. I have, on my home development systems, 32 different cross-compiling environments for various platforms, and every one of them has their own requirements and administrative headaches. Its a damned nuisance to have to set things up when I want to switch platforms.

IF the compiler is onboard the Pandora from the get-go, I don't need to do anything special to any other machine, I don't have to even *have* another machine be involved in the development process: I can just use the Pandora, itself, to write apps for the Pandora. This is a highly, highly useful feature, and the day that compilers being removed from their target systems became a norm, was a sad day indeed..

Try this: take a 12 year old product off the shelf, and wonder where the compiler went? The answer is this: its gone with the computer it was originally installed on. Having a compiler installed on the Pandora means that, for as long as the Pandora hardware itself is operational, and functional, then apps can be written for the thing.

I have to support other programmers in my job, and occasionally in my hobby projects, too .. I know the hassles and stupidity involved in guiding someone through setting up their development environment. I've seen otherwise intelligent and capable people fall on the floor in tears because their carefully-crafted cross-compiling environment has gone down the drain with the latest MS patch or virus or whatever ..

Having a compiler onboard means there will *always* be a compiler for the Pandora, always, no matter what else happens in the average development environment. In fact, I believe I will make the Pandora, itself, my primary development machine for Pandora projects .. simply mount the filesystem on my PC with a large monitor, and set up my Makefiles to do the builds on the Pandora itself .. this is going to be a much smoother system than having to cross-compile, package, transfer the package, install the package on Pandora, etc.

Sure, I can understand newbies thinking its stupid to have a compiler onboard. Its easy to ignore the arguments for 'why its not "cool"'. I have 20 years of experience on this issue: its just plain *RIGHT* to put a compiler on the Pandora, and there are no good reasons to exclude it, period.

Hello-World Tutorial with Pandora-compiler-onboard:

1. Edit your code on the Pandora, press build, run.

Hello-World Tutorial with cross-compiling:

1. For your environment, find a compiler. Good luck if you have a special environment on your PC.
2. Install all the libs that the Pandora has included on its filesystem, on your other PC.
3. Compile yourfile.c on your cross-development machine. Good luck.
4. Transfer binary to Pandora, run.
5. Hope you don't have a library/linking issue that stalls your flow ..
 
torpor said:
I work in embedded systems development for a major European aerospace and industrial applications company. I have, on my home development systems, 32 different cross-compiling environments for various platforms, and every one of them has their own requirements and administrative headaches. Its a damned nuisance to have to set things up when I want to switch platforms.
Cool, but normally you set up your cross-compiler once and after that you can just use it, no need to switch around stuff afterwards. Also having yet another compiler on your system itself is also a pain because it will create the same nightmare - you can't expect the same environment for a toaster compared to a Pandora.
I have, so far, on my system, compilers for: x86, x86_64, ARM (via OE), ARM (CS G++), MIPS, MIPS (via PSPSDK), AVR - and everything is working really nice. I was even able to share files between those compilers so I don't have to have redundant files on my system. If I ever have the feeling that I loose control over all my compilers, I will just write a script so its the same steps to compile for any system. But for now, I simply put a small text in my Makefiles where I note down how I compiled the project and when that was. It takes me a single look and I know how to compile stuff.

IF the compiler is onboard the Pandora from the get-go, I don't need to do anything special to any other machine, I don't have to even *have* another machine be involved in the development process: I can just use the Pandora, itself, to write apps for the Pandora. This is a highly, highly useful feature, and the day that compilers being removed from their target systems became a norm, was a sad day indeed..
You can also do this if you download the compiler later on. And yes, you will also need libraries and header files which will probably result in problems if you try to compile anything else than "hello world" or the SDL tutorials (as I could imagine, that SDL comes pre-installed on the Pandora, maybe even with headers)

Try this: take a 12 year old product off the shelf, and wonder where the compiler went? The answer is this: its gone with the computer it was originally installed on. Having a compiler installed on the Pandora means that, for as long as the Pandora hardware itself is operational, and functional, then apps can be written for the thing.
Right, and back then, I also didn't understand why there was a compiler on the device itself. While it might be nice to have a really basic way of doing things on your hardware (like bash scripts which we have on the Pandora) there is no need for a full C compiler for example - only programmers know how to use it and they probably have their own preference and will still want to grab their required packages and IDE from elsewhere as the system can't come with everything they need except for a "hello world" application.

I have to support other programmers in my job, and occasionally in my hobby projects, too .. I know the hassles and stupidity involved in guiding someone through setting up their development environment. I've seen otherwise intelligent and capable people fall on the floor in tears because their carefully-crafted cross-compiling environment has gone down the drain with the latest MS patch or virus or whatever ..
I haven't had a single problem setting up my cross-compiling environment for ARM. It was even a lot easier than I thought it would be.

Having a compiler onboard means there will *always* be a compiler for the Pandora, always, no matter what else happens in the average development environment. In fact, I believe I will make the Pandora, itself, my primary development machine for Pandora projects .. simply mount the filesystem on my PC with a large monitor, and set up my Makefiles to do the builds on the Pandora itself .. this is going to be a much smoother system than having to cross-compile, package, transfer the package, install the package on Pandora, etc.
Its not like we will go to the gcc svn and destroy it so it can't be ran on ARM anymore, you can always grab it later on, making your pandora your primary dev. machine.
And I hope you know, that you can do it the other way around too? Compile on your computer, mount the directory with the binary on your Pandora via network and execute it without "packaging, transfering the package and installing it" (which is not a part of development though imo, otherwise you would have to do it on Pandora too)?
Compiling on your x86 is probably a good bit faster than compiling on the Pandora itself and you (probably) have a large monitor to control your debugger from with direct access to the source files the binary was build from with exactly the same object files which you can easily re-create while testing your fullscreen application on the pandora.

Sure, I can understand newbies thinking its stupid to have a compiler onboard. Its easy to ignore the arguments for 'why its not "cool"'. I have 20 years of experience on this issue: its just plain *RIGHT* to put a compiler on the Pandora, and there are no good reasons to exclude it, period.
Why don't we include TONS of free e-books, documentations, movies, games, ... Right, because they are only useful for a small minority of the users. I'm fine if there is stuff which shows off the features of your new device, but a compiler is nothing special and no-one will care if its there when they first boot their machine up as the average consumer would like to see graphics and sound output probably.

Hello-World Tutorial without Pandora-compiler-onboard:

One time setup: install compiler package and required libraries

1. Edit your code on the Pandora, press build, run.

Hello-World Tutorial with cross-compiling:

1. For your environment, find a compiler which is linked from the wiki if you use x86, which you probably do. Good luck if you have a special environment on your PC or an uncommon setup on your pandora if you really want to be that special.
2. Install all the libs that the Pandora has included on its filesystem, on your other PC or mount them via network BUT you probably have or want to compile them yourself anyway.
3. Compile yourfile.c on your cross-development machine. Good luck but you won't need it as its extremly simple unless you depend on really strange libs with tons of dependencies.
4. Transfer binary to Pandora or use the mounted network share, run.
5. Hope you don't have a library/linking issue that stalls your flow but seeing how you compiled with the libs from the pandora itself, there shouldn't be any problem..
 
Last edited by a moderator:
Not sure where cool, newbie etc comes into it all. Could say the opposite and say well must be a newbie that cant set up a cross compiling environment, oh look how cool I am being able to program on this. Anyway, I don't think it has anything to do with being cool, uncool, newbie, etc. I will be doing some development on the Pandora as stated in this and other threads, but for the majority of people I don't believe they plan on it being their primary development machine, and I'll be more than happy to have it set up on an SD card, rather than pre installed on the NAND (how many different languages are there with supporting libraries!). I'm sure that once the 1st batch is released and it's being used, that if there is a really big user base for it they'll add it, but it may mean removing other stuff, or less space in general on there. I'm not against development on the Pandora, I'll be doing it myself, I just don't believe enough people will be doing it to justify the NAND real estate.
JayFoxRox beat me to it +1
 
Since the idea is to promote development for Pandora, I find it highly amusing that there are people saying that having a complete development environment *on* the device would be 'a waste'. Think of all the new coders that will come along and just get started, precisely because they don't have to install anything else on their systems to do so ..

Anyway, I'll be pushing for it to be included in the base Pandora image. It makes a lot of sense to have it onboard. So far I haven't heard any decent arguments against having compiler-onboard, other than "don't do it, its useless". Which is obviously not the case.

The room is there - it only consumes an additional 8 to 12 megs to include gcc/g++/ld/binutils + headers.. so it sure won't be wasting any space, and it will make things a *lot* more interesting for newcomers to the Pandora scene if they have it onboard ..
 
torpor said:
Since the idea is to promote development for Pandora, I find it highly amusing that there are people saying that having a complete development environment *on* the device would be 'a waste'. Think of all the new coders that will come along and just get started, precisely because they don't have to install anything else on their systems to do so ..

Anyway, I'll be pushing for it to be included in the base Pandora image. It makes a lot of sense to have it onboard. So far I haven't heard any decent arguments against having compiler-onboard, other than "don't do it, its useless". Which is obviously not the case.

The room is there - it only consumes an additional 8 to 12 megs to include gcc/g++/ld/binutils + headers.. so it sure won't be wasting any space, and it will make things a *lot* more interesting for newcomers to the Pandora scene if they have it onboard ..
I'm sorry but are you reading a different thread? who said it's useless, so now your saying only include the languages that YOU want that's very nice of you. Even if we went with only the languages you want, ONLY 8 to 12 megs is not insignificant out of the NAND, once everything else that is required is on there. Complete development environment, so which IDE, or you talking vi, I don't think that would be very welcoming to new developers.
If someone is going to develop for the Pand I'm sure there capable of installing it onto an SD card (or even the NAND if you want), if they HAD to only develop on the machine itself. If they can't do that then there's no way in hell they'll be able to write hello world compile it and run it.
As it is you wont be able to get away from having to download stuff to use on there, this will just be one of them.
Since I'm repeating myself, I'm assuming it's still not a decent argument for why not to have it on the NAND.
 
Last edited by a moderator:
I'm saying - put a compiler onboard, so that new developers coming to the Pandora environment have access to it without having to do anything more than picking their Pandora out of the box. This is useful: you don't have to install anything more, or even have another machine around.

Yes, C/C++ compiler, is what I'm talking about - because that is the most commonly used tool and language ever used in the GP32/GP2X/WIZ/Pandora scene. Its highly useful to have it onboard, especially if headers are also there for the libraries included, because it makes development absolutely simple.

Sure, python will be there (I'm quite sure), and will also be quite useful. vim is also onboard, as will be a GUI-based text editor too. So, there isn't really a big overhead here .. just 8 megs or so for the C/C++ compiler and headers.
 
torpor said:
Sure, I can understand newbies thinking its stupid to have a compiler onboard.
Not a single person in this thread has said that. One person came close, but even he didn't go so far as to say not to do it at all.
No one is debating whether compiling on the Pandora would be useful or not.
The debate is whether it should be available out of the box, or something that needs to be installed after market by interested parties. All of your arguments are pro "it should be available", but the only one which is pro "available out of the box" is the one suggesting that gcc is going to somehow disappear off the internet entirely.
The best argument for not including it out of the box is that it will serve only a small portion of users. You have to stop just including things that someone might user somewhere, otherwise it's "oh, just one more thing" until the NAND is full.
I won't complain if the devs do include it, but I won't complain if they don't. Seriously, is "opkg install gcc" really that hard to type?
 
Last edited by a moderator:
GCC Disappearing off the Internet entirely: Not going to happen, but maybe you haven't noticed: not all gcc's are the same. The fact that its on the Internet is not the same as "its easily available in my local environment". What if the Pandora developer doesn't have a 'net connection? At least with compiler-onboard, they'll have a chance to code without needing the Internet around.

Small portion of users: Those who will have a Pandora soon are mostly going to be hackers and developer types doing interesting things with it. Its *not* a mainstream device right now - you have to have some savvy just to know about the existence of the Pandora. It is mostly a developers machine.

"opkg install gcc" = a total drag, if you don't have Internet connectivity, and .. well .. its not all you'd need to install. There's all the -dev packages (headers) too ..

Look: please just try to understand the argument that having a compiler onboard means one less barrier to entry for developers targeting the machine. Sure, they can go through the hassle of setting up a development environment, if they can find one suitable (see cf: WIZ scene), or they can just use the one thats included in the system. Its not a *huge* amount of NAND to be consuming, but it is one of the most useful things that can be included with the Pandora base system, from the get-go ..
 
I compile stuff natively on the Freerunner phone, since another person working with them set them up that way and I can't be bothered to get a cross compiler working (even though I cross compile ARM all the time for other things). It's slow as all get out; the things I compile are just several hundred lines over under a dozen files but it still takes up to multiple minutes to perform. On paper it doesn't seem like the phone would be THAT much worse than the Pandora, with the Pandora having maybe a 3x or so lead, but that phone is pretty damn gimped so in this case it could end up being way more in the Pandora's favor.

Still, expect it to be pretty damn slow compared to your big desktop. Before thinking about this I'd probably have to see how running gvim remotely from a Pandora fares because constantly uploading source to it defeats the purpose and I'm sure as hell not going to program on its keyboard directly. But it's probably a no go for me because the stuff I would compile for Pandora would probably take multiple minutes on my PC and require 1GB+ of RAM to even finish. If previous experiences are any indication, anyway :/
 
Back
Top