This is a live mirror of the Perl 5 development currently hosted at https://github.com/perl/perl5
e9aa3e94c7bebd6618ed8cfc588e5ee65f93af59
[metaconfig.git] / U / modified / package.U
1 ?RCS: $Id: package.U 1 2006-08-24 12:32:52Z rmanfredi $
2 ?RCS:
3 ?RCS: Copyright (c) 1991-1997, 2004-2006, Raphael Manfredi
4 ?RCS: 
5 ?RCS: You may redistribute only under the terms of the Artistic Licence,
6 ?RCS: as specified in the README file that comes with the distribution.
7 ?RCS: You may reuse parts of this distribution only within the terms of
8 ?RCS: that same Artistic Licence; a copy of which may be found at the root
9 ?RCS: of the source tree for dist 4.0.
10 ?RCS:
11 ?RCS: $Log: package.U,v $
12 ?RCS: Revision 3.0.1.3  1994/10/29  16:27:21  ram
13 ?RCS: patch36: beware of non-ascii character sets when translating case
14 ?RCS:
15 ?RCS: Revision 3.0.1.2  1993/11/10  17:37:02  ram
16 ?RCS: patch14: skip definition of spackage if not otherwise used
17 ?RCS:
18 ?RCS: Revision 3.0.1.1  1993/09/13  16:11:10  ram
19 ?RCS: patch10: added spackage, suitable for starting sentences
20 ?RCS:
21 ?RCS: Revision 3.0  1993/08/18  12:09:28  ram
22 ?RCS: Baseline for dist 3.0 netwide release.
23 ?RCS:
24 ?MAKE:package spackage: Nothing
25 ?MAKE:  -pick wipe $@ %<
26 ?S:package:
27 ?S:     This variable contains the name of the package being constructed.
28 ?S:     It is primarily intended for the use of later Configure units.
29 ?S:.
30 ?S:spackage:
31 ?S:     This variable contains the name of the package being constructed,
32 ?S:     with the first letter uppercased, i.e. suitable for starting
33 ?S:     sentences.
34 ?S:.
35 ?X: dist-4 has defined PACKAGE: here, which clashes with perly.h
36 ?X:  as package is a reserved keyword in perl
37 ?T:first last
38 : set package name
39 package='<PACKAGENAME>'
40 @if spackage
41 first=`echo $package | sed -e 's/^\(.\).*/\1/'`
42 last=`echo $package | sed -e 's/^.\(.*\)/\1/'`
43 ?X:
44 ?X: So early in the Configure script, we don't have ./tr set up and can't
45 ?X: include Tr in our dependency or that would create a cycle. Therefore,
46 ?X: we have to somehow duplicate the work done in Tr. That's life.
47 ?X:
48 case "`echo AbyZ | tr '[:lower:]' '[:upper:]' 2>/dev/null`" in
49 ABYZ) spackage=`echo $first | tr '[:lower:]' '[:upper:]'`$last;;
50 *) spackage=`echo $first | tr '[a-z]' '[A-Z]'`$last;;
51 esac
52 @end
53