9 Replies - 630 Views - Last Post: 28 January 2012 - 06:03 AM Rate Topic: -----

Topic Sponsor:

#1 bitpupil  Icon User is offline

  • New D.I.C Head

Reputation: 0
  • View blog
  • Posts: 8
  • Joined: 25-January 12

Question on runtime environmentd

Posted 25 January 2012 - 08:05 AM

Hello coders. Am new to this site. I am a beginner programmer in Java. I have a shallow knowledge in other languages such as VB6, PHP and C++.( well i can right a program to add two numbers with these). My question is, Is there a programming language that can write and create an executable program that wont ask for a Run-time Environment from a machine it is to run on? VB asks the .Net Framework, Java programs ask for JRE to be installed etc. I would like my programs to be available to users who dont have these environments and arent able to install them because they might lack Admin rights t do so

Is This A Good Question/Topic? 0
  • +

Replies To: Question on runtime environmentd

#2 xclite  Icon User is offline

  • LIKE A BOSS
  • member icon


Reputation: 528
  • View blog
  • Posts: 2,536
  • Joined: 12-May 09

Re: Question on runtime environmentd

Posted 25 January 2012 - 10:43 AM

You can go with languages that compile to machine language, but they aren't guaranteed to run on machines with different architectures - they'd need to be compiled for the target machine.

Another option is javascript - nearly every computer has a browser than can interpret javascript or a webpage.
Was This Post Helpful? 0
  • +
  • -

#3 ishkabible  Icon User is offline

  • spelling expert
  • member icon



Reputation: 1139
  • View blog
  • Posts: 4,775
  • Joined: 03-August 09

Re: Question on runtime environmentd

Posted 25 January 2012 - 01:48 PM

ANSI C is really your only option(or translating another language to ANSI C) if you place that kind of constraint on yourself. C is the only language I can think of that has a compiler for virtual every architecture. If your going to avoid a runtime; your going to have to use a language compiled native code.

however; any language whose runtime can be compiled to ANSI C can also run on virtually any hardware. Lua for instance uses ANSI C so you could write the software in Lua and provide the lua runtime; the same goes for Java(but not all of it's libraries will work on all platforms but for major systems your fine)

This post has been edited by ishkabible: 25 January 2012 - 01:51 PM

Was This Post Helpful? 0
  • +
  • -

#4 bitpupil  Icon User is offline

  • New D.I.C Head

Reputation: 0
  • View blog
  • Posts: 8
  • Joined: 25-January 12

Re: Question on runtime environmentd

Posted 26 January 2012 - 10:09 AM

View Postxclite, on 25 January 2012 - 10:43 AM, said:

You can go with languages that compile to machine language, but they aren't guaranteed to run on machines with different architectures - they'd need to be compiled for the target machine.

Another option is javascript - nearly every computer has a browser than can interpret javascript or a webpage.


Ok. So when you say "different architectures", do you mean different operating systems?

I dont think javascript can do what i want to do. With it i can only make a program that runs in a browser. Furthermore, i dont think it can help create a GUI. I want the functionality and ability of VB or Java but with no requirements of an environment.






















/
Was This Post Helpful? 0
  • +
  • -

#5 bitpupil  Icon User is offline

  • New D.I.C Head

Reputation: 0
  • View blog
  • Posts: 8
  • Joined: 25-January 12

Re: Question on runtime environmentd

Posted 26 January 2012 - 10:32 AM

View Postishkabible, on 25 January 2012 - 01:48 PM, said:

ANSI C is really your only option(or translating another language to ANSI C) if you place that kind of constraint on yourself. C is the only language I can think of that has a compiler for virtual every architecture. If your going to avoid a runtime; your going to have to use a language compiled native code.

however; any language whose runtime can be compiled to ANSI C can also run on virtually any hardware. Lua for instance uses ANSI C so you could write the software in Lua and provide the lua runtime; the same goes for Java(but not all of it's libraries will work on all platforms but for major systems your fine)


Thanks for the reply. I suspected C or Assembly Language could be the answer to my query. However i wonder how good c is or how easily it can be used to create a GUI. My applications will definitely be GUI based.

IDM is a very popular application. It, for one, doesn't require any environment for it to be used. Is this because of the language used to create it or is it because some other process, similar to what you mentioned above, was used to make it not require any other environment? Please elaborate on this.
Was This Post Helpful? 0
  • +
  • -

#6 xclite  Icon User is offline

  • LIKE A BOSS
  • member icon


Reputation: 528
  • View blog
  • Posts: 2,536
  • Joined: 12-May 09

Re: Question on runtime environmentd

Posted 26 January 2012 - 10:48 AM

First, Javascript can be used to make a GUI - it interacts with web pages. If you're uncomfortable with making your application browser based and using HTML, then C is the best choice.


C works well for graphics, and there are several GUI libraries one can use.
Was This Post Helpful? 0
  • +
  • -

#7 ishkabible  Icon User is offline

  • spelling expert
  • member icon



Reputation: 1139
  • View blog
  • Posts: 4,775
  • Joined: 03-August 09

Re: Question on runtime environmentd

Posted 26 January 2012 - 04:57 PM

@OP: I think you need to reconsider your goals; I think sacrifice a bit on portability. D is a programing language much like C++ but with many of nice features of Java. It can run on all major systems(Linux, FreeBSD, Win32, Max OSX) and more. There is a front end for GCC so any target GCC can target D could also be targeted on in theory.

The reason to use C is for portability abd I don't believe you need that degree of portability.
Was This Post Helpful? 0
  • +
  • -

#8 bitpupil  Icon User is offline

  • New D.I.C Head

Reputation: 0
  • View blog
  • Posts: 8
  • Joined: 25-January 12

Re: Question on runtime environmentd

Posted 26 January 2012 - 09:52 PM

View Postxclite, on 26 January 2012 - 10:48 AM, said:

First, Javascript can be used to make a GUI - it interacts with web pages. If you're uncomfortable with making your application browser based and using HTML, then C is the best choice.


C works well for graphics, and there are several GUI libraries one can use.


Yeah. I want to write programs for windows. Which C compiler do you recommend and is it inclusive of the GUI libraries you speak of? I have the Pelles C for my 32bit system. Thank you so far.
Was This Post Helpful? 0
  • +
  • -

#9 ishkabible  Icon User is offline

  • spelling expert
  • member icon



Reputation: 1139
  • View blog
  • Posts: 4,775
  • Joined: 03-August 09

Re: Question on runtime environmentd

Posted 27 January 2012 - 07:59 AM

If you just using windows then your options are many; you can use almost anything(D, C++, a native Java code generator).

I like MinGW for a C compiler personally however.

have you considered a native Java compiler? I believe GJC compiles programs with no run time.

This post has been edited by ishkabible: 27 January 2012 - 08:00 AM

Was This Post Helpful? 0
  • +
  • -

#10 bitpupil  Icon User is offline

  • New D.I.C Head

Reputation: 0
  • View blog
  • Posts: 8
  • Joined: 25-January 12

Re: Question on runtime environmentd

Posted 28 January 2012 - 06:03 AM

View Postishkabible, on 27 January 2012 - 07:59 AM, said:

If you just using windows then your options are many; you can use almost anything(D, C++, a native Java code generator).

I like MinGW for a C compiler personally however.

have you considered a native Java compiler? I believe GJC compiles programs with no run time.


Thank you. I am currently downloading GCJ and JNC (as an alternative/backup). I will let you know if i succeed to do what i want with these.
Was This Post Helpful? 0
  • +
  • -

Page 1 of 1