Follow Techotopia on Twitter

On-line Guides
All Guides
eBook Store
iOS / Android
Linux for Beginners
Office Productivity
Linux Installation
Linux Security
Linux Utilities
Linux Virtualization
Linux Kernel
System/Network Admin
Programming
Scripting Languages
Development Tools
Web Development
GUI Toolkits/Desktop
Databases
Mail Systems
openSolaris
Eclipse Documentation
Techotopia.com
Virtuatopia.com

How To Guides
Virtualization
General System Admin
Linux Security
Linux Filesystems
Web Servers
Graphics & Desktop
PC Hardware
Windows
Problem Solutions
Privacy Policy

  




 

 

Postfix Documentation
Previous Page Home Next Page

5 - Porting Postfix to an unsupported system

Each system type that Postfix knows is identified by a unique name. Examples: SUNOS5, FREEBSD4, and so on. When porting Postfix to a new system, the first step is to choose a SYSTEMTYPE name for the new system. You must use a name that includes at least the major version of the operating system (such as SUNOS4 or LINUX2), so that different releases of the same system can be supported without confusion.

Add a case statement to the "makedefs" shell script in the source code top-level directory that recognizes the new system reliably, and that emits the right system-specific information. Be sure to make the code robust against user PATH settings; if the system offers multiple UNIX flavors (e.g. BSD and SYSV) be sure to build for the native flavor, instead of the emulated one.

Add an "#ifdef SYSTEMTYPE" section to the central util/sys_defs.h include file. You may have to invent new feature macro names. Please choose sensible feature macro names such as HAS_DBM or FIONREAD_IN_SYS_FILIO_H.

I strongly recommend against using "#ifdef SYSTEMTYPE" in individual source files. While this may look like the quickest solution, it will create a mess when newer versions of the same SYSTEMTYPE need to be supported. You're likely to end up placing "#ifdef" sections all over the source code again.

Postfix Documentation
Previous Page Home Next Page