Home | Blog | Software | Reviews and Features | Forum | Help | Donate | About us
topbanner_forum
  *

avatar image

Welcome, Guest. Please login or register.
Did you miss your activation email?

Login with username, password and session length
  • December 04, 2016, 06:34:17 PM
  • Proudly celebrating 10 years online.
  • Donate now to become a lifetime supporting member of the site and get a non-expiring license key for all of our programs.
  • donate

Last post Author Topic: How to program for all 3 platforms at once  (Read 8240 times)

Ron88888

  • Supporting Member
  • Joined in 2007
  • **
  • default avatar
  • Posts: 7
    • View Profile
    • Donate to Member
How to program for all 3 platforms at once
« on: December 05, 2010, 11:51:49 AM »
I want to write desktop software that works on all three platforms (Windows, Mac, Linux). What is the best/easiest way to do that?

40hz

  • Supporting Member
  • Joined in 2007
  • **
  • Posts: 11,768
    • View Profile
    • Donate to Member
Re: How to program for all 3 platforms at once
« Reply #1 on: December 05, 2010, 12:35:37 PM »
Easiest? Java.  :)
« Last Edit: December 05, 2010, 12:40:59 PM by 40hz »

app103

  • That scary taskbar girl
  • Global Moderator
  • Joined in 2006
  • *****
  • Posts: 5,666
    • View Profile
    • App's Apps
    • Read more about this member.
    • Donate to Member
Re: How to program for all 3 platforms at once
« Reply #2 on: December 05, 2010, 12:46:23 PM »
Easiest for me would be Lasarus/freepascal. But that would require you to have access to all 3 platforms for compiling & testing. (write once and compile for anywhere)

Ron88888

  • Supporting Member
  • Joined in 2007
  • **
  • default avatar
  • Posts: 7
    • View Profile
    • Donate to Member
Re: How to program for all 3 platforms at once
« Reply #3 on: December 05, 2010, 02:59:32 PM »
Besides Java, how is it done in the real world? Is code written in C++ or C# for Windows, Objective C for Mac, and... I don't know what for (Li|U)nix? Sounds like a lot of extra work. How do people finesse it?

timns

  • Supporting Member
  • Joined in 2007
  • **
  • Posts: 1,211
    • View Profile
    • Donate to Member
Re: How to program for all 3 platforms at once
« Reply #4 on: December 05, 2010, 03:00:57 PM »
I want to write desktop software that works on all three platforms (Windows, Mac, Linux). What is the best/easiest way to do that?

Java. For a lot of reasons: stable, well supported, and some wonderful IDEs available. And for just about anything you need to do, there's already probably a class that can get you there.

Ron88888

  • Supporting Member
  • Joined in 2007
  • **
  • default avatar
  • Posts: 7
    • View Profile
    • Donate to Member
Re: How to program for all 3 platforms at once
« Reply #5 on: December 05, 2010, 03:02:08 PM »
Is it feasible to do this in Python or Ruby or some other scripting language? And, I'm guessing a core of code is written that can be easily carried over to another platform. True?

40hz

  • Supporting Member
  • Joined in 2007
  • **
  • Posts: 11,768
    • View Profile
    • Donate to Member
Re: How to program for all 3 platforms at once
« Reply #6 on: December 05, 2010, 03:37:01 PM »
Do what exactly? Certain tools are better for some things than others. What sort of project do you have in mind?

timns

  • Supporting Member
  • Joined in 2007
  • **
  • Posts: 1,211
    • View Profile
    • Donate to Member
Re: How to program for all 3 platforms at once
« Reply #7 on: December 05, 2010, 03:47:09 PM »
Is it feasible to do this in Python or Ruby or some other scripting language? And, I'm guessing a core of code is written that can be easily carried over to another platform. True?

It's a bit too much of a nebulous question. It totally depends on what you want to do - if you want to knock up some little web app that runs in any platform's browser, then sure. But if you want to create a bit more of a full-on true desktop application, you're going to have to move away from scripting. Especially if you have any type of performance requirements.

Ron88888

  • Supporting Member
  • Joined in 2007
  • **
  • default avatar
  • Posts: 7
    • View Profile
    • Donate to Member
Re: How to program for all 3 platforms at once
« Reply #8 on: December 05, 2010, 04:11:37 PM »
The application I have in mind will deal with a lot of XML, as in:

    * Create documents where the user's experience is as much like using a word processor as possible, but the user selects an xml tag/element, then types something in, then selects another tag, then types in some content, over and over;
    * the list of tags would appear in a pane, for selecting, generated from an xml schema (or other way of displaying the ontology);
    * displaying the document according to css would be nice;
    * facilitate uploading the resulting xml documents to a server;
    * and a way of "designing" xml tags, as needed in the moment, or as a major project.

Java may be a logical choice for this, but... I don't know Java.

And I've wondered about this topic in general, having most of my experience in web programming.

Deozaan

  • Charter Member
  • Joined in 2006
  • ***
  • Points: 1
  • Posts: 7,713
    • View Profile
    • The Blog of Deozaan
    • Read more about this member.
    • Donate to Member
Re: How to program for all 3 platforms at once
« Reply #9 on: December 05, 2010, 04:34:59 PM »
Isn't this the purported goal of Mono?


JavaJones

  • Review 2.0 Designer
  • Charter Member
  • Joined in 2005
  • ***
  • Posts: 2,717
    • View Profile
    • Donate to Member
Re: How to program for all 3 platforms at once
« Reply #10 on: December 05, 2010, 05:39:30 PM »
It sounds like one of the languages commonly used in web development (PHP, Python, etc.) would be appropriate for your needs, but note that this then requires either A: a web server to run the app installed on the user's system (you could bundle your own server if you want, but this would certainly need to be optional and lightweight) or B: running the app off a remote server that you host.

If you want something compiled natively for each platform, not running in a web browser, I think going the route of straight C/C++ and using a cross-platform UI library like Qt might be best. It depends also on which languages you do already know...

- Oshyan

timns

  • Supporting Member
  • Joined in 2007
  • **
  • Posts: 1,211
    • View Profile
    • Donate to Member
Re: How to program for all 3 platforms at once
« Reply #11 on: December 05, 2010, 06:04:28 PM »
Or why not use this as an opportunity to learn Java?  :Thmbsup:

Carol Haynes

  • Waffles for England (patent pending)
  • Global Moderator
  • Joined in 2005
  • *****
  • Posts: 7,986
    • View Profile
    • Dales Computer Services
    • Donate to Member
Re: How to program for all 3 platforms at once
« Reply #12 on: December 05, 2010, 06:56:40 PM »
Try www.realsoftware.com

Real Studio allows you to write one program and compile without modification for all three platforms.

It isn't free and you do need the Pro version to cross-compile for all three platforms. This means you can test applications on all three platforms but only compile and debug on the platform you purchased a license for.

The Enterprise version allows you install the complier on any of the three platforms with the same license code - and provided you stick to one license per user you can install it on as many machines as you want. This means you can cross compile and debug on any platform you choose.

There is also a web version (though it isn't final yet - but due for release any time now) which allows you to produce self contained compiled web applications. There are/will be restrictions on the PHP setup on the web server (requires FastCGI or sufficient rights to run applications on the server). Note this will be a standalone product but will be included with the Enterprise edition (and it supports iPhone and iPad).

There is a fairly active community and comprehensive documentation and third party books available. The compiler is updated regularly (usually 4+ times a year) on a subscription basis.

You can link it to various database engines, including MySQL.

Try out the 30 day trial - if you want to play more there is a cheaper personal edition (doesn't include all the database features and a few other bits are more limited).

Realsoftware also have an odd upgrade policy - basically if you buy a license for personal you can upgrade to pro or enterprise at any time. Upgrades extend your current subscription by 6 months. The cheapest way to get a long subscription on Pro or Enterprise is to buy as many years as you can afford on Personal and then upgrade - you get all your existing years plus six months with the upgrade which is much cheaper than renewing every year for the Enterprise package!

40hz

  • Supporting Member
  • Joined in 2007
  • **
  • Posts: 11,768
    • View Profile
    • Donate to Member
Re: How to program for all 3 platforms at once
« Reply #13 on: December 05, 2010, 07:54:36 PM »
@ Carol: RealStudio looks quite impressive. Reminds me of some other RAD platforms I've seen or used over the years.

Do you know how they handle redistribution of your developed applications? Do you need to purchase licenses or runtimes? Or is that covered when you purchase the Pro editions?


Carol Haynes

  • Waffles for England (patent pending)
  • Global Moderator
  • Joined in 2005
  • *****
  • Posts: 7,986
    • View Profile
    • Dales Computer Services
    • Donate to Member
Re: How to program for all 3 platforms at once
« Reply #14 on: December 06, 2010, 10:09:17 AM »
No - you can distribute applications without paying for licenses or runtimes. There are third party libraries available - not sure what the licensing is on them but on Real Basic the distribution is included with the license. Details on the website somewhere - try FAQs.

40hz

  • Supporting Member
  • Joined in 2007
  • **
  • Posts: 11,768
    • View Profile
    • Donate to Member
Re: How to program for all 3 platforms at once
« Reply #15 on: December 06, 2010, 10:34:44 AM »
@Carol: Thx. Found it. (They also respond to their email! :Thmbsup: How common a thing is that for a software company? Looking better and better already  8))
« Last Edit: December 06, 2010, 10:36:19 AM by 40hz »

Carol Haynes

  • Waffles for England (patent pending)
  • Global Moderator
  • Joined in 2005
  • *****
  • Posts: 7,986
    • View Profile
    • Dales Computer Services
    • Donate to Member
Re: How to program for all 3 platforms at once
« Reply #16 on: December 06, 2010, 04:57:56 PM »
I haven't done a huge amount with RealBasic yet but I have plans. They are pretty responsive to emails and there are active support forums.

Ron88888

  • Supporting Member
  • Joined in 2007
  • **
  • default avatar
  • Posts: 7
    • View Profile
    • Donate to Member
Re: How to program for all 3 platforms at once
« Reply #17 on: December 06, 2010, 06:17:46 PM »
Thanks everyone for your replies. Good stuff. Will look into it.

Does anyone have much experience with RealStudio?

40hz

  • Supporting Member
  • Joined in 2007
  • **
  • Posts: 11,768
    • View Profile
    • Donate to Member
Re: How to program for all 3 platforms at once
« Reply #18 on: December 06, 2010, 07:20:57 PM »
^ Just DL'ed the 30-day trial.

I'd be interested in hearing from anybody who uses it too.  :)

def

  • Participant
  • Joined in 2006
  • *
  • default avatar
  • Posts: 31
    • View Profile
    • Donate to Member
Re: How to program for all 3 platforms at once
« Reply #19 on: December 07, 2010, 01:50:09 PM »
The most interesting RealBasic/Real Studio feature is IMHO that one can compile standalone executables without having access to the other platforms (especially the Mac since I don't have one).

Are there other compilers or IDE's with such a feature?

Ron88888

  • Supporting Member
  • Joined in 2007
  • **
  • default avatar
  • Posts: 7
    • View Profile
    • Donate to Member
Re: How to program for all 3 platforms at once
« Reply #20 on: December 07, 2010, 02:41:32 PM »
I have zero experience with QT. This is what it says at their web site, qt.nokia.com

Write code once to target multiple platforms
Qt allows you to write advanced applications and UIs once, and deploy them across desktop and embedded operating systems without rewriting the source code saving time and development cost.

kyrathaba

  • N.A.N.Y. Organizer
  • Honorary Member
  • Joined in 2006
  • **
  • Posts: 3,120
    • View Profile
    • Donate to Member
Re: How to program for all 3 platforms at once
« Reply #21 on: December 13, 2010, 07:38:38 PM »
Hmm, I have some background with QuickBASIC, so I think I could pick up RealBASIC pretty easily.  Especially now that I have some OOP background with C#.  I'm just wondering if the cost would be worth it, to me personally.  It looks like you have to get at least the "Pro" version in order to be able to deploy to all three major platforms.  Not sure I want to layout the cash right now.  Carol, I'd be interested in hearing your impressions if you do pursue this avenue of development.

Carol Haynes

  • Waffles for England (patent pending)
  • Global Moderator
  • Joined in 2005
  • *****
  • Posts: 7,986
    • View Profile
    • Dales Computer Services
    • Donate to Member
Re: How to program for all 3 platforms at once
« Reply #22 on: December 14, 2010, 03:00:41 AM »
I have a copy of RB and have some plans. My biggest problem is finding the time. I've been really busy with work over the last few months and I have other things I have to do before I start spending time on RB. Bit of a catch 22 situation.

Deozaan

  • Charter Member
  • Joined in 2006
  • ***
  • Points: 1
  • Posts: 7,713
    • View Profile
    • The Blog of Deozaan
    • Read more about this member.
    • Donate to Member
Re: How to program for all 3 platforms at once
« Reply #23 on: December 14, 2010, 04:40:32 AM »
Another way to program for all 3 platforms at once is to use something like Adobe AIR, Flash, or javascript (web app that works offline).


kyrathaba

  • N.A.N.Y. Organizer
  • Honorary Member
  • Joined in 2006
  • **
  • Posts: 3,120
    • View Profile
    • Donate to Member
Re: How to program for all 3 platforms at once
« Reply #24 on: December 14, 2010, 09:35:57 AM »
I've heard Adobe AIR mentioned a lot lately.  What code does it use?  Java?