Closed. This question needs to be more focused. It is not currently accepting answers.
Want to improve this question? Update the question so it focuses on one problem only by editing this post.
Closed 9 years ago.
Improve this question
A few months ego I purchased Nokia N800 device and since then I'm itching to write some code for it. I know that some of the application I'm running are written in Python and that there is a Mono port for the Maemo platform as well.
Basically what I'm asking is:
Is there a recommended development language for Maemo platform?
What development tools exist?
Can I use Windows or Linux as my primary development machine, and which do you recommend and why?
I highly suggest that you try C++ and QT.
QT is already well supported for Diablo and Fremantle, and the next release of Maemo (Harmattan) should be based on QT.
Learning QT will be much much easier than GTK+, coding will be faster and more fun, your application can be compiled in various platforms and you can even develop and debug in Windows, then simply run a qmake && make in a scratchbox environment.
Take a look at this tutorial: Getting started wit QT for Maemo
You still need a Linux box to compile your code for a Maemo device.
If you are using windows, you can setup ubuntu (or kubuntu) in a VirtualBox machine.
Maemo SDk + along with Scratchbox 2 is a better alternative than Maemo SDk & Scratchbox.
Personnally, I'm using QT creator in Windows, kubuntu 9.04 in VirtualBox, and I've never been happier.
When I started, I tried the "official" approach : Ubuntu, GTK+, C language and scratchbox 1. ... that was painful.
The Hildon framework is made up of GTK+ extensions, so the language is C. You can use C++ wrappers (maemomm) too. Or you can go with pymaemo for building apps with Python, which to me is much easier than C or C++. I've also seen an attempt at a ruby port, but have not followed up with that project recently.
For the development environment, there is "scratchbox", which gives you a sandbox for compiling and running your app. Here's a link on how to set up a scratchbox development environment. (It sure took me a long time to get everything setup.)
You'll have to use Linux as your development machine because your Nokia N800 is really a mini Linux computer.
If you want to have an IDE experience, try the ESbox plugin for Eclipse.
Have fun hacking!!!
I've just found two tutorials on Maemo.org:
Writing Hildon Desktop Plug-ins for Maemo 3.x
How to write maemo desktop plugins for maemo 4.x
For extra on-the-go fun, you can get the linux gcc and make tools running on the tablet itself and do your programming and compiling on the device.
For any help with this sort of stuff the Maemo Talk forums are fantastic.
Ruby for Maemo is being hosted at http://code.scottishclimbs.com/maemo/
I've not yet tried it myself.
There's a Scratchbox Virtual Appliance for Maemo development (I'm not sure if the link is the right one) but that's how I started hacking. It took forever for me to figure out how to set up scratchbox by myself.
I have to echo Karatchov's response.
The 2 recommended approaches currently are:
Python + PyGtk
C++ & Qt
Using anything else, you set yourself up for some pain (unless you are a Gtk+ veteran - since you are asking this question, I assume you are not). C++ & Qt is the future of Maemo anyway, and Qt works well on "old" platforms such as Diablo.
As a debugger, I recommend you pick up (compile) "cgdb". The plain old gdb can be a bit too spartan.
Generally, you should develop your application as a "normal" Qt application using Qt Creator, and occasionally test it in scratchbox.
Nokia has been working hard to provide tools and documentation for developers. I would say one of the best places to start is at Forum Nokia:
http://www.forum.nokia.com/Technology_Topics/Device_Platforms/Maemo.xhtml
The next stop for developing for Maemo is of course Maemo's headquarters:
http://maemo.org/development/
These two links are to portals where you'll have to drill down for further info, but they are pretty good starting points. Now to answer your questions directly:
I suppose the two 'recommended' languages are C and python. While these are well supported, they are not the only choices as you have seen from previous answers. In addition to those languages, perl is on the device, though it is not in the same state as it is on debian.
The chief development tool is the SDK. It allows you to test the environment and compile software for the device. You can also use Eclipse for which there are plugins.
It is recommended that you use linux as a development machine, but you can run it in a virtual machine on Windows. While I prefer my OS to be 100% free and therefor choose debian, Nokia is working hard to make a better development environment for Windows. So rest assured that Nokia does not necessarily share my bias! :-)
I develop mainly with python and pyside (I develop on an N900).
I have all my files in the nokia N900 and I use sshfs to mount my home directory on my pc.
I then develop on my desktop, while actually saving everything right into the cell phone, and use SSH to run it remotely.
If you get too lazy to even pick up the device to look at the screen, you might want to use VNC; though personally, I feel it's just not responsive enough.
Yes, all I have on my desktop is my editor (sublime-text, by the way). The rest live on the mobile device. I use git to sync things/make backups, etc.
py2deb is great for making packages once you want to distribute your proyect. Again, no need to install anything on your desktop.
IF you'd rather be more conservative, the SDK is designed for debian, and you'll suffer a lot with any non-debian-based OS (unless you use a VM). Be warned! :)
Related
I have tasted both Qt 4.x/5.x and GTKmm 3.x and I really like GTKmm over Qt.
Now I have just discovered that GTKmm 3.x doesn't offer a Windows porting, they also do not offer a Mac porting, basically I can't find nothing but libraries/sources/binaries for Linux.
Apparently the Windows support ( I'm not sure about the situation for the Mac OS stuff ) was dropped in the 2.x era and it's still not-existing today.
I have planned to use GTK 3.x for specific reasons, especially for some new features introduced by the 3.x branch, so using GTK 2.x is an option off the table.
Now I ask: there is something new for the Windows and/or Mac support for GTK 3.x ? There is something ? even experimental projects ?
No it isn't - at least when you want to be on the safe side for the future. The MacOSX and GTK ports are less then perfect and completely voluntarily which means by a program of this complexity and size they are not not active developed. And nobody cares that old features are implemented before new are added.
Almost 2 years since GTK3 released and there is still no official Windows binary distribution. And on one of the GNOME conferences there was an open discussion if GTK4 should be made Linux only. Well i guess they mean Linux/BSD - but Wayland is pure Linux at the moment and BSD do have a lack of developer for Desktop stuff.
This should be enough to scare any person with a serious program which requires real world investment away.
Also i strongly belive that cross platform GUI toolkits are a thing from the past. Abstract the GUI of your app and develop for every platform. With the success of the AppStores you will be forced more and more to use the native platform style. Your app will already be rejected by Apples AppStore if it looks to different. Windows is now enforcing WinRT. Be prepared that this will just be more important in the future.
So the way to go is WxWidgets which uses native widget sets. Skip GTK
2018-12-18 Update:
GTK+ 3 on Windows has been supported through MSYS2 for years.
Old answer:
GTK for Windows is currently provided "as-is". What it means, basically, is that there are no GTK maintainer that use Windows, and those using Linux have enough work maintaining the Linux builds.
This means that any contribution for GTK 3 on Windows is welcome, some people are using it, but that's not ready for the masses because nobody steps up to do the work, which won't be done by magic overnight. So it's usable, but don't expect reactive maintenance.
As for the build, there's a french dude providing an (unofficial) GTK 3 installer for Windows.
As of right now, no.
Like Frédéric Hamidi said, see Where can I download precompiled GTK+ 3 binaries or windows installer? for more info.
GTK on Mac has worked well for a long time and continues to work into the 3.x series:
https://live.gnome.org/GTK%2B/OSX/Building
You can also install GTK 3.x using MacPorts, but I don't know how well that works.
I'm going to enter a small game competition in the coming months. They require the submission to be able to be compiled ( and it will be, before being run/evaluated for the contest) on Linux. I'm going to be using SDL and C++. I've only ever developed on Windows before and I've grown quite accustomed to the benefits Visual Studio gives. I'd like to be able to develop in windows with VS, and then near the end of the process migrate it over to linux. Beside making sure SDL is already installed on the Linux machine, are there things I can do throughout development that will make the process easier? Also, the contest rule for all of this states:
it must also work on an open platform (we strongly recommend making sure that your program run on modern flavors of GNU/Linux, as all of the judges will have access to it).
I assume compiling/running in Ubuntu (already have a home server with this) would be sufficient for this?
Your question is slightly open-ended, but my first suggestion would be to use a proper cross-platform build system such as CMake from day one. I would refrain from "migrating" to Linux at the very end; you may be under a rough schedule (and maybe run into problems you did not anticipate). Thus, a continuous build of (working) Linux versions will help ease your worries.
Furthermore, if the game is meant to run solely under Linux, why not install Ubuntu in a Virtual Machine somewhere and get acquainted with one of the development environments such as kdevelop or qtcreator? Wouldn't direct contact with the platform you are developing for make things a little easier?
I'm developing games and started like you. I'd advise you to use SFML library for this purposes. It's not very big and is very good thing to start from.
There you can use:
2D renderer (OpenGL)
Fonts
Timers
Wrappers around images/sprites
Post effects/shaders
Sound
Network
In this page you can find a few start examples.
I have developed an application designed for commercial use. Application is based on Qt. But I have to use Themida, the anti-cracking software. So I need to compile this software for Linux/MacOS as well, but there is not any obfuscation software like themida. I have an idea.. Is it possible to embed wine to application? As google picasa for example... If yes then how to do that? Are there any examples...
Is it possible to embed wine to application?
You can't "embed" it, because it is a huge collection of dlls. Another problem is that wine is LGPL, so "embedding it" (static link with LGPL) is "no go" for proprietary/closed-source app.
I think you should be able to link with it dynamically.
2 years ago it was possible to make application link with winelib and get access to wine facilities this way. Haven't tried that myself.
It will be probably easier to simply compile application for windows, and then ensure it works under wine - less hassle. However, if I were you, I'd attempt to find different protection scheme - any scheme that doesn't rely on windows-specific technology. Relying on wine to make your app work isn't a very good idea (IMO).
You do not "embed" Wine. Wine is a set of libraries installed on linux that act as a middle-tier between a windows program and the linux system.
Simply compile your app on Windows, preferably wrap it into an installer with all your dependent .dll's like "themida" and possibly the Qt .dll's.
Then install wine on your linux system, try to install your app and cross fingers ;)
Closed. This question does not meet Stack Overflow guidelines. It is not currently accepting answers.
We don’t allow questions seeking recommendations for books, tools, software libraries, and more. You can edit the question so it can be answered with facts and citations.
Closed 6 years ago.
Improve this question
I am a newbie in linux and programming. I want to learn linux command and use create some C and C++ programme to interact with the linux API from my windows XP. However, I am not sure how to set up the environment from my windows based computer.
What programme should I install? Also, it seems like linux has Ubuntu, Fedora. I heard of Red Hat as well. What is the difference and which one should I install?
Also, is there any difference between using linux with user interface like Ubuntu, using an IDE to create programme AND the command line terminal using VIM to create programme?
Besides, I have heard of using Valgrind to debug programme. Does Valgrind works together with an IDE in Ubuntu or works in command line terminal only? If my IDE already has debugger, do I still need Valgrind?
Sorry for such newbie questions.
Thanks.
Your question is very vague and prone to start argumentations and fights. Also, you miss-used many terminologies there and before you even start programming with Linux, you should first get acquainted with the OS, especially the terminal... But first things first, programming in C/C++ for Windows is not entirely the same as programming in C/C++ for Linux. If you want the latter, then use the latter.
My suggestion is this :
Grab VirtualBox and install it.
Download Ubuntu ; IMHO, Ubuntu is best for starters (or anyone as a matter of fact) because it has a lot of support, a good user base and is compatible with pretty much any Linux software installer (RPM, deb, etc.) You can choose any other distribution, it doesn't really matter, but I recommend this one. [1]
Start VirtualBox and create a new Ubuntu virtual machine. The steps are pretty straight forward, consult the documentation for any assistance). Your virtual machine may look something like :
1GB of RAM will be enough;
10GB of hard disk (you won't need much more, but you may increase the size if you think you'll need more space for /home, see next point)
a network adapter set a bridged
etc.
Install Ubuntu from the ISO that you have just downloaded (that you have mounted into VirtualBox as a CD-ROM device) You'll only need about 8GB of hard disk total for a typical, minimum Ubuntu installation (ext4+swap), however I recommend this setup.
Enjoy your installation. (Tip: now you can install the VirtualBox's Guest Additions.)
Open a terminal in your Ubuntu VirtualBox window and type sudo apt-get install build-essential to install the GCC compiler
Gedit is already installed by default with Ubuntu and it's a fairly good text editor compared to Windows' notepad. However, vim is not, but you can install it with sudo apt-get install vim in the terminal.
And voilà! You're all set to go to do some C/C++ programming in a Linux environment, where you can still have Windows in case you're stuck.
I also recommend you do most of your learning using the terminal (aka the command line) so you know how things work under the hood. Then, when you are familiar with the GCC compilier, MAKEFILEs, etc. you can install some IDE to avoid repeating tasks; The two best I have yet found are Ajunta and MonoDevelop. Both are available from the repositories.
Now, if you want to "create some C and C++ programs to interact with the linux API from [your] windows XP", You need, for example, to learn sockets and SSH; so you can connect to your Linux machine from your Windows machine and execute some commands remotely from your Windows applications. But before you do that, learn C/C++ and play around with Linux. For a newbie, you already have your hands full right there.
Good luck!
[1] Ubuntu (a Linux distribution) comes with Gnome as GUI, while Kubuntu with KDE and Xubuntu has XFCE. All of them (GUIs) are separate projects and you could have all of them installed on any Linux desktop installation. Even, you don't need any GUI with any Linux distribution; for example, VMWare's Virtual Appliance Marketplate have a whole bunch of ready-to-go Linux installations like that.
Try it with a VM or as a live-cd.
Valgrind is a command-line tool but maybe some IDEs use integrated it.
Under Linux you'll see, than most of the time an IDE is quite useless (not a troll).
You'll do your Makefile manually,...
Hope you'll enjoy' it.
Regards,
Learn 1 thing at a time.
If you want to learn to program first, try python first. It works in Windows and Linux and you get result faster
If you want to learn C++, get Visual C++ express or Cygwin/GCC
If you want to experience with Linux, get a distribution of your choice (Linux-Mint is a good introction, coming from Windows) and try it in a VM (VMWare Player or VirtualBox)
Try easy projects and only after that, worry about debuggers
If you try it in virtual machines (virtualbox or WMWare for example) you can test as many options you want before deciding what Linux distro you will want to use. There are a lot, but from what you listed, my personnal opinion is that Ubuntu is a lot easier than Fedora to start. I've never used RedHat so I can't tell but it hasn't the reputation of beeing a hard one (for experts).
Anyways, at least to start I recommend installing it with GUI (and after starting too unless it's a server...).
Regarding IDEs, you could try Eclipse and Netbeans. They run both on Windows and Linux but I'm not C/C++ programmer so I don't know if they are good at that job. I you don't use IDE, Vim is far from beeing the unique option (Vim "addicts" :) will say it is the unique productive one but that's a personnal choice and the learning time is not very short). Personnaly I prefer a good IDE or at least graphical editors for programming, not that I don't like the power and speed of the terminal with command line as I prefer to use it for system administration or configuration but not for programming where you stay a long time on it.
I don't know about Valgrind but Eclipse or Netbeans IDEs have debuggers of course.
Programming for Linux a series of projects to learn, for the steps, you may refer to:
Red Hat Certified System Administrator I &II student-book which may help you to get the survival abilities in Linux, actually when you really understand the fields covered by these courses, you will have got the ability to find what to learn.
Search amazon with keyword 'Linux Programming', choose one and start your journey.
Have a good time.
I am trying to setup a development environment for Linux C++ application. Because I'm limited to my laptop (vista) which provides essential office applications, I want to program and access email, word at the same time.
I'd prefer a local Windows IDE. SSH to a company linux server and using VI doesn't seem productive to me. Even using some IDE installed on the linux server doesn't seem good to me, because I can't do the work at home.
So does Eclipse CDT + MinGW work for me, or is there any other choice?
Thanks.
ZXH
Why not install a Linux virtual machine on your laptop, in VMware or similar? That way you can test while you're developing too.
You can also try http://cygwin.com/
Is it a GUI app? And do you have to target Linux specifically? If not, Qt (http://trolltech.com/) may be something that you can use. It would allow you to more or less develop your whole application on Windows, and then spend a few hours on a linux machine getting the whole thing ported...
Qt is the best choice. I develop with tis tool for a long time. And you can develop with the same ide : QtCreator and the same framework : Qt on MacOS, Linux based or Windows plateform...
Moreover, specifically on Linux, Qt is well integrated with Kdevelop !
If you have Visual Studio, which I feel is an excellent IDE, you can try to set it up to use GCC/G++. I've done this before, back in the Visual Studio 6 days. As long as you aren't using any Windows-specific libraries and write portable C++, you can compile and test on Windows, then periodically ensure that the code also compiles properly for Linux.
Another approach, one that I actually prefer, is to host your source and make files on the Linux box, share the files through Samba, then use your Windows IDE/text editor to edit those files. Then, you can do the compiling through an SSH terminal. Sure, you'd lose the convenience of being able to compile through your IDE, but at least you wouldn't have to muck around getting the compiler set up on Windows.
If you have a linux server available to you, you could also use NX to log in graphically, and use a Linux IDE there like Code::Blocks, or shudder Eclipse. Of course, there's nothing unproductive about shelling in and using VIM. I find it's a good way to shake out the IDE-induced cobwebs every now and again. Happy coding however you end up doing so!
I use (and recommend) Netbeans for C/C++ Development together with Cygwin to develop POSIX applications on Windows that will run on Linux/Solaris later on.
It is pretty easy to setup as long as you stick to the stable version of Cygwin.
I was in a similar position 2-3 years ago and tried several approaches, but the only one that really worked wor me was vim+ssh (+gdb, make, svn, etc). But again, I use vim even for Windows development.
This slideshow (PDF) walks through how to set up a cross compiler from Windows to Linux.