xref: /titanic_41/usr/src/lib/libshell/misc/buildksh93.readme (revision ff3124eff995e6cd8ebd8c6543648e0670920034)
1#
2# CDDL HEADER START
3#
4# The contents of this file are subject to the terms of the
5# Common Development and Distribution License (the "License").
6# You may not use this file except in compliance with the License.
7#
8# You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE
9# or http://www.opensolaris.org/os/licensing.
10# See the License for the specific language governing permissions
11# and limitations under the License.
12#
13# When distributing Covered Code, include this CDDL HEADER in each
14# file and include the License file at usr/src/OPENSOLARIS.LICENSE.
15# If applicable, add the following below this CDDL HEADER, with the
16# fields enclosed by brackets "[]" replaced with your own identifying
17# information: Portions Copyright [yyyy] [name of copyright owner]
18#
19# CDDL HEADER END
20#
21# Copyright 2007 Sun Microsystems, Inc.  All rights reserved.
22# Use is subject to license terms.
23#
24# ident	"%Z%%M%	%I%	%E% SMI"
25#
26
27#
28# buildksh93.readme
29#
30
31* Intro:
32"buildksh93.ksh" is a small build script used to build the AT&T "ast-ksh"
33and "ast-open" packages using its native (nmake-based) build system
34which is needed to build the iffe-generated (header) files (each time
35for { 32bit SPARC, 64bit SPARC, 32bit i386, 64bit AMD64 }) which are
36moved later to their matching OS/Net build directories.
37
38
39* Note that buildksh93.ksh modifies the build behaviour of the AST build
40system, including enforcing C99/XPG6 semantics (which is MANDATORY!!)
41and feeding additional libraries (like libnsl, libsocket, librt etc.)
42to the feature look system (called "iffe" (="if feature exists")) to
43ensure all features needed for the Solaris version of ksh93 are
44properly found.
45
46
47* Example usage of the script (more information can be found in the
48script itself):
49## Download AT&T ksh93 sources
50$ wget --http-user="I accept www.opensource.org/licenses/cpl" --http-passwd="." 'http://www.research.att.com/sw/download/beta/INIT.2007-04-18.tgz'
51$ wget --http-user="I accept www.opensource.org/licenses/cpl" --http-passwd="." 'http://www.research.att.com/sw/download/beta/ast-ksh.2007-04-18.tgz'
52
53## Unpack the sources (32bit SPARC):
54$ mkdir build32_sparc
55$ cd build32_sparc
56$ gunzip -c ../INIT.2007-03-28.tgz | tar -xf -
57$ gunzip -c ../ast-ksh.2007-03-28.tgz | tar -xf -
58
59## Build ast-ksh for 32bit SPARC (build other build flags are:
60# - "build.solaris.sparc.32bit.suncc" - 32bit SPARC
61# - "build.solaris.sparc.64bit.suncc" - 64bit SPARC
62# - "build.solaris.i386.32bit.suncc"  - 32bit x86/i386
63# - "build.solaris.i386.64bit.suncc"  - 64bit x86/AMD64
64# )
65$ time nice ksh ../buildksh93.ksh "build.solaris.sparc.32bit.suncc" 2>&1 | tee -a buildlog.log
66
67## Test ksh93
68$ time nice ksh ../buildksh93.ksh "testshell" 2>&1 | tee -a buildlog.log
69
70## Generated binaries and headers can be found in the arch/$(PLATFORM)/
71## subdirectory.
72
73
74# EOF.
75