1 # Copyright (C) 1991, 92, 93, 94, 95, 96, 97 Free Software Foundation, Inc.
2 # This file is part of the GNU C Library.
4 # The GNU C Library is free software; you can redistribute it and/or
5 # modify it under the terms of the GNU Library General Public License as
6 # published by the Free Software Foundation; either version 2 of the
7 # License, or (at your option) any later version.
9 # The GNU C Library is distributed in the hope that it will be useful,
10 # but WITHOUT ANY WARRANTY; without even the implied warranty of
11 # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
12 # Library General Public License for more details.
14 # You should have received a copy of the GNU Library General Public
15 # License along with the GNU C Library; see the file COPYING.LIB. If not,
16 # write to the Free Software Foundation, Inc., 59 Temple Place - Suite 330,
17 # Boston, MA 02111-1307, USA.
20 # Sub-makefile for POSIX portion of the library.
24 headers := sys/utsname.h sys/times.h sys/wait.h sys/types.h unistd.h \
25 glob.h regex.h wordexp.h fnmatch.h bits/types.h getopt.h \
26 bits/posix1_lim.h bits/posix2_lim.h bits/posix_opt.h \
27 bits/local_lim.h tar.h bits/utsname.h bits/confname.h \
28 bits/waitflags.h bits/waitstatus.h sys/unistd.h sched.h \
29 bits/sched.h re_comp.h wait.h
31 distribute := confstr.h TESTS TESTS2C.sed testcases.h
36 wait waitpid wait3 wait4 \
37 alarm sleep pause nanosleep \
39 execve fexecve execv execle execl execvp execlp \
41 getuid geteuid getgid getegid getgroups setuid setgid group_member \
42 getpgid setpgid getpgrp bsd-getpgrp setpgrp getsid setsid \
43 getlogin getlogin_r setlogin \
44 pathconf sysconf fpathconf \
47 getopt getopt1 getopt_init \
48 sched_setp sched_getp sched_sets sched_gets sched_yield sched_primax \
49 sched_primin sched_rr_gi \
50 getaddrinfo gai_strerror
52 aux := init-posix environ
53 tests := tstgetopt testfnm runtests
55 install-bin := getconf
56 install-lib := libposix.a
57 gpl2lgpl := getopt.c getopt1.c getopt.h regex.c regex.h
59 before-compile := testcases.h
63 CFLAGS-regex.c = -Wno-unused -Wno-strict-prototypes
64 CFLAGS-getaddrinfo.c = -DRESOLVER
66 $(objpfx)libposix.a: $(dep-dummy-lib); $(make-dummy-lib)
67 lib: $(objpfx)libposix.a
69 testcases.h: TESTS TESTS2C.sed
70 sed -f TESTS2C.sed < $< > $@T
72 test ! -d CVS || cvs commit -mRegenerated $@
74 # Make the standalone glob/fnmatch package.
76 glob.tar: glob/ChangeLog glob/COPYING.LIB \
77 glob/Makefile.in glob/configure glob/configure.in glob/configure.bat\
78 glob/SCOPTIONS glob/SMakefile glob/Makefile.ami \
79 glob/fnmatch.h glob/glob.h glob/fnmatch.c glob/glob.c
80 tar cho$(verbose)f $@ $^
88 glob/configure: glob/configure.in
89 cd glob; autoconf $(ACFLAGS)
90 test ! -d CVS || cvs commit -m'Regenerated: autoconf $(ACFLAGS) $<' $@
92 glob/ChangeLog: ../ChangeLog
93 changelog-extract --regexp 'posix/(glob|fnmatch).*' < $< > $@.new
96 test ! -d CVS || cvs commit -mRegenerated $@
99 compress -c $< > $@-tmp
102 gzip -9v -c $< > $@-tmp