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 debuginfo gdb-gdb.py build without redhat-rpm-config and on RHEL-5.
Date: Sat, 27 Jun 2026 23:55:25 GMT	[thread overview]
Message-ID: <178260452586.1.8301857364968819921.rpms-gdb-e81f4701471f@fedoraproject.org> (raw)

            A new commit has been pushed.

            Repo   : rpms/gdb
            Branch : gdb-17.2-rebase-f44
            Commit : e81f4701471f7f01a83498ddf44ca80b575593c5
            Author : Jan Kratochvil <jan.kratochvil@redhat.com>
            Date   : 2012-02-21T20:05:03+01:00
            Stats  : +11/-6 in 1 file(s)
            URL    : https://src.fedoraproject.org/rpms/gdb/c/e81f4701471f7f01a83498ddf44ca80b575593c5?branch=gdb-17.2-rebase-f44

            Log:
            Fix debuginfo gdb-gdb.py build without redhat-rpm-config and on RHEL-5.

- Provide precompiled variants of gdb-gdb.py.

---
diff --git a/gdb.spec b/gdb.spec
index 6bb6b30..f93fff8 100644
--- a/gdb.spec
+++ b/gdb.spec
@@ -26,7 +26,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: 17%{?dist}
+Release: 18%{?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
@@ -1053,13 +1053,14 @@ do
   touch -r $RPM_BUILD_DIR/%{gdb_src}/gdb/ChangeLog $i
 done
 
-# RHEL-5: error: Installed (but unpackaged) file(s) found:
-#           /usr/lib/debug/usr/bin/gdb-gdb.pyc
-#           /usr/lib/debug/usr/bin/gdb-gdb.pyo
-%if 0%{!?el5:1}
+%if 0%{?_enable_debug_packages:1} && 0%{!?_without_python:1}
 mkdir -p $RPM_BUILD_ROOT/usr/lib/debug%{_bindir}
 cp -p $RPM_BUILD_DIR/%{gdb_src}/gdb/gdb-gdb.py $RPM_BUILD_ROOT/usr/lib/debug%{_bindir}/
-%endif # 0%{!?el5:1}
+for pyo in "" "-O";do
+  # RHEL-5: AttributeError: 'module' object has no attribute 'compile_file'
+  python $pyo -c 'import compileall, re, sys; sys.exit (not compileall.compile_dir("'"$RPM_BUILD_ROOT/usr/lib/debug%{_bindir}"'", 1, "'"/usr/lib/debug%{_bindir}"'"))'
+done
+%endif # 0%{?_enable_debug_packages:1} && 0%{!?_without_python:1}
 
 %if 0%{?rhel:1} && 0%{?rhel} <= 6
 %if 0%{!?_without_python:1}
@@ -1180,6 +1181,10 @@ fi
 %{_infodir}/gdb.info*
 
 %changelog
+* Tue Feb 21 2012 Jan Kratochvil <jan.kratochvil@redhat.com> - 7.4.50.20120120-18.fc17
+- Fix debuginfo gdb-gdb.py build without redhat-rpm-config and on RHEL-5.
+- Provide precompiled variants of gdb-gdb.py.
+
 * Mon Feb 13 2012 Jan Kratochvil <jan.kratochvil@redhat.com> - 7.4.50.20120120-17.fc17
 - gstack: Turn off --readnever (suggested by Oliver Henshaw).
 

                 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=178260452586.1.8301857364968819921.rpms-gdb-e81f4701471f@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