redhat.com logo go to redhat.com
Red Hat Developer Network:  White Paper

 

Chapter 1. Introduction

With the emergence of Linux as a viable computing platform, applications written for other Unix platforms are being ported to Linux. This guide will help you do this task. The focus is on porting applications from Solaris (in particular, on porting from Solaris running on 32-bit SPARC processors to Linux running on Intel IA-32 processors). However, if an application follows the standard programming interfaces, you can use this guide to port from other platforms.

Generally speaking, porting is quite simple. Because Solaris is a certified Unix implementation, it has passed the conformance tests of the Unix copyright holders. Linux is also designed with conformance to the Unix standard in mind. Although Linux has not undergone the conformance testing (due to the costs involved), chances are that if the programmer used only the set of interfaces covered by the Unix standard, you can reuse the code without any changes.

The porting problems that you can expect occur in several different areas:

  • You cannot port from some special versions of the Solaris OS, such as Trusted Solaris. There is not yet an equivalent to these special versions. However, as Sun has not updated these versions of the OS since version 2.5.1, it is not likely that you would be attempting such a port.

  • The tools used on the different platforms are different. As Sun does not develop tools for Linux, programmers who are using Sun's tools on Solaris have to switch their tools when doing the work on Linux. This can introduce additional problems beyond the differences in the use of the tools. The languages the compilers accept are slightly different (that is, they have different extensions on top of the base language).

  • The programming interfaces differ. While both operating systems are designed to follow standards, differences in the implementations and different states of the implementations are unavoidable. The programming environment is regulated by a common standard (POSIX.2), but there is still room for differences and extensions.

About this Guide

The following discussion is based on the 7.x series of the Red Hat Linux distribution. This series features the 2.4 version of the Linux kernel and the 2.2 version of the GNU C library. Comparisons with older versions of either package are not discussed in this paper. On the Solaris side, it is sufficient to discuss the latest version of the OS, Solaris 8.

Where useful, we discuss upcoming developments on the Linux side. When deficiencies in the Linux system are mentioned, take into account that the development of Linux proceeds very rapidly and the described deficiencies might already be solved. If a particular problem has not yet been solved, this need not prevent you from continuing. Because all of the core operating system is available under an Open Source license, you can either make appropriate changes yourself or contract out the changes. Red Hat's custom engineering services are available for such projects.