[OpenIndiana-discuss] Porting an application to OpenIndiana.
Jason Long
hack3rcon at yahoo.com
Thu Feb 11 21:14:59 UTC 2021
Thank you so much.
Excuse me, can I send email to you?
On Thursday, February 11, 2021, 09:43:26 PM GMT+3:30, Alan Coopersmith <alan.coopersmith at oracle.com> wrote:
On 2/11/21 8:59 AM, Jason Long via openindiana-discuss wrote:
> Hello,
> If someone wants to porting an application from an operating system to another operating system, then he\she must rewrite that program from scratch?
No - most applications have a large amount of code that's specific to the
application itself which is operating system independent - for instance a
stock market application is going to have code for tracking changes in
stock prices or figuring out gains and losses that doesn't depend on the
OS in use; while a database is going to have things like SQL handling code
that doesn't change between platforms.
But applications also have a fair amount of code to interact with platform
interfaces to do things like network communications, read & write to disk
or other storage, display output, etc. If they're written in something
like Java or Python that provides it's own platform routines for that, to
hide the underlying OS details, then there may be very little work to port
to a new OS, unless they need functionality not provided by the platform.
If they're written in something else, without those platform routines,
such as C or C++, then the work may increase and how much depends on
the OS'es you are porting between. Porting from another platform in
the Unix family - Linux, BSD, AIX, etc. - will be much easier than
porting from Windows or MacOS, since a large amount of the OS
interfaces are the same between the Unixes - especially for the subset
defined in the POSIX standard. You can see this in the large amount of
open source software shipping already in OpenIndiana, where the same
source code for things such as vim, emacs, nano, Firefox, perl, python,
etc. is used on OpenIndiana as on BSD & Linux, with just some small
sections of the code which check for the OS and call the OS-specific
interfaces for that.
--
-Alan Coopersmith- alan.coopersmith at oracle.com
Oracle Solaris Engineering - https://blogs.oracle.com/alanc
More information about the openindiana-discuss
mailing list