public inbox for git-commits@fedoraproject.org
help / color / mirror / Atom feed
From: Jan Kratochvil <jan.kratochvil@redhat.com>
To: git-commits@fedoraproject.org
Subject: [rpms/gdb] gdb-17.2-rebase-f44: Fix SELinux deny_ptrace .spec build rules (BZ 786878).
Date: Sat, 27 Jun 2026 23:55:31 GMT	[thread overview]
Message-ID: <178260453159.1.12697080380426411093.rpms-gdb-01b1870f188f@fedoraproject.org> (raw)

A new commit has been pushed.

Repo   : rpms/gdb
Branch : gdb-17.2-rebase-f44
Commit : 01b1870f188f50f8b605ebd4001722372ff965df
Author : Jan Kratochvil <jan.kratochvil@redhat.com>
Date   : 2012-03-09T19:11:09+01:00
Stats  : +98/-2 in 2 file(s)
URL    : https://src.fedoraproject.org/rpms/gdb/c/01b1870f188f50f8b605ebd4001722372ff965df?branch=gdb-17.2-rebase-f44

Log:
Fix SELinux deny_ptrace .spec build rules (BZ 786878).

---
diff --git a/gdb-attach-fail-reasons-5of5configure.patch b/gdb-attach-fail-reasons-5of5configure.patch
new file mode 100644
index 0000000..ea1b3fc
--- /dev/null
+++ b/gdb-attach-fail-reasons-5of5configure.patch
@@ -0,0 +1,89 @@
+--- 1/gdb/config.in	2012-03-09 18:40:28.001871023 +0100
++++ ./gdb/config.in	2012-03-09 18:41:46.552621113 +0100
+@@ -245,6 +245,9 @@
+ /* Define if librpm library is being used. */
+ #undef HAVE_LIBRPM
+ 
++/* Define to 1 if you have the `selinux' library (-lselinux). */
++#undef HAVE_LIBSELINUX
++
+ /* Define if libunwind library is being used. */
+ #undef HAVE_LIBUNWIND
+ 
+@@ -483,6 +486,9 @@
+ /* Define to 1 if you have the `sbrk' function. */
+ #undef HAVE_SBRK
+ 
++/* Define to 1 if you have the <selinux/selinux.h> header file. */
++#undef HAVE_SELINUX_SELINUX_H
++
+ /* Define to 1 if you have the `setlocale' function. */
+ #undef HAVE_SETLOCALE
+ 
+--- 1/gdb/configure	2012-03-09 18:40:28.183870443 +0100
++++ ./gdb/configure	2012-03-09 18:41:45.783623559 +0100
+@@ -15557,6 +15557,64 @@ $as_echo "#define HAVE_PERSONALITY 1" >>
+ 
+ fi
+ 
++for ac_header in selinux/selinux.h
++do :
++  ac_fn_c_check_header_mongrel "$LINENO" "selinux/selinux.h" "ac_cv_header_selinux_selinux_h" "$ac_includes_default"
++if test "x$ac_cv_header_selinux_selinux_h" = x""yes; then :
++  cat >>confdefs.h <<_ACEOF
++#define HAVE_SELINUX_SELINUX_H 1
++_ACEOF
++
++fi
++
++done
++
++{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for security_get_boolean_active in -lselinux" >&5
++$as_echo_n "checking for security_get_boolean_active in -lselinux... " >&6; }
++if test "${ac_cv_lib_selinux_security_get_boolean_active+set}" = set; then :
++  $as_echo_n "(cached) " >&6
++else
++  ac_check_lib_save_LIBS=$LIBS
++LIBS="-lselinux  $LIBS"
++cat confdefs.h - <<_ACEOF >conftest.$ac_ext
++/* end confdefs.h.  */
++
++/* Override any GCC internal prototype to avoid an error.
++   Use char because int might match the return type of a GCC
++   builtin and then its argument prototype would still apply.  */
++#ifdef __cplusplus
++extern "C"
++#endif
++char security_get_boolean_active ();
++int
++main ()
++{
++return security_get_boolean_active ();
++  ;
++  return 0;
++}
++_ACEOF
++if ac_fn_c_try_link "$LINENO"; then :
++  ac_cv_lib_selinux_security_get_boolean_active=yes
++else
++  ac_cv_lib_selinux_security_get_boolean_active=no
++fi
++rm -f core conftest.err conftest.$ac_objext \
++    conftest$ac_exeext conftest.$ac_ext
++LIBS=$ac_check_lib_save_LIBS
++fi
++{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_selinux_security_get_boolean_active" >&5
++$as_echo "$ac_cv_lib_selinux_security_get_boolean_active" >&6; }
++if test "x$ac_cv_lib_selinux_security_get_boolean_active" = x""yes; then :
++  cat >>confdefs.h <<_ACEOF
++#define HAVE_LIBSELINUX 1
++_ACEOF
++
++  LIBS="-lselinux $LIBS"
++
++fi
++
++
+ 
+ # Support for --with-sysroot is a copy of GDB_AC_WITH_DIR,
+ # except that the argument to --with-sysroot is optional.

diff --git a/gdb.spec b/gdb.spec
index 5927107..a144a7a 100644
--- a/gdb.spec
+++ b/gdb.spec
@@ -33,7 +33,7 @@ Version: 7.4.50.%{snap}
 
 # The release always contains a leading reserved number, start it at 1.
 # `upstream' is not a part of `name' to stay fully rpm dependencies compatible for the testing.
-Release: 29%{?dist}
+Release: 30%{?dist}
 
 License: GPLv3+ and GPLv3+ with exceptions and GPLv2+ and GPLv2+ with exceptions and GPL+ and LGPLv2+ and BSD and Public Domain
 Group: Development/Debuggers
@@ -559,6 +559,7 @@ Patch650: gdb-attach-fail-reasons-2of5.patch
 Patch651: gdb-attach-fail-reasons-3of5.patch
 Patch652: gdb-attach-fail-reasons-4of5.patch
 Patch653: gdb-attach-fail-reasons-5of5.patch
+Patch657: gdb-attach-fail-reasons-5of5configure.patch
 
 # Fix inferior calls, particularly uncaught thrown exceptions (BZ 799531).
 Patch654: gdb-x86-onstack.patch
@@ -579,7 +580,7 @@ BuildRequires: ncurses-devel%{?_isa} texinfo gettext flex bison expat-devel%{?_i
 # dlopen() no longer makes rpm-libs%{?_isa} (it's .so) a mandatory dependency.
 BuildRequires: rpm-devel%{?_isa}
 %endif # 0%{!?el5:1}
-BuildRequires: zlib-devel%{?_isa}
+BuildRequires: zlib-devel%{?_isa} libselinux-devel%{?_isa}
 %if 0%{!?_without_python:1}
 %if 0%{?el5:1}
 # This RHEL-5.6 python version got split out python-libs for ppc64.
@@ -850,6 +851,7 @@ rm -f gdb/jv-exp.c gdb/m2-exp.c gdb/objc-exp.c gdb/p-exp.c
 %patch651 -p1
 %patch652 -p1
 %patch653 -p1
+%patch657 -p1
 %patch654 -p1
 %patch655 -p1
 %patch656 -p1
@@ -1017,6 +1019,8 @@ perl -i.relocatable -pe 's/^(D\[".*_RELOCATABLE"\]=" )1(")$/${1}0$2/' gdb/config
 make %{?_smp_mflags} CFLAGS="$CFLAGS $FPROFILE_CFLAGS" LDFLAGS="$FPROFILE_CFLAGS"
 
 ! grep '_RELOCATABLE.*1' gdb/config.h
+grep '^#define HAVE_LIBSELINUX 1$' gdb/config.h
+grep '^#define HAVE_SELINUX_SELINUX_H 1$' gdb/config.h
 
 if [ "$fprofile" = "-fprofile" ]
 then
@@ -1319,6 +1323,9 @@ fi
 %endif # 0%{!?el5:1} || "%{_target_cpu}" == "noarch"
 
 %changelog
+* Fri Mar  9 2012 Jan Kratochvil <jan.kratochvil@redhat.com> - 7.4.50.20120120-30.fc17
+- Fix SELinux deny_ptrace .spec build rules (BZ 786878).
+
 * Tue Mar  6 2012 Jan Kratochvil <jan.kratochvil@redhat.com> - 7.4.50.20120120-29.fc17
 - Fix inferior calls, particularly uncaught thrown exceptions (BZ 799531).
 - Fix DWARF DIEs CU vs. section relative offsets (Joel Brobecker, me).

                 reply	other threads:[~2026-06-27 23:55 UTC|newest]

Thread overview: [no followups] expand[flat|nested]  mbox.gz  Atom feed

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=178260453159.1.12697080380426411093.rpms-gdb-01b1870f188f@fedoraproject.org \
    --to=jan.kratochvil@redhat.com \
    --cc=git-commits@fedoraproject.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox