1# $NetBSD: Makefile.inc,v 1.185 2012/11/03 19:39:21 christos Exp $ 2# from: @(#)Makefile.inc 8.6 (Berkeley) 5/4/95 3 4# gen sources 5.if defined(__MINIX) 6.PATH: ${.CURDIR}/gen/minix 7.endif # defined(__MINIX) 8.PATH: ${ARCHDIR}/gen ${.CURDIR}/gen 9 10.if defined(__MINIX) 11# Unsupported by Minix. 12# closefrom.c confstr.c extattr.c getdevmajor.c \ 13# pthread_atfork.c setdomainname.c sethostname.c setproctitle.c \ 14# sysctl.c sysctlbyname.c sysctlgetmibinfo.c sysctlnametomib.c \ 15# wait3.c 16 17# To be ported 18# nlist.c nlist_aout.c nlist_coff.c nlist_ecoff.c nlist_elf32.c nlist_elf64.c 19# 20# Not useful but portable 21# disklabel.c 22 23SRCS+= _errno.c alarm.c alphasort.c arc4random.c assert.c basename.c clock.c \ 24 closedir.c \ 25 ctermid.c ctype_.c daemon.c \ 26 dehumanize_number.c devname.c dirname.c err.c errx.c \ 27 errlist.c errno.c execl.c execle.c execlp.c execv.c execvp.c \ 28 fmtcheck.c fmtmsg.c fnmatch.c fstab.c ftok.c \ 29 fts.c ftw.c getbsize.c getcap.c getcwd.c \ 30 getdomainname.c getgrent.c \ 31 getgrouplist.c getgroupmembership.c gethostname.c \ 32 getloadavg.c getlogin.c getmntinfo.c \ 33 getnetgrent.c getpagesize.c \ 34 getpass.c getprogname.c getpwent.c getttyent.c \ 35 getusershell.c glob.c humanize_number.c initdir.c initgroups.c \ 36 isascii.c isatty.c isctype.c lockf.c nftw.c \ 37 nice.c \ 38 opendir.c pause.c popen.c \ 39 psignal.c \ 40 ptree.c pwcache.c pw_scan.c raise.c randomid.c rb.c readdir.c \ 41 rewinddir.c scandir.c seekdir.c \ 42 setjmperr.c setmode.c setprogname.c \ 43 shquote.c shquotev.c sighold.c sigignore.c siginterrupt.c \ 44 sysctl.c sysctlbyname.c sysctlgetmibinfo.c sysctlnametomib.c \ 45 siglist.c signal.c signame.c sigrelse.c \ 46 sigset.c sigsetops.c sleep.c \ 47 stringlist.c sysconf.c \ 48 syslog.c telldir.c time.c \ 49 times.c toascii.c tolower_.c ttyname.c ttyslot.c toupper_.c ualarm.c \ 50 ulimit.c uname.c unvis.c usleep.c utime.c utimens.c utmp.c \ 51 utmpx.c valloc.c vis.c wait.c waitpid.c warn.c warnx.c \ 52 vwarn.c vwarnx.c verr.c verrx.c wordexp.c 53.endif 54 55# indirect reference stubs, to be removed soon. 56SRCS+= _err.c _errx.c \ 57 _sysconf.c _verr.c _verrx.c _vwarn.c _vwarnx.c _warn.c _warnx.c 58 59# uses alloca 60COPTS.execvp.c = -Wno-stack-protector 61COPTS.execl.c = -Wno-stack-protector 62COPTS.execle.c = -Wno-stack-protector 63COPTS.execlp.c = -Wno-stack-protector 64COPTS.syslog.c = -Wno-format-nonliteral 65 66# machine-dependent gen sources 67# m-d Makefile.inc must include sources for: 68# _setjmp() bswap16() bswap32() bswap64() fabs() infinity 69# isinf() setjmp() sigsetjmp() 70 71.include "${ARCHDIR}/gen/Makefile.inc" 72 73MAN+= alarm.3 arc4random.3 basename.3 bswap.3 clock.3 closefrom.3 \ 74 confstr.3 \ 75 cpuset.3 ctermid.3 ctype.3 daemon.3 devname.3 directory.3 dirname.3 \ 76 endutxent.3 err.3 exec.3 extattr_copy_file.3 extattr_namespace_to_string.3 \ 77 fmtcheck.3 fmtmsg.3 fnmatch.3 fpclassify.3 fpgetmask.3 \ 78 ftok.3 fts.3 ftw.3 \ 79 getbsize.3 cgetcap.3 getcwd.3 getdevmajor.3 \ 80 getdomainname.3 getdiskbyname.3 getfsent.3 \ 81 getgrent.3 getgrouplist.3 gethostname.3 getlastlogx.3 getloadavg.3 \ 82 getmntinfo.3 getnetgrent.3 getpagesize.3 getpass.3 \ 83 getprogname.3 getpwent.3 getttyent.3 getusershell.3 glob.3 \ 84 humanize_number.3 \ 85 initgroups.3 isalnum.3 isalpha.3 isascii.3 isblank.3 iscntrl.3 \ 86 isdigit.3 isfinite.3 isgraph.3 isgreater.3 isinf.3 islower.3 isnan.3 \ 87 isnormal.3 isprint.3 ispunct.3 isspace.3 isupper.3 isxdigit.3 \ 88 lockf.3 _lwp_makecontext.3 makecontext.3 \ 89 nice.3 nlist.3 \ 90 pause.3 popen.3 \ 91 posix_spawn.3 posix_spawn_file_actions_addopen.3 \ 92 posix_spawn_file_actions_init.3 posix_spawnattr_getflags.3 \ 93 posix_spawnattr_getpgroup.3 posix_spawnattr_getschedparam.3 \ 94 posix_spawnattr_getschedpolicy.3 posix_spawnattr_init.3 \ 95 posix_spawnattr_getsigdefault.3 posix_spawnattr_getsigmask.3 \ 96 psignal.3 pwcache.3 pthread_atfork.3 \ 97 raise.3 randomid.3 realpath.3 scandir.3 setjmp.3 setmode.3 \ 98 setproctitle.3 shquote.3 sighold.3 sigignore.3 siginterrupt.3 \ 99 signal.3 signbit.3 sigrelse.3 sigset.3 sigsetops.3 sleep.3 \ 100 stringlist.3 sysconf.3 sysctl.3 syslog.3 time.3 times.3 \ 101 timezone.3 toascii.3 tolower.3 toupper.3 ttyname.3 \ 102 ualarm.3 ulimit.3 uname.3 unvis.3 usleep.3 utime.3 valloc.3 vis.3 \ 103 wordexp.3 104 105MLINKS+=bswap.3 bswap16.3 bswap.3 bswap32.3 bswap.3 bswap64.3 106MLINKS+=cpuset.3 cpuset_create.3 cpuset.3 cpuset_destroy.3 \ 107 cpuset.3 cpuset_zero.3 cpuset.3 cpuset_set.3 cpuset.3 cpuset_clr.3 \ 108 cpuset.3 cpuset_isset.3 cpuset.3 cpuset_size.3 109MLINKS+=directory.3 closedir.3 directory.3 dirfd.3 directory.3 opendir.3 \ 110 directory.3 readdir.3 directory.3 readdir_r.3 directory.3 \ 111 rewinddir.3 directory.3 seekdir.3 directory.3 telldir.3 \ 112 directory.3 fdopendir.3 113MLINKS+=endutxent.3 getutxent.3 endutxent.3 getutxid.3 \ 114 endutxent.3 getutxline.3 endutxent.3 pututxline.3 \ 115 endutxent.3 setutxent.3 116MLINKS+=err.3 verr.3 err.3 errx.3 err.3 verrx.3 err.3 warn.3 err.3 vwarn.3 \ 117 err.3 warnx.3 err.3 vwarnx.3 118MLINKS+=exec.3 execl.3 exec.3 execle.3 exec.3 execlp.3 exec.3 execv.3 \ 119 exec.3 execvp.3 exec.3 exect.3 120MLINKS+=extattr_namespace_to_string.3 extattr_string_to_namespace.3 \ 121 extattr_copy_file.3 extattr_copy_fd.3 \ 122 extattr_copy_file.3 extattr_copy_link.3 \ 123 extattr_copy_file.3 cpxattr.3 \ 124 extattr_copy_file.3 fcpxattr.3 \ 125 extattr_copy_file.3 lcpxattr.3 126MLINKS+=fpgetmask.3 fpgetround.3 fpgetmask.3 fpgetsticky.3 \ 127 fpgetmask.3 fpsetmask.3 fpgetmask.3 fpsetround.3 \ 128 fpgetmask.3 fpsetsticky.3 fpgetmask.3 fpgetprec.3 \ 129 fpgetmask.3 fpsetprec.3 130MLINKS+=fts.3 fts_open.3 fts.3 fts_read.3 fts.3 fts_children.3 \ 131 fts.3 fts_set.3 fts.3 fts_close.3 132MLINKS+=ftw.3 nftw.3 133MLINKS+=cgetcap.3 cgetclose.3 cgetcap.3 cgetent.3 \ 134 cgetcap.3 cgetfirst.3 cgetcap.3 cgetmatch.3 cgetcap.3 cgetnext.3 \ 135 cgetcap.3 cgetnum.3 cgetcap.3 cgetset.3 cgetcap.3 cgetstr.3 \ 136 cgetcap.3 cgetustr.3 137MLINKS+=getcwd.3 getwd.3 138MLINKS+=getpass.3 getpass_r.3 139MLINKS+=getpass.3 getpassfd.3 140MLINKS+=getdiskbyname.3 setdisktab.3 141MLINKS+=getdomainname.3 setdomainname.3 142MLINKS+=getfsent.3 endfsent.3 getfsent.3 getfsfile.3 getfsent.3 getfsspec.3 \ 143 getfsent.3 setfsent.3 144MLINKS+=getgrent.3 endgrent.3 getgrent.3 setgroupent.3 getgrent.3 getgrgid.3 \ 145 getgrent.3 getgrnam.3 getgrent.3 setgrent.3 146MLINKS+=getgrent.3 getgrgid_r.3 getgrent.3 getgrnam_r.3 getgrent.3 getgrent_r.3 147MLINKS+=getgrouplist.3 getgroupmembership.3 148MLINKS+=gethostname.3 sethostname.3 149MLINKS+=getlastlogx.3 getutmp.3 getlastlogx.3 getutmpx.3 150MLINKS+=getlastlogx.3 updlastlogx.3 getlastlogx.3 updwtmpx.3 151MLINKS+=getlastlogx.3 utmpxname.3 152MLINKS+=getnetgrent.3 endnetgrent.3 getnetgrent.3 innetgr.3 \ 153 getnetgrent.3 setnetgrent.3 154MLINKS+=getprogname.3 setprogname.3 155MLINKS+=getpwent.3 endpwent.3 getpwent.3 setpassent.3 getpwent.3 getpwnam.3 \ 156 getpwent.3 getpwuid.3 getpwent.3 setpwent.3 157MLINKS+=getpwent.3 getpwnam_r.3 getpwent.3 getpwuid_r.3 getpwent.3 getpwent_r.3 158# getpwent.3 setpwfile.3 - deprecated 159MLINKS+=getttyent.3 endttyent.3 getttyent.3 getttynam.3 \ 160 getttyent.3 setttyent.3 getttyent.3 setttyentpath.3 161MLINKS+=getusershell.3 endusershell.3 getusershell.3 setusershell.3 162MLINKS+=glob.3 globfree.3 163MLINKS+=glob.3 glob_pattern_p.3 164MLINKS+=humanize_number.3 dehumanize_number.3 165MLINKS+=makecontext.3 swapcontext.3 166MLINKS+=popen.3 pclose.3 167MLINKS+=posix_spawn.3 posix_spawnp.3 \ 168 posix_spawn_file_actions_addopen.3 posix_spawn_file_actions_addclose.3 \ 169 posix_spawn_file_actions_addopen.3 posix_spawn_file_actions_adddup2.3 \ 170 posix_spawn_file_actions_init.3 posix_spawn_file_actions_destroy.3 \ 171 posix_spawnattr_getflags.3 posix_spawnattr_setflags.3 \ 172 posix_spawnattr_getpgroup.3 posix_spawnattr_setpgroup.3 \ 173 posix_spawnattr_getschedparam.3 posix_spawnattr_setschedparam.3 \ 174 posix_spawnattr_getschedpolicy.3 posix_spawnattr_setschedpolicy.3 \ 175 posix_spawnattr_getsigdefault.3 posix_spawnattr_setsigdefault.3 \ 176 posix_spawnattr_getsigmask.3 posix_spawnattr_setsigmask.3 \ 177 posix_spawnattr_init.3 posix_spawnattr_destroy.3 178MLINKS+=psignal.3 sys_siglist.3 psignal.3 sys_signame.3 psignal.3 psiginfo.3 179MLINKS+=pwcache.3 user_from_uid.3 pwcache.3 group_from_gid.3 180MLINKS+=pwcache.3 uid_from_user.3 pwcache.3 gid_from_group.3 181MLINKS+=pwcache.3 pwcache_userdb.3 pwcache.3 pwcache_groupdb.3 182MLINKS+=randomid.3 randomid_new.3 randomid.3 randomid_delete.3 183MLINKS+=scandir.3 alphasort.3 184MLINKS+=setjmp.3 _longjmp.3 setjmp.3 _setjmp.3 setjmp.3 longjmp.3 \ 185 setjmp.3 longjmperror.3 setjmp.3 sigsetjmp.3 setjmp.3 siglongjmp.3 186MLINKS+=setmode.3 getmode.3 187MLINKS+=shquote.3 shquotev.3 188MLINKS+=sigsetops.3 sigemptyset.3 sigsetops.3 sigfillset.3 \ 189 sigsetops.3 sigaddset.3 sigsetops.3 sigdelset.3 \ 190 sigsetops.3 sigismember.3 191MLINKS+=stringlist.3 sl_init.3 stringlist.3 sl_free.3 stringlist.3 sl_add.3 \ 192 stringlist.3 sl_find.3 193MLINKS+=sysctl.3 sysctlbyname.3 sysctl.3 sysctlgetmibinfo.3 \ 194 sysctl.3 sysctlnametomib.3 195MLINKS+=syslog.3 closelog.3 syslog.3 openlog.3 syslog.3 setlogmask.3 \ 196 syslog.3 vsyslog.3 197MLINKS+=syslog.3 closelog_r.3 syslog.3 openlog_r.3 syslog.3 setlogmask_r.3 \ 198 syslog.3 syslog_r.3 syslog.3 vsyslog_r.3 199MLINKS+=syslog.3 syslogp.3 syslog.3 syslogp_r.3 \ 200 syslog.3 vsyslogp.3 syslog.3 vsyslogp_r.3 201MLINKS+=ttyname.3 isatty.3 ttyname.3 ttyslot.3 ttyname.3 ttyname_r.3 202MLINKS+=unvis.3 strunvis.3 unvis.3 strunvisx.3 203MLINKS+=unvis.3 strnunvis.3 unvis.3 strnunvisx.3 204MLINKS+=vis.3 svis.3 vis.3 strvis.3 vis.3 strvisx.3 vis.3 strsvis.3 \ 205 vis.3 strsvisx.3 vis.3 nvis.3 206MLINKS+=vis.3 snvis.3 vis.3 strnvis.3 vis.3 strnvisx.3 vis.3 strsnvis.3 \ 207 vis.3 strsnvisx.3 208 209CPPFLAGS.ctype_.c+= -I${LIBCDIR}/locale 210CPPFLAGS.isctype.c+= -I${LIBCDIR}/locale 211CPPFLAGS.tolower_.c+= -I${LIBCDIR}/locale 212CPPFLAGS.toupper_.c+= -I${LIBCDIR}/locale 213 214errlist.c: errlist.awk ${NETBSDSRCDIR}/sys/sys/errno.h 215.if defined(__MINIX) 216 ${TOOL_CAT} ${NETBSDSRCDIR}/sys/sys/errno.h | ${TOOL_SED} 's/(_SIGN//' | ${TOOL_AWK} -f ${NETBSDSRCDIR}/lib/libc/gen/errlist.awk > ${.TARGET} 217.else 218 ${TOOL_AWK} -f ${.ALLSRC} > ${.TARGET} 219.endif 220 221CLEANFILES+= errlist.c 222