Summary: The GNU gdb debugger Name: gdb Version: 8.1.1 Release: 1 Copyright: GPL Group: Development/Tools URL: http://www.gnu.org/software/gdb/ Source0: http://ftp.gnu.org/gnu/gdb/%{name}-%{version}.tar.gz Source1: README-gdb%{version}-%{release}.ppc.aix #Patch0: gdb-%{version}-configure-disable_static_lib.patch Patch1: gdb-%{version}-aix-gcore.patch Patch2: gdb-%{version}-backtrace.patch Patch3: gdb-%{version}-hang_on_binary_sym.patch Patch4: gdb-%{version}-internal-error.patch Patch5: gdb-%{version}-large_binary_size_limit.patch Patch6: gdb-%{version}-mmap.patch Patch7: gdb-%{version}-qfuncsect_psymtab.patch Patch8: gdb-%{version}-sighandler-corrupt-stack.patch Patch9: gdb-%{version}-stack_size.patch Patch10: gdb-%{version}-traceback_table.patch Patch11: gdb-%{version}-vector.patch Patch12: gdb-%{version}-xlC-stabs.patch Patch13: gdb-%{version}-xlc_cpp-demagle.patch Patch14: gdb-%{version}-disable_dwtype.patch Patch15: gdb-%{version}-aix-gcore-libgen.patch Patch16: gdb-%{version}-disable_lang_check.patch Patch17: gdb-%{version}-mkdtemp.patch Patch18: gdb-%{version}-texinfo.patch Prefix: %{_prefix} #BuildRequires: bzip2 BuildRoot: %{_tmppath}/%{name}-root Prereq: /sbin/install-info Requires: AIX-rpm >= 5.1.0.0 Requires: expat >= 2.0.1-2 #Requires: gcc >= 6.3.0 %define DEFCC cc %description GNU gdb is the standard GNU program debugger. %prep %setup -q export patch=/opt/freeware/bin/patch #%patch0 -p1 -b .disable-static %patch1 -p1 -b .gcore %patch2 -p1 -b .backtrace %patch3 -p1 -b .bin_sym_hang %patch4 -p1 -b .internal_error %patch5 -p1 -b .large_bin_size %patch6 -p1 -b .mmap %patch7 -p1 -b .qfuncsect_psymtab %patch8 -p1 -b .sig_handle %patch9 -p1 -b .stack_size %patch10 -p1 -b .traceback_table %patch11 -p1 -b .vector %patch12 -p1 -b .xlC_stabs %patch13 -p1 -b .xlC_demangle %patch14 -p1 -b .dwtype %patch15 -p1 -b .libgen_gencore %patch16 -p1 -b .disable_lang_check %patch17 -p1 -b .mkdtemp %patch18 -p1 -b .texinfo %build export CC=gcc export CXX=g++ export AR="/usr/bin/ar" export AS="/usr/bin/as" export OBJECT_MODE=64 export CFLAGS="-maix64 -D_LARGE_FILES -D_ALL_SOURCE -DTUI=1 -Wall -Wpointer-arith -Wno-unused -Wunused-value -Wunused-function -Wno-switch -Wno-char-subscripts -Wempty-body -Wunused-but-set-parameter -Wunused-but-set-variable -Wno-sign-compare -Wno-write-strings -Wno-narrowing -Wformat-nonliteral -static-libstdc++ -static-libgcc" export CXXFLAGS="-maix64 -D_LARGE_FILES -D_ALL_SOURCE -DTUI=1 -Wall -Wpointer-arith -Wno-unused -Wunused-value -Wunused-function -Wno-switch -Wno-char-subscripts -Wempty-body -Wunused-but-set-parameter -Wunused-but-set-variable -Wno-sign-compare -Wno-write-strings -Wno-narrowing -Wformat-nonliteral -fpermissive -static-libstdc++ -static-libgcc" export LIBPATH=/opt/freeware/lib:/usr/lib:$LIBPATH export LDFLAGS="-lC -lpthread -Wl,-blibpath:/opt/freeware/lib64:/opt/freeware/lib:/usr/lib:/lib" ./configure --prefix=/opt/freeware \ --infodir=/opt/freeware/info \ --mandir=/opt/freeware/man \ --disable-werror \ --enable-sim \ --target=powerpc64-ibm-aix6.1.0.0 \ --build=powerpc64-ibm-aix6.1.0.0 \ --with-mpfr=no \ --with-mpc=no gmake %{?_smp_mflags} cp ${RPM_SOURCE_DIR}/README-gdb%{version}-%{release}.ppc.aix README-gdb%{version}-%{release}.ppc.aix %install rm -rf $RPM_BUILD_ROOT gmake DESTDIR=${RPM_BUILD_ROOT} install mkdir -p ${RPM_BUILD_ROOT}/usr/linux/lib #cp /usr/lib/libC.a ${RPM_BUILD_ROOT}/usr/linux/lib/libC.a_bak #cp /usr/lib/libC.a ${RPM_BUILD_ROOT}/usr/linux/lib/libC.a # Strip all of the executables /usr/bin/strip ${RPM_BUILD_ROOT}%{prefix}/bin/* 2>/dev/null || : # compress the info files gzip -9fn ${RPM_BUILD_ROOT}%{_infodir}/* # install the gcore script in /usr/bin #cp ./gdb/gdb_gcore.sh ${RPM_BUILD_ROOT}%{prefix}/bin/gcore #chmod 755 ${RPM_BUILD_ROOT}%{prefix}/bin/gcore # Create links into /usr/bin and /usr/linux/bin. ( cd $RPM_BUILD_ROOT mkdir -p usr/bin cd usr/bin ln -sf ../..%{prefix}/bin/* . ) %clean rm -rf $RPM_BUILD_ROOT %post /sbin/install-info %{_infodir}/annotate.info.gz %{_infodir}/dir #/sbin/install-info %{_infodir}/bfd.info.gz %{_infodir}/dir /sbin/install-info %{_infodir}/gdb.info.gz %{_prefix}/dir /sbin/install-info %{_infodir}/stabs.info.gz %{_prefix}/dir #mv /usr/linux/lib/libC.a_bak /usr/linux/lib/libC.a %preun #mv /usr/linux/lib/libC.a /usr/linux/lib/libC.a_bak %postun if [ $1 = 0 ] ; then /sbin/install-info --delete %{_infodir}/annotate.info.gz %{_infodir}/dir #/sbin/install-info --delete %{_infodir}/bfd.info.gz %{_infodir}/dir /sbin/install-info --delete %{_infodir}/gdb.info.gz %{_prefix}/dir /sbin/install-info --delete %{_infodir}/stabs.info.gz %{_prefix}/dir fi %files %defattr(-,bin,bin) %doc COPYING COPYING.LIB README README-gdb%{version}-%{release}.ppc.aix %{_mandir}/man1/* %{_mandir}/man5/* %{prefix}/bin/* #/usr/linux/lib/libC.a_bak #/usr/linux/lib/libC.a %{_infodir}/annotate.info.gz %{_infodir}/gdb* #%{_infodir}/bfd* %{_infodir}/stabs.info.gz /usr/bin/* %changelog * Sun Oct 07 2018 Nitish K Mishra 8.1.1-1 - Initial Port to version 8.1.1-1 * Thu Jun 28 2018 Nitish K Mishra 7.12.1-2 - Fix for dwarf support * Wed May 17 2017 Nitish K Mishra 7.12.1-1 - Update to 7.12.1-1 * Wed May 3 2017 Sangamesh Mallayya 7.9.1-7 - Add changes to signal handler patch to display register contents - if stack address is corrupted. * Thu Feb 6 2017 Sangamesh Mallayya 7.9.1-6 - Add gcore support. - Add vector support. * Thu Apr 09 2016 Sangamesh Mallayya 7.9.1-4 - Add fix to read stack size larger than int limit. - Add fix to read signal hanlder frame during core analysis. - Add temporary fix for hang when gdb tries to look for binary_function symbol. * Thu Feb 11 2016 Sangamesh Mallayya 7.9.1-3 - Add multiple fixes. - Prevent core dumping in case of unrecognized xlc++ stab symbols V & m. - Do not skip the xlc++ symbols which start with $_. - Add a support to read the very large binary of size around 5GB. - Use xlc++ demangling API for C++ functions. - Displaying the entire stack traces for the binaries where stwu instruction to update - the stack frame wasn't being read by gdb. - Prevent GDB internal error. * Thu Dec 18 2015 Sangamesh Mallayya 7.9.1-2 - Rewrite a sysroot path to recognise .so files. * Thu Nov 26 2015 Sangamesh Mallayya 7.9.1-2 - Add a fix to recognise sysroot path. * Thu Oct 29 2015 Sangamesh Mallayya 7.9.1-1 - Update to 7.9.1. Apply the patches which didn't make it to the community yet. * Fri Dec 6 2013 Raunaq Bathija 7.5-7 - Add support for debugging core files generated by binaries in Large Memory model. * Mon Oct 28 2013 Raunaq Bathija 7.5-6 - Improve xlC++ stabstring support. - Add Fix to correctly read psymtab in case of xlc -qfuncsecct compiled binaries. - Include README file specific to AIX related changes in the doc section. * Wed Aug 14 2013 Raunaq Bathija 7.5-5 - Add partial xlC++ stabstring support to recognize c++ data types better. * Wed Jul 3 2013 Raunaq Bathija 7.5-4 - Modify aix-thread and inf-ptrace patch to remove multiple #ifdef - Add mmap command to gdb * Wed Apr 3 2013 Raunaq Bathija 7.5-3 - Remove changes from generic files and make equivalent changes in AIX specific files. * Mon Feb 18 2013 Raunaq Bathija 7.5-2 - Modify the fix for setting breakpoints (mentioned initially in 7.5-1) - Add fix for proper listing of functions in an xlc compiled object. * Wed Jan 16 2013 Raunaq Bathija 7.5-1 - Update gdb version to 7.5 - Modify the fix for stopping at first executable statement of functions. - Add a fix for setting breakpoints properly instead of multiple entries. * Tue Jun 26 2012 Sangamesh Mallayya 7.3-5 - Skip reading @FIX entries * Wed Mar 14 2012 Sangamesh Mallayya 7.3-4 - Add a fix for filename issue. If -qfuncsect compiler option is - used then gdb is displays filename as _start_. - Add a fix for proper address relocation for core dump. * Mon Feb 06 2012 Sangamesh Mallayya 7.3-3 - Add fix for stopping at first executable statement of a functions. * Thu Dec 01 2011 Sangamesh Mallayya 7.3-2 - Add fix for Internal Error issue in case of -qfuncsect xlc option. * Fri Nov 11 2011 Sangamesh Mallayya 7.3-1 - Build 64-bit version (alpha) * Thu Sep 23 2004 David Clissold 6.0-1 - Initial version, adopted from old GNUPro.spec (which included an older gdb).