Solved

portability issues

Posted on 1998-08-31
8
342 Views
Last Modified: 2010-04-21
What are the issues of portability on Unix and NT?
 I want to make a my code portable on Unix as well as windows platform.
0
Comment
Question by:aeigo
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 3
  • 3
  • 2
8 Comments
 
LVL 4

Expert Comment

by:jlms
ID: 2006818
None, you can write code in UNIX and just recompile it in NT and it will run immediately and viceversa.
0
 

Author Comment

by:aeigo
ID: 2006819
one line answer
0
 
LVL 4

Accepted Solution

by:
jlms earned 0 total points
ID: 2006820
Well, what did you expect for 0 points???
0
Industry Leaders: We Want Your Opinion!

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

 

Author Comment

by:aeigo
ID: 2006821
Actually i didnt had any points I lost all in my first question
0
 
LVL 4

Expert Comment

by:jlms
ID: 2006822
Now about portability, well they are the obvious things:

The GUI is different, so you should isolate in different functions the routines to handle the user interface from whatever your program does.

The calls to the OS should be kept at a minimum, and when needed you have to isolate them, so you can include the adequate one.

Any possible hardware dependant functions should be treated similarly.

Be careful with the lenght of the word (32 bits? 64 bits?).


0
 
LVL 3

Expert Comment

by:braveheart
ID: 2006823
I could write a book on this topic.

Before we can help you, you will have to give us some details of the type of applications you are thinking of porting:

Which language(s) are you using?
Is it a single program or a complex system of intercommunicating modules?
Does it consist of lots of different components written in different languages or integrating lots of different tools?
Do you use a GUI?
Do you use an RDBMS?
Client/server architecture?
Will it have to run in a heterogeneous (mixed NT/UNIX) network?
Is it a single program or are their lots of communicating modules?
Is it single or multi-user?
Do you have any porting tools available?
Do you have any emulation libraries?
What platforms does your application(s) currently run on?
What platforms do you wish to port it to?
Do you have lots of money to spend?
Do you have lots of porting experience in house?

Well, those will do for starters.
0
 

Author Comment

by:aeigo
ID: 2006824
to
braveheart
I could write a book on this topic.

Here is some Information

language(s) used is  c++
Its a complex system of intercommunicating modules
Do you use a GUI?  No gui


Client/server architecture?  yes

Will it have to run in a heterogeneous (mixed NT/UNIX) network?
yes It has to run on Heterogenous Network.
Is it a single program or are their lots of communicating modules? Lots of communicating module
Is it single or multi-user?  Multiuser.
we are not porting previously built code. deeloping portable code
but we are developing a portable code.
Do you have any emulation libraries? no.
Do you have lots of money to spend? no .
Do you have lots of porting experience in house?no experience.


0
 
LVL 3

Expert Comment

by:braveheart
ID: 2006825
When designing an application that has to be portable between NT and UNIX, probably the most important consideration is the availability of equivalent libraries on both platforms. This is particularly true in the communications area.

Having no GUI makes porting easier as I presume that any communication with a user/controller will be via a text-only interface which will require very little massaging.

However, all your communication stuff is likely to be non-portable. You might like to look at the remote procedure call and external data representation functions on UNIX (man rpc, man xdr), assuming that there is an equivalent library available on NT (you may have to search the public domain for this). Note that these are not trivial to use but they will simplify problems of different sizes or byte order (endian-ness) of different data types on different machines.

If you are using raw TCP there may be libraries to help you. Perhaps GNU have something appropriate.

If you communicate by, or store information in files perhaps your network has shared disks, using "samba" or "PC-NFS" or something similar.  Is file locking between different processes or users an issue?

Your application sounds quite complex for people with no porting experience to tackle, especially if you have no money. Let's hope you have lots of time.
0

Featured Post

Free Tool: Port Scanner

Check which ports are open to the outside world. Helps make sure that your firewall rules are working as intended.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Title # Comments Views Activity
Unix / Linux grid computing 5 171
dot directory in FreeBSD??? 4 102
MarkLogic 1 117
Showing a username in UNIX and using that name in the script 4 71
A metadevice consists of one or more devices (slices). It can be expanded by adding slices. Then, it can be grown to fill a larger space while the file system is in use. However, not all UNIX file systems (UFS) can be expanded this way. The conca…
Introduction Regular patching is part of a system administrator's tasks. However, many patches require that the system be in single-user mode before they can be installed. A cluster patch in particular can take quite a while to apply if the machine…
Learn several ways to interact with files and get file information from the bash shell. ls lists the contents of a directory: Using the -a flag displays hidden files: Using the -l flag formats the output in a long list: The file command gives us mor…
Learn how to find files with the shell using the find and locate commands. Use locate to find a needle in a haystack.: With locate, check if the file still exists.: Use find to get the actual location of the file.:

732 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question