Makefile 2.7 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283
  1. # Copyright (C) 1991-2026 Free Software Foundation, Inc.
  2. # This file is part of the GNU C Library.
  3. # The GNU C Library is free software; you can redistribute it and/or
  4. # modify it under the terms of the GNU Lesser General Public
  5. # License as published by the Free Software Foundation; either
  6. # version 2.1 of the License, or (at your option) any later version.
  7. # The GNU C Library is distributed in the hope that it will be useful,
  8. # but WITHOUT ANY WARRANTY; without even the implied warranty of
  9. # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
  10. # Lesser General Public License for more details.
  11. # You should have received a copy of the GNU Lesser General Public
  12. # License along with the GNU C Library; if not, see
  13. # <https://www.gnu.org/licenses/>.
  14. #
  15. # Makefile for signal routines.
  16. #
  17. subdir := signal
  18. include ../Makeconfig
  19. headers := signal.h sys/signal.h \
  20. bits/signum-generic.h bits/signum-arch.h \
  21. bits/sigcontext.h bits/sigaction.h \
  22. bits/sigevent-consts.h bits/siginfo-consts.h \
  23. bits/sigstack.h bits/sigthread.h bits/ss_flags.h \
  24. bits/types/__sigset_t.h bits/types/sig_atomic_t.h \
  25. bits/types/sigevent_t.h bits/types/siginfo_t.h \
  26. bits/types/sigset_t.h bits/types/sigval_t.h \
  27. bits/types/stack_t.h bits/types/struct_sigstack.h \
  28. bits/types/__sigval_t.h bits/signal_ext.h \
  29. bits/sigstksz.h
  30. routines := signal raise killpg \
  31. sigaction libc_sigaction sigprocmask kill \
  32. sigpending sigsuspend sigwait \
  33. sigblock sigsetmask sigpause sigvec \
  34. sigstack sigaltstack sigintr \
  35. sigsetops sigempty sigfillset sigaddset sigdelset sigismem \
  36. sigreturn \
  37. siggetmask sysv_signal \
  38. sigisempty sigandset sigorset \
  39. allocrtsig sigtimedwait sigwaitinfo sigqueue \
  40. sighold sigrelse sigignore sigset
  41. tests := \
  42. tst-minsigstksz-1 \
  43. tst-minsigstksz-2 \
  44. tst-minsigstksz-3 \
  45. tst-minsigstksz-3a \
  46. tst-minsigstksz-4 \
  47. tst-minsigstksz-5 \
  48. tst-raise \
  49. tst-sigaction \
  50. tst-sigisemptyset \
  51. tst-signal \
  52. tst-sigset \
  53. tst-sigset2 \
  54. tst-sigsimple \
  55. tst-sigwait-eintr \
  56. # tests
  57. include ../Rules
  58. CFLAGS-raise.c += -fasynchronous-unwind-tables
  59. CFLAGS-sigpause.c += -fexceptions
  60. CFLAGS-sigsuspend.c += -fexceptions -fasynchronous-unwind-tables
  61. CFLAGS-sigtimedwait.c += -fexceptions -fasynchronous-unwind-tables
  62. CFLAGS-sigwait.c += -fexceptions -fasynchronous-unwind-tables
  63. CFLAGS-sigwaitinfo.c += -fexceptions -fasynchronous-unwind-tables
  64. CFLAGS-sigreturn.c += $(no-stack-protector)
  65. # We don't want to test the lazy resolution stack usage, just the
  66. # execution of the handler and the functions.
  67. LDFLAGS-tst-minsigstksz-1 = -Wl,-z,now
  68. LDFLAGS-tst-minsigstksz-2 = -Wl,-z,now
  69. LDFLAGS-tst-minsigstksz-3 = -Wl,-z,now
  70. LDFLAGS-tst-minsigstksz-3a = -Wl,-z,now
  71. LDFLAGS-tst-minsigstksz-4 = -Wl,-z,now