File: BUILD

package info (click to toggle)
sformat 3.4-3.2
  • links: PTS
  • area: main
  • in suites: woody
  • size: 2,044 kB
  • ctags: 3,434
  • sloc: ansic: 20,882; makefile: 102; sh: 100
file content (162 lines) | stat: -rw-r--r-- 5,009 bytes parent folder | download | duplicates (8)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
Short overview for those who don't read manuals:

	You **need** either my "smake" program, the SunPRO make 
	from /usr/bin/make (SunOS 4.x) or /usr/ccs/bin/make (SunOS 5.x)
	or GNU make to compile this program.

	All other make programs are either not smart enough or have bugs.

	My "smake" is (in binary form) in the makefiles distribution 

	on: ftp://ftp.fokus.gmd.de/pub/unix/makefiles

	If you have the choice between all three make programs, the
	preference would be 

		1)	smake		(preferred)
		2)	SunPRO make
		3)	GNU make	(this is the last resort)

	Important notice: "smake" that comes with SGI/IRIX will not work!!!

	Please read the README's for your operating system too.

			WARNING
	Do not use 'mc' to extract the tar file!
	All mc versions before 4.0.14 cannot extract symbolic links correctly.

	To unpack an archive use:

		gzip -d < star.tar.gz | tar -xpf -

	Replace 'star' by the actual archive name.


Here comes the long form:

This program uses a new makefile system. The makefile system is optimized 
for a program called 'smake' Copyright 1985 by Jrg Schilling,
but SunPro make (the make program that comes with SunOS >= 4.0 and Solaris)
as well as newer versions of GNU make will work also.
BSDmake could be make working, if it supports pattern matching rules
correctly.

The makefile system allows simultaneous compilation on a wide
variety of target systems if the source tree is accessible via NFS.

To allow this, all binaries and results of a 'compilation' in any form
are placed in sub-directories. This includes automatically generated
include files. Results in general will be placed into
a directory named OBJ/<arch-name>/ in the current projects leaf directory,
libraries will be placed into a directory called libs/<arch-name>/ 
that is located in the source tree root directory.

<arch-name> will be something like 'sparc-sunos5-cc'

To compile a system or sub-system, simply enter smake, make or Gmake.
Compilation may be initialized at any point of the source tree of a
system. If compilation is started in a sub tree, all objects
in that sub tree will be made.
To install the product of a compilation in your system, call:

smake install

at top level. The binaries will usually be installed in /opt/schily/bin.
If you want to change this, edit the appropriate (system dependent) files
in the DEFAULTS directory.
The default C-compiler can be modified in the DEFAULT files too.

If you want to have a different compiler for one compilation,
call:

make CCOM=gcc
or
make CCOM=cc

For a list of targets call:

make .help

The man page makefiles.4 located in man/man4/makefiles.4 contains
the documentation on general use and for leaf makefiles.

The man page makerules.4 located in man/man4/makerules.4 contains
the documentation for system programmers who want to modify
the make rules of the makefile system.


Hints for compilation:

The makefile system is optimized for 'smake'. Smake will give the
fastest processing and best debugging output.

SunPro make will work as is. GNU make need some special preparation.

To use GNU make create a file called 'Gmake' in you search path
that contains:

#!/bin/sh
MAKEPROG=gmake
export MAKEPROG
exec gmake "$@"

and call 'Gmake' instead of gmake.

If you like to use 'smake', you may obtain a copy of the makefile
system. Various newer releases contain precompiled versions of 'smake'.
The packages are located on:

ftp://ftp.fokus.gmd.de/pub/unix/makefiles/

Precompiled binaries of 'smake' are located in bins/<arch-name>/smake
(e.g. bin/sparc-sunos5-cc/smake) of each package.

Smake has a -D flag to see the actual makefile source used
and a -d flag that gives easy to read debugging. Use smake -xM
to get a makefile dependency list. Try smake -help

The defaults found in the directory DEFAULTS are configured to
give minimum warnings. This is made because many people will
be irritated by warning messages and because the GNU c-compiler
will give warnings that are perfectly correct and portable c-code.

If you want to port code to new platforms or do engeneering
on the code, you should use the alternate set of defaults found
in the directory DEFAULTS_ENG.
You may do this permanently by renaming the directories or
for one compilation by calling:

make DEFAULTSDIR=DEFAULTS_ENG

If you like to compile with debugging information for dbx or gdb,
call:

make clean
make COPTX=-g LDOPTX=-g

If you want to see an example, please have a look at the "star"
source. It may be found on:

ftp://ftp.fokus.gmd.de/pub/unix/star

Have a look at the manual page, it is included in the distribution.
Install the manual page with 

make install first and include /opt/schily/man in your MANPATH

Note that some systems (e.g. Solaris 2.x) require you either to call
/usr/lib/makewhatis /opt/schily/man or to call 

man -F <man-page-name>

Author:

Joerg Schilling
Seestr. 110
D-13353 Berlin
Germany

Email: 	joerg@schily.isdn.cs.tu-berlin.de, js@cs.tu-berlin.de
	schilling@fokus.gmd.de

Please mail bugs and suggestions to me.