Is there such a thing as PERL portability checklist ...

M

martin

Hi, I have read the group collecting bits and pieces of information
about the topic that I am doing this post on. However I failed to find
the sort of comprehensive information I am looking, hence my posting
now. Imagine you had a perl script that you had inherited and you
needed to ensure it is portable across a variety of platforms/OSs.

My question or rather questions are:

1- Is there a checklist available somewhere to use as a guideline in
assessing portability of the code.This could be a known inventory of
portability guidelines.
2- Are there any known non-portable constructs listed somewhere that
one could use as a basis for checking the code against? This could be
even some perl built in functions or constructs that are non-portable.
3- what is the highest priority items to check for?
4- what kind of key questions one needs to ask, what kind of
information to collect about platform,OS, ...?


Well, this could be a tall order,but I thought it would be nice to know
how some of the experts would go about this task and what methodologuy
they would adopt to get the most done in the least amount of time.

Any information is greatly appreciated. Thanks. Martin
 
M

Mumia W.

martin said:
[...]
1- Is there a checklist available somewhere to use as a guideline in
assessing portability of the code.This could be a known inventory of
portability guidelines. [...]

First, try "man perlport" and "man File::Spec"

Off the top of my head, I can think of these things that would hurt
portability:
* the use of system commands rather than perl modules (e.g. unix find
vs. File::Find)
* assuming the path separator is '/' or '\\'
* assuming the locations of things on the filesystem
* using proprietary libraries
 
P

Peter J. Holzer

Mumia said:
Off the top of my head, I can think of these things that would hurt
portability:
* the use of system commands rather than perl modules (e.g. unix find
vs. File::Find)
* assuming the path separator is '/' or '\\'
* assuming the locations of things on the filesystem
* using proprietary libraries

* assuming a file is a stream of bytes

hp
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

Forum statistics

Threads
473,744
Messages
2,569,483
Members
44,902
Latest member
Elena68X5

Latest Threads

Top