| 227 |
dpurdie |
1 |
#
|
|
|
2 |
# Copyright (C) 1999-2002 ERG Limited, All rights reserved
|
|
|
3 |
#
|
|
|
4 |
# Module name: Makelib.pl
|
|
|
5 |
# Module type: Makefile system
|
|
|
6 |
#
|
|
|
7 |
# Description: rpcgen
|
|
|
8 |
#
|
|
|
9 |
# Version Who Date Description
|
|
|
10 |
# 1.0 APY 24/08/99 Created
|
|
|
11 |
#
|
|
|
12 |
# $Source: /cvsroot/device/NET/SRC/RPC40/RPCGEN/MAKEFILE.PL,v $
|
|
|
13 |
# $Revision: 1.3 $ $Date: 2002/04/30 07:15:20 $ $State: Exp $
|
|
|
14 |
# $Author: adamy $ $Locker: $
|
|
|
15 |
#...........................................................................
|
|
|
16 |
|
|
|
17 |
# exec build system
|
|
|
18 |
#
|
|
|
19 |
die "Usage: Makefile.pl rootdir Makelib.pl\n"
|
|
|
20 |
unless( $#ARGV+1 >= 2 );
|
|
|
21 |
require "$ARGV[1]";
|
|
|
22 |
|
|
|
23 |
# subdirectories to recurse (if any) and target platform(s),
|
|
|
24 |
# the following section(s) is called for each target ..
|
|
|
25 |
# eg SubDir('SUBDIR1', 'SUBDIR2');
|
|
|
26 |
#..
|
|
|
27 |
|
|
|
28 |
# build platform definitions ..
|
|
|
29 |
# eg Platform('P386', 'M68K');
|
|
|
30 |
#..
|
|
|
31 |
Platform( @BuildTools );
|
|
|
32 |
|
|
|
33 |
#.............................................................................
|
|
|
34 |
# Platforms definitions
|
|
|
35 |
#
|
|
|
36 |
|
|
|
37 |
# Build flags and paths:
|
|
|
38 |
# eg AddCFlags( '*', '-DDOSOMETIME' );
|
|
|
39 |
# AddIncDir( '*', '../INC' );
|
|
|
40 |
# AddSrcDir( '*', 'SUBDIR' );
|
|
|
41 |
#..
|
|
|
42 |
AddCFlags( '*', '-DEMBEDDED' );
|
|
|
43 |
|
|
|
44 |
AddIncDir( '*', '.' );
|
|
|
45 |
|
|
|
46 |
# Any new source types
|
|
|
47 |
# eg AddSourceType( '.xxx', '.asm' );
|
|
|
48 |
#..
|
|
|
49 |
#(none)
|
|
|
50 |
|
|
|
51 |
# Any source/headers etc
|
|
|
52 |
# eg Src( '*', 'Makefile.pl' [, ...] )
|
|
|
53 |
#..
|
|
|
54 |
Src( '*', 'Makefile.pl' );
|
|
|
55 |
Src( '*', 'rpc_type.h' );
|
|
|
56 |
Src( '*', 'rpc_pars.h' );
|
|
|
57 |
Src( '*', 'rpc_scan.h' );
|
|
|
58 |
Src( '*', 'rpc_util.h' );
|
|
|
59 |
Src( '*', 'rpc_clnt.c' );
|
|
|
60 |
Src( '*', 'rpc_cout.c' );
|
|
|
61 |
Src( '*', 'rpc_hout.c' );
|
|
|
62 |
Src( '*', 'rpc_main.c' );
|
|
|
63 |
Src( '*', 'rpc_pars.c' );
|
|
|
64 |
Src( '*', 'rpc_samp.c' );
|
|
|
65 |
Src( '*', 'rpc_scan.c' );
|
|
|
66 |
Src( '*', 'rpc_svco.c' );
|
|
|
67 |
Src( '*', 'rpc_tblo.c' );
|
|
|
68 |
Src( '*', 'rpc_util.c' );
|
|
|
69 |
Src( '*', 'rindex.c' );
|
|
|
70 |
|
|
|
71 |
# Files to be generated:
|
|
|
72 |
# eg Generate( 'P386', 'aa.cc', 'aa.h' );
|
|
|
73 |
#..
|
|
|
74 |
#(none)
|
|
|
75 |
|
|
|
76 |
# Addition rules:
|
|
|
77 |
# eg Rule( 'P386', "aa.h:\n" . "\tbuild aa.h" );
|
|
|
78 |
#..
|
|
|
79 |
#(none)
|
|
|
80 |
|
|
|
81 |
# Headers to be installed
|
|
|
82 |
# eg InstallHdr( '*', 'public.h' );
|
|
|
83 |
#..
|
|
|
84 |
#(none)
|
|
|
85 |
|
|
|
86 |
# Libraries to be made
|
|
|
87 |
# eg Lib( 'P386,M68K', 'lib', 'src1', 'src2', '-args' );
|
|
|
88 |
# Lib( '*', 'lib', @OBJS );
|
|
|
89 |
#..
|
|
|
90 |
#(none)
|
|
|
91 |
|
|
|
92 |
# Libraries to be installed into the 'export' lib directory:
|
|
|
93 |
# eg InstallLib( 'P386', 'lib' );
|
|
|
94 |
#..
|
|
|
95 |
#(none)
|
|
|
96 |
|
|
|
97 |
# Applications to be built
|
|
|
98 |
# eg Prog( ... )
|
|
|
99 |
#..
|
|
|
100 |
Prog( '*', 'rpcgen', @OBJS );
|
|
|
101 |
|
|
|
102 |
# Applications to be installed
|
|
|
103 |
# eg InstallProg( ... )
|
|
|
104 |
#..
|
|
|
105 |
#(none)
|
|
|
106 |
|
|
|
107 |
# Packaging installation
|
|
|
108 |
#..
|
|
|
109 |
#.. PackageHdr( 'P386', 'public.h', $Pinc, 'A' );
|
|
|
110 |
#.. PackageLib( 'P386', 'plib1', $Plib, 'A' );
|
|
|
111 |
#.. PackageProg( 'P386', 'prog1', $Pbin, 'A' );
|
|
|
112 |
|
|
|
113 |
#.............................................................................
|
|
|
114 |
# Finally generate the makefile
|
|
|
115 |
MakefileGenerate();
|