]>
Commit | Line | Data |
---|---|---|
7566401a ER |
1 | # NOTE |
2 | # - Do not remove -lib package, it is required by FPC | |
3 | ||
4 | # TODO | |
a59c1d89 | 5 | # - change install msg to poldek in buildid-locate-rpm-pld.patch when poldek allows it. LP#493922 |
e1daef87 | 6 | # |
7566401a ER |
7 | # Conditional build: |
8 | %bcond_without python # build without python support | |
9 | ||
10 | %define snap 20090930 | |
41611023 | 11 | %define rel 0.6 |
5ff7d7dd | 12 | Summary: A GNU source-level debugger for C, C++ and Fortran |
0ec45698 ER |
13 | Summary(de.UTF-8): Symbolischer Debugger für C und andere Sprachen |
14 | Summary(es.UTF-8): Depurador de programas C y otras lenguajes | |
15 | Summary(fr.UTF-8): Débugger symbolique pour C et d'autres langages | |
16 | Summary(pl.UTF-8): Symboliczny odpluskwiacz dla C i innych języków | |
17 | Summary(pt_BR.UTF-8): Depurador de programas C e outras linguagens | |
18 | Summary(ru.UTF-8): Символический отладчик для C и других языков | |
19 | Summary(tr.UTF-8): C ve diğer diller için sembolik hata ayıklayıcı | |
20 | Summary(uk.UTF-8): Символьний відладчик для С та інших мов | |
21 | Summary(zh_CN.UTF-8): [开发]C和其他语言的调试器 | |
22 | Summary(zh_TW.UTF-8): [.-A開發]C和.$)B其.-A他語.$)B言的調試器 | |
0241102e | 23 | Name: gdb |
ab050a48 | 24 | Version: 7.0 |
8395e834 | 25 | Release: 0.9.fc12.%{rel} |
d7c2fd3d | 26 | License: GPL v3+ |
0241102e | 27 | Group: Development/Debuggers |
ab050a48 BZ |
28 | Source0: http://ftp.gnu.org/gnu/gdb/%{name}-%{version}.tar.bz2 |
29 | # Source0-md5: 3386a7b69c010785c920ffc1e9cb890a | |
31a43e77 | 30 | Source1: http://www.mif.pg.gda.pl/homepages/ankry/man-PLD/%{name}-non-english-man-pages.tar.bz2 |
feb56b14 | 31 | # Source1-md5: 2e8a48939ae282c12bbacdd54e398247 |
41611023 | 32 | Source3: %{name}-gstack.man |
7566401a ER |
33 | Source4: libstdc++-v3-python-r151798.tar.bz2 |
34 | # Source4-md5: 7507540c50a1edeb2fc22a37bc4a08b8 | |
049ba25c | 35 | |
bf594b18 | 36 | # FEDORA -- use the same numbering that they do |
a59c1d89 | 37 | # don't ever modify these patches, apply secondary patch to alter it pld way |
bf594b18 | 38 | # use:'<,'>!grep -vE '^(\#|$)' in vim to filterout comments, spaces |
8395e834 | 39 | |
049ba25c | 40 | Patch1: %{name}-6.3-rh-dummykfail-20041202.patch |
049ba25c | 41 | Patch2: %{name}-6.3-rh-testversion-20041202.patch |
049ba25c | 42 | Patch3: %{name}-6.3-rh-testlibunwind-20041202.patch |
049ba25c AM |
43 | Patch104: %{name}-6.3-ppcdotsolib-20041022.patch |
44 | Patch105: %{name}-6.3-ppc64syscall-20040622.patch | |
45 | Patch106: %{name}-6.3-framepczero-20040927.patch | |
46 | Patch111: %{name}-6.3-ppc64displaysymbol-20041124.patch | |
47 | Patch112: %{name}-6.6-scheduler_locking-step-sw-watchpoints2.patch | |
48 | Patch260: %{name}-6.6-scheduler_locking-step-is-default.patch | |
049ba25c AM |
49 | Patch118: %{name}-6.3-gstack-20050411.patch |
50 | Patch122: %{name}-6.3-test-pie-20050107.patch | |
8395e834 ER |
51 | Patch124: %{name}-archer-pie.patch |
52 | Patch389: %{name}-archer-pie-addons.patch | |
049ba25c | 53 | Patch125: %{name}-6.3-test-self-20050110.patch |
049ba25c | 54 | Patch133: %{name}-6.3-test-dtorfix-20050121.patch |
049ba25c AM |
55 | Patch136: %{name}-6.3-test-movedir-20050125.patch |
56 | Patch140: %{name}-6.3-gcore-thread-20050204.patch | |
57 | Patch141: %{name}-6.6-step-thread-exit.patch | |
58 | Patch259: %{name}-6.3-step-thread-exit-20050211-test.patch | |
59 | Patch142: %{name}-6.3-terminal-fix-20050214.patch | |
60 | Patch145: %{name}-6.3-threaded-watchpoints2-20050225.patch | |
61 | Patch148: %{name}-6.3-inheritance-20050324.patch | |
049ba25c AM |
62 | Patch153: %{name}-6.3-ia64-gcore-page0-20050421.patch |
63 | Patch157: %{name}-6.3-security-errata-20050610.patch | |
64 | Patch158: %{name}-6.3-ia64-sigtramp-frame-20050708.patch | |
65 | Patch160: %{name}-6.3-ia64-gcore-speedup-20050714.patch | |
66 | Patch161: %{name}-6.3-inferior-notification-20050721.patch | |
67 | Patch162: %{name}-6.3-ia64-info-frame-fix-20050725.patch | |
68 | Patch163: %{name}-6.3-inheritancetest-20050726.patch | |
69 | Patch164: %{name}-6.3-readnever-20050907.patch | |
049ba25c AM |
70 | Patch169: %{name}-6.3-ia64-sigill-20051115.patch |
71 | Patch170: %{name}-6.3-bt-past-zero-20051201.patch | |
72 | Patch176: %{name}-6.3-large-core-20051206.patch | |
73 | Patch177: %{name}-6.3-gstack-without-path-20060414.patch | |
74 | Patch188: %{name}-6.5-bz203661-emit-relocs.patch | |
75 | Patch190: %{name}-6.5-dwarf-stack-overflow.patch | |
76 | Patch194: %{name}-6.5-bz185337-resolve-tls-without-debuginfo-v2.patch | |
77 | Patch195: %{name}-6.5-tls-of-separate-debuginfo.patch | |
78 | Patch196: %{name}-6.5-sharedlibrary-path.patch | |
79 | Patch199: %{name}-6.5-bz190810-gdbserver-arch-advice.patch | |
049ba25c AM |
80 | Patch201: %{name}-6.5-gcore-i386-on-amd64.patch |
81 | Patch211: %{name}-6.5-last-address-space-byte-test.patch | |
82 | Patch208: %{name}-6.5-BEA-testsuite.patch | |
83 | Patch209: %{name}-6.5-readline-long-line-crash.patch | |
84 | Patch213: %{name}-6.5-readline-long-line-crash-test.patch | |
85 | Patch214: %{name}-6.5-bz216711-clone-is-outermost.patch | |
86 | Patch215: %{name}-6.5-bz218379-ppc-solib-trampoline-fix.patch | |
87 | Patch216: %{name}-6.5-bz218379-ppc-solib-trampoline-test.patch | |
88 | Patch217: %{name}-6.5-bz218379-solib-trampoline-lookup-lock-fix.patch | |
89 | Patch225: %{name}-6.5-bz109921-DW_AT_decl_file-test.patch | |
90 | Patch229: %{name}-6.3-bz140532-ppc-unwinding-test.patch | |
91 | Patch231: %{name}-6.3-bz202689-exec-from-pthread-test.patch | |
bf594b18 | 92 | Patch232: %{name}-7.0-upstream.patch |
049ba25c AM |
93 | Patch234: %{name}-6.6-bz230000-power6-disassembly-test.patch |
94 | Patch235: %{name}-6.3-bz231832-obstack-2gb.patch | |
95 | Patch240: %{name}-6.6-bz225783-prelink-path.patch | |
96 | Patch241: %{name}-6.6-bz225783-gdb-debuginfo-paths.patch | |
97 | Patch245: %{name}-6.6-bz229517-gcore-without-terminal.patch | |
98 | Patch247: %{name}-6.6-bz235197-fork-detach-info.patch | |
99 | Patch249: %{name}-6.6-gcore32-test.patch | |
100 | Patch254: %{name}-6.6-testsuite-timeouts.patch | |
101 | Patch258: %{name}-6.6-bz237572-ppc-atomic-sequence-test.patch | |
102 | Patch261: %{name}-6.6-readline-system.patch | |
103 | Patch263: %{name}-6.3-attach-see-vdso-test.patch | |
104 | Patch265: %{name}-6.6-bz247354-leader-exit-fix.patch | |
105 | Patch266: %{name}-6.6-bz247354-leader-exit-test.patch | |
106 | Patch271: %{name}-6.5-bz243845-stale-testing-zombie-test.patch | |
107 | Patch274: %{name}-6.6-buildid-locate.patch | |
108 | Patch353: %{name}-6.6-buildid-locate-rpm.patch | |
049ba25c AM |
109 | Patch282: %{name}-6.7-charsign-test.patch |
110 | Patch284: %{name}-6.7-ppc-clobbered-registers-O2-test.patch | |
111 | Patch287: %{name}-6.7-testsuite-stable-results.patch | |
112 | Patch289: %{name}-6.5-ia64-libunwind-leak-test.patch | |
113 | Patch290: %{name}-6.5-missed-trap-on-step-test.patch | |
114 | Patch293: %{name}-6.7-bz426600-DW_TAG_interface_type-fix.patch | |
115 | Patch294: %{name}-6.7-bz426600-DW_TAG_interface_type-test.patch | |
116 | Patch296: %{name}-6.5-gcore-buffer-limit-test.patch | |
117 | Patch298: %{name}-6.6-threads-static-test.patch | |
118 | Patch304: %{name}-6.7-kernel-headers-compat.patch | |
119 | Patch309: %{name}-6.3-mapping-zero-inode-test.patch | |
120 | Patch311: %{name}-6.3-focus-cmd-prev-test.patch | |
121 | Patch314: %{name}-6.3-watchpoint-cond-gone-test.patch | |
122 | Patch315: %{name}-6.8-bz442765-threaded-exec-test.patch | |
123 | Patch317: %{name}-6.8-sparc64-silence-memcpy-check.patch | |
124 | Patch318: %{name}-6.8-gcc35998-ada-memory-trash.patch | |
125 | Patch320: %{name}-6.5-section-num-fixup-test.patch | |
126 | Patch322: %{name}-6.8-constant-watchpoints.patch | |
127 | Patch324: %{name}-6.8-glibc-headers-compat.patch | |
128 | Patch326: %{name}-6.8-tui-singlebinary.patch | |
049ba25c AM |
129 | Patch350: %{name}-6.8-inlining-addon.patch |
130 | Patch328: %{name}-6.8-inlining-by-name.patch | |
131 | Patch329: %{name}-6.8-bz254229-gcore-prpsinfo.patch | |
132 | Patch330: %{name}-6.8-bz436037-reg-no-longer-active.patch | |
133 | Patch331: %{name}-6.8-quit-never-aborts.patch | |
134 | Patch332: %{name}-6.8-fortran-tag-constant.patch | |
049ba25c AM |
135 | Patch337: %{name}-6.8-attach-signalled-detach-stopped.patch |
136 | Patch343: %{name}-6.8-watchpoint-conditionals-test.patch | |
137 | Patch348: %{name}-6.8-bz466901-backtrace-full-prelinked.patch | |
138 | Patch349: %{name}-archer.patch | |
139 | Patch352: %{name}-6.8-bz457187-largefile.patch | |
7566401a ER |
140 | Patch360: %{name}-6.8-bz457187-largefile-test.patch |
141 | Patch375: %{name}-readline-6.0.patch | |
142 | Patch376: libstdc++-v3-python-common-prefix.patch | |
143 | Patch381: %{name}-simultaneous-step-resume-breakpoint-test.patch | |
ab050a48 BZ |
144 | Patch382: %{name}-core-open-vdso-warning.patch |
145 | Patch383: %{name}-bz528668-symfile-sepcrc.patch | |
146 | Patch384: %{name}-bz528668-symfile-cleanup.patch | |
147 | Patch385: %{name}-bz528668-symfile-multi.patch | |
148 | Patch387: %{name}-bz539590-gnu-ifunc.patch | |
149 | Patch388: %{name}-bz538626-bp_location-accel-bp-cond.patch | |
8395e834 ER |
150 | Patch390: %{name}-readline-6.0-signal.patch |
151 | Patch391: %{name}-x86_64-i386-syscall-restart.patch | |
ab050a48 | 152 | |
a59c1d89 ER |
153 | # PLD patches |
154 | Patch1000: %{name}-readline.patch | |
155 | Patch1001: %{name}-info.patch | |
156 | Patch1002: %{name}-passflags.patch | |
157 | Patch1005: %{name}-pretty-print-by-default.patch | |
158 | Patch1006: buildid-locate-rpm-pld.patch | |
3a97e68e | 159 | URL: http://www.gnu.org/software/gdb/ |
e92b6e8a | 160 | BuildRequires: autoconf >= 2.53 |
830462ab | 161 | BuildRequires: automake |
435950f1 JB |
162 | BuildRequires: bison |
163 | BuildRequires: flex | |
72a26adc | 164 | BuildRequires: libtool |
4e6d01d3 | 165 | BuildRequires: ncurses-devel >= 5.2 |
f8c0e4ef | 166 | BuildRequires: readline-devel >= 6.0 |
fc1b3e2b | 167 | BuildRequires: rpmbuild(macros) >= 1.219 |
3a97e68e | 168 | BuildRequires: texinfo >= 4.4 |
ab050a48 | 169 | BuildRequires: zlib-devel |
fc1b3e2b ER |
170 | %if %{with python} |
171 | BuildRequires: python-devel | |
172 | BuildRequires: rpm-pythonprov | |
173 | %endif | |
b4655cd1 | 174 | BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n) |
6aa96a1b | 175 | |
176 | %description | |
92563ae4 | 177 | Gdb is a full featured, command driven debugger. Gdb allows you to |
178 | trace the execution of programs and examine their internal state at | |
179 | any time. Gdb works for C and C++ compiled with the GNU C compiler | |
180 | gcc. | |
6aa96a1b | 181 | |
f01e46e5 JR |
182 | %description -l de.UTF-8 |
183 | dem Sie die Ausführung von Programmen verfolgen und jederzeit den | |
184 | inneren Zustand überprüfen können. Er funktioniert für C und mit GNU C | |
92563ae4 | 185 | kompiliertes C++. |
6aa96a1b | 186 | |
f01e46e5 JR |
187 | %description -l es.UTF-8 |
188 | Este es un debugger orientado a comandos repleto de características. | |
189 | Te permite rastrear la ejecución de programas y examinar su estado | |
c15663f7 | 190 | interno a cualquier momento. Funciona para C y C++ compilado con el |
191 | compilador GNU C. | |
192 | ||
f01e46e5 JR |
193 | %description -l fr.UTF-8 |
194 | Débugger complet, piloté par commandes. Permet de tracer l'exécution | |
195 | des programmes et d'examiner à tout moment leur état interne. | |
196 | Fonctionne avec les binaires C et C++ compilés avec le compilateur C | |
92563ae4 | 197 | de GNU, gcc. |
6aa96a1b | 198 | |
f01e46e5 JR |
199 | %description -l pl.UTF-8 |
200 | Gdb jest rozbudowanym odpluskwiaczem (debuggerem), pozwalającym | |
201 | śledzić wykonywanie programu i badać jego stan wewnętrzny. Gdb | |
202 | umożliwia odpluskwianie programów napisanych w C/C++ i skompilowanych | |
92563ae4 | 203 | przy pomocy kompilatora GNU (gcc). |
6aa96a1b | 204 | |
f01e46e5 JR |
205 | %description -l pt_BR.UTF-8 |
206 | Este é um debugger orientado a comandos repleto de características. | |
207 | Ele permite à você rastrear a execução de programas e examinar o seu | |
c15663f7 | 208 | estado interno a qualquer momento. Ele funciona para para C e C++ |
209 | compilado com o compilador GNU C. | |
210 | ||
f01e46e5 JR |
211 | %description -l ru.UTF-8 |
212 | Это полноценный отладчик, управляемый командами. Он позволяет | |
213 | трассировать исполнение программ и изучать их внутреннее состояние в | |
214 | любой момент времени. Работает с программами на C и C++, | |
215 | скомпилированными GNU компилятором C (gcc, egcs, pgcc). | |
11d14365 | 216 | |
f01e46e5 JR |
217 | %description -l tr.UTF-8 |
218 | Bir komut arayüzü üzerinden programcıya programını adım adım izleme | |
219 | (trace) ve herhangi bir anda programın durumunu inceleme olanağı | |
92563ae4 | 220 | verir. |
6aa96a1b | 221 | |
f01e46e5 JR |
222 | %description -l uk.UTF-8 |
223 | Це повноцінний відладчик, що керується командами. Він дозволяє | |
224 | трасувати виконання програм та вивчати їх внутрішній стан в довільний | |
225 | момент часу. Працює з програмами на C та C++, зкомпільованими | |
226 | компіляторами GNU C (gcc, egcs, pgcc). | |
11d14365 | 227 | |
7566401a ER |
228 | %package gdbserver |
229 | Summary: A standalone server for GDB (the GNU source-level debugger) | |
230 | Group: Development/Debuggers | |
231 | ||
232 | %description gdbserver | |
233 | GDB, the GNU debugger, allows you to debug programs written in C, C++, | |
234 | Java, and other languages, by executing them in a controlled fashion | |
235 | and printing their data. | |
236 | ||
237 | This package provides a program that allows you to run GDB on a | |
238 | different machine than the one which is running the program being | |
239 | debugged. | |
240 | ||
fc1b3e2b ER |
241 | %package -n python-%{name} |
242 | Summary: GDB Python bindings | |
243 | Summary(pl.UTF-8): Wiązania PackageKit dla Pythona | |
244 | Group: Development/Languages/Python | |
245 | Requires: python-libs | |
246 | ||
247 | %description -n python-%{name} | |
248 | GDB Python bindings. | |
249 | ||
f02a934e | 250 | %package lib |
4e0c2e1e | 251 | Summary: GDB in the form of a static library |
0ec45698 | 252 | Summary(pl.UTF-8): GDB w postaci biblioteki statycznej |
f02a934e | 253 | Group: Development/Debuggers |
3a97e68e | 254 | #Requires: binutils-devel >= 2.17.50 |
f02a934e JR |
255 | |
256 | %description lib | |
257 | GDB in the form of a static library. | |
258 | ||
f01e46e5 | 259 | %description lib -l pl.UTF-8 |
4e0c2e1e JB |
260 | GDB w postaci biblioteki statycznej. |
261 | ||
6aa96a1b | 262 | %prep |
bf594b18 | 263 | %setup -q |
049ba25c | 264 | |
7566401a ER |
265 | # libstdc++ pretty printers. |
266 | bzip2 -dc %{SOURCE4} | tar xf - | |
267 | ||
049ba25c AM |
268 | # Files have `# <number> <file>' statements breaking VPATH / find-debuginfo.sh . |
269 | rm -f gdb/ada-exp.c gdb/ada-lex.c gdb/c-exp.c gdb/cp-name-parser.c gdb/f-exp.c | |
270 | rm -f gdb/jv-exp.c gdb/m2-exp.c gdb/objc-exp.c gdb/p-exp.c | |
271 | ||
bf594b18 | 272 | # FEDORA PATCHES -- keep them in same order they do |
8395e834 | 273 | %patch2 -p1 |
ab050a48 | 274 | %patch232 -p1 |
049ba25c | 275 | %patch349 -p1 |
ab050a48 BZ |
276 | %patch383 -p1 |
277 | %patch384 -p1 | |
278 | %patch385 -p1 | |
8395e834 | 279 | %patch124 -p1 |
049ba25c AM |
280 | %patch1 -p1 |
281 | %patch3 -p1 | |
049ba25c AM |
282 | %patch104 -p1 |
283 | %patch105 -p1 | |
284 | %patch106 -p1 | |
285 | %patch111 -p1 | |
286 | %patch112 -p1 | |
049ba25c AM |
287 | %patch118 -p1 |
288 | %patch122 -p1 | |
289 | %patch125 -p1 | |
049ba25c | 290 | %patch133 -p1 |
049ba25c AM |
291 | %patch136 -p1 |
292 | %patch140 -p1 | |
293 | %patch141 -p1 | |
294 | %patch259 -p1 | |
295 | %patch142 -p1 | |
296 | %patch145 -p1 | |
297 | %patch148 -p1 | |
049ba25c AM |
298 | %patch153 -p1 |
299 | %patch157 -p1 | |
300 | %patch158 -p1 | |
301 | %patch160 -p1 | |
302 | %patch161 -p1 | |
303 | %patch162 -p1 | |
304 | %patch163 -p1 | |
305 | %patch164 -p1 | |
049ba25c AM |
306 | %patch169 -p1 |
307 | %patch170 -p1 | |
308 | %patch176 -p1 | |
309 | %patch177 -p1 | |
310 | %patch188 -p1 | |
311 | %patch190 -p1 | |
312 | %patch194 -p1 | |
313 | %patch195 -p1 | |
314 | %patch196 -p1 | |
315 | %patch199 -p1 | |
049ba25c AM |
316 | %patch201 -p1 |
317 | %patch208 -p1 | |
318 | %patch209 -p1 | |
319 | %patch211 -p1 | |
320 | %patch213 -p1 | |
321 | %patch214 -p1 | |
322 | %patch215 -p1 | |
323 | %patch216 -p1 | |
324 | %patch217 -p1 | |
325 | %patch225 -p1 | |
326 | %patch229 -p1 | |
327 | %patch231 -p1 | |
328 | %patch234 -p1 | |
329 | %patch235 -p1 | |
330 | %patch240 -p1 | |
331 | %patch241 -p1 | |
332 | %patch245 -p1 | |
333 | %patch247 -p1 | |
334 | %patch249 -p1 | |
335 | %patch254 -p1 | |
336 | %patch258 -p1 | |
337 | %patch260 -p1 | |
338 | %patch261 -p1 | |
339 | %patch263 -p1 | |
340 | %patch265 -p1 | |
341 | %patch266 -p1 | |
342 | %patch271 -p1 | |
343 | %patch274 -p1 | |
344 | %patch353 -p1 | |
049ba25c AM |
345 | %patch282 -p1 |
346 | %patch284 -p1 | |
347 | %patch287 -p1 | |
348 | %patch289 -p1 | |
349 | %patch290 -p1 | |
350 | %patch293 -p1 | |
351 | %patch294 -p1 | |
352 | %patch296 -p1 | |
353 | %patch298 -p1 | |
354 | %patch304 -p1 | |
355 | %patch309 -p1 | |
356 | %patch311 -p1 | |
357 | %patch314 -p1 | |
358 | %patch315 -p1 | |
359 | %patch317 -p1 | |
360 | %patch318 -p1 | |
361 | %patch320 -p1 | |
362 | %patch322 -p1 | |
363 | %patch324 -p1 | |
364 | %patch326 -p1 | |
049ba25c AM |
365 | %patch350 -p1 |
366 | %patch328 -p1 | |
367 | %patch329 -p1 | |
368 | %patch330 -p1 | |
369 | %patch331 -p1 | |
370 | %patch332 -p1 | |
049ba25c AM |
371 | %patch337 -p1 |
372 | %patch343 -p1 | |
373 | %patch348 -p1 | |
374 | %patch352 -p1 | |
7566401a ER |
375 | %patch360 -p1 |
376 | %patch375 -p1 | |
377 | %patch376 -p1 | |
378 | %patch381 -p1 | |
ab050a48 BZ |
379 | %patch382 -p1 |
380 | %patch387 -p1 | |
381 | %patch388 -p1 | |
8395e834 ER |
382 | %patch389 -p1 |
383 | %patch390 -p1 | |
384 | %patch391 -p1 | |
7566401a | 385 | |
a59c1d89 ER |
386 | # PLD patches |
387 | %patch1000 -p1 | |
388 | %patch1001 -p1 | |
389 | %patch1002 -p1 | |
390 | %patch1005 -p1 | |
391 | %patch1006 -p1 | |
392 | ||
7566401a | 393 | mv $(basename %{SOURCE4} .tar.bz2) libstdcxxpython |
9164351f | 394 | |
41611023 ER |
395 | # Change the version that gets printed at GDB startup, so it is PLD Linux specific. |
396 | cat > gdb/version.in << EOF | |
397 | PLD Linux (%{version}-%{release}) | |
398 | EOF | |
399 | ||
6aa96a1b | 400 | %build |
7566401a | 401 | for dir in $(find gdb -name 'configure.in'); do |
0cd7a575 AM |
402 | dir=$(dirname "$dir") |
403 | olddir=$(pwd) | |
404 | cd $dir | |
405 | rm -f aclocal.m4 | |
406 | %{__aclocal} | |
407 | %{__autoconf} | |
a1a121a0 | 408 | %{__autoheader} |
0cd7a575 AM |
409 | cd $olddir |
410 | done | |
3661d025 | 411 | cp -f /usr/share/automake/config.* . |
3a97e68e | 412 | # don't --enable-shared here, there would be libs version mismatch with binutils |
62be29ad | 413 | %configure \ |
049ba25c AM |
414 | --with-gdb-datadir=%{_datadir}/gdb \ |
415 | --with-separate-debug-dir=/usr/lib/debug \ | |
7566401a ER |
416 | %if %{with python} |
417 | --with-python \ | |
418 | --with-pythondir=%{py_sitescriptdir} \ | |
419 | %else | |
420 | --without-python \ | |
421 | %endif | |
fdffb271 | 422 | --disable-gdbtk \ |
ebd49a3e | 423 | --disable-shared \ |
fdffb271 | 424 | --enable-gdbcli \ |
b257c914 | 425 | --enable-gdbmi \ |
426 | --enable-multi-ice \ | |
ebd49a3e | 427 | --enable-netrom \ |
fdffb271 | 428 | --enable-nls \ |
5f8bd10e | 429 | --enable-tui \ |
fdffb271 | 430 | --with-cpu=%{_target_cpu} \ |
ac43b5eb | 431 | %ifnarch alpha |
3a97e68e | 432 | --with-mmalloc \ |
ac43b5eb | 433 | %endif |
3a97e68e JB |
434 | --without-included-gettext \ |
435 | --without-included-regex \ | |
436 | --without-x | |
ebd49a3e | 437 | |
bf594b18 | 438 | %{__make} -j1 |
a59c1d89 | 439 | %{__make} -j1 info |
6aa96a1b | 440 | |
441 | %install | |
442 | rm -rf $RPM_BUILD_ROOT | |
5ff7d7dd | 443 | install -d $RPM_BUILD_ROOT%{_infodir} |
6aa96a1b | 444 | |
bf594b18 | 445 | %{__make} -j1 install install-info \ |
049ba25c | 446 | DESTDIR=$RPM_BUILD_ROOT |
e611e157 | 447 | |
a59c1d89 ER |
448 | # gdbtui seems all identical to gdb except when invoked as gdbtio, ncurses |
449 | # window is created too. | |
450 | echo ".so gdb.1" > $RPM_BUILD_ROOT%{_mandir}/man1/gdbtui.1 | |
451 | ln -f $RPM_BUILD_ROOT%{_bindir}/{gdb,gdbtui} | |
452 | ||
8d9a5f3e | 453 | bzip2 -dc %{SOURCE1} | tar xf - -C $RPM_BUILD_ROOT%{_mandir} |
7566401a ER |
454 | cp -a gdb/libgdb.a $RPM_BUILD_ROOT%{_libdir} |
455 | ||
456 | rm -f $RPM_BUILD_ROOT%{_infodir}/dir | |
457 | rm -f $RPM_BUILD_ROOT%{_mandir}/README.gdb-non-english-man-pages | |
458 | ||
459 | %if %{with python} | |
460 | # Temporarily now: | |
461 | for LIB in lib lib64; do | |
462 | LIBPATH="$RPM_BUILD_ROOT%{_datadir}/gdb/auto-load%{_prefix}/$LIB" | |
463 | install -d $LIBPATH | |
464 | # basename is being run only for the native (non-biarch) file. | |
bf594b18 ER |
465 | sed -e 's,@pythondir@,%{_datadir}/gdb/python,' \ |
466 | -e 's,@toolexeclibdir@,%{_prefix}/'"$LIB," \ | |
7566401a ER |
467 | < libstdcxxpython/hook.in \ |
468 | > $LIBPATH/$(basename %{_prefix}/%{_lib}/libstdc++.so.6.*)-gdb.py | |
469 | done | |
fc1b3e2b ER |
470 | cp -a libstdcxxpython/libstdcxx $RPM_BUILD_ROOT%{py_sitescriptdir} |
471 | ||
472 | %py_ocomp $RPM_BUILD_ROOT%{py_sitescriptdir} | |
473 | %py_comp $RPM_BUILD_ROOT%{py_sitescriptdir} | |
474 | %py_postclean | |
7566401a | 475 | %endif |
8d9a5f3e | 476 | |
41611023 ER |
477 | cp -a %{SOURCE3} $RPM_BUILD_ROOT%{_mandir}/man1/gstack.1 |
478 | ||
7566401a ER |
479 | # Remove the files that are part of a gdb build but that are owned and provided by other packages. |
480 | # These are part of binutils | |
481 | rm -rf $RPM_BUILD_ROOT%{_datadir}/locale | |
482 | rm -f $RPM_BUILD_ROOT%{_infodir}/bfd* | |
483 | rm -f $RPM_BUILD_ROOT%{_infodir}/standard* | |
484 | rm -f $RPM_BUILD_ROOT%{_infodir}/mmalloc* | |
485 | rm -f $RPM_BUILD_ROOT%{_infodir}/configure* | |
486 | rm -rf $RPM_BUILD_ROOT%{_includedir} | |
487 | rm -rf $RPM_BUILD_ROOT%{_libdir}/lib{bfd*,opcodes*,iberty*,mmalloc*} | |
f02a934e | 488 | |
b0a9ea6d JB |
489 | %clean |
490 | rm -rf $RPM_BUILD_ROOT | |
6aa96a1b | 491 | |
1f7f0d47 ER |
492 | %post -p /sbin/postshell |
493 | -/usr/sbin/fix-info-dir -c %{_infodir} | |
6aa96a1b | 494 | |
1f7f0d47 ER |
495 | %postun -p /sbin/postshell |
496 | -/usr/sbin/fix-info-dir -c %{_infodir} | |
6aa96a1b | 497 | |
6aa96a1b | 498 | %files |
0241102e | 499 | %defattr(644,root,root,755) |
f0842f54 | 500 | %doc gdb/{ChangeLog,NEWS,PROBLEMS,README} |
7566401a ER |
501 | %attr(755,root,root) %{_bindir}/gdb |
502 | %attr(755,root,root) %{_bindir}/gdbtui | |
503 | %attr(755,root,root) %{_bindir}/gstack | |
504 | %dir %{_datadir}/gdb | |
505 | %{_datadir}/gdb/syscalls | |
506 | %{_mandir}/man1/gdb.1* | |
507 | %{_mandir}/man1/gdbtui.1* | |
41611023 | 508 | %{_mandir}/man1/gstack.1* |
8d9a5f3e | 509 | %lang(es) %{_mandir}/es/man1/* |
510 | %lang(fr) %{_mandir}/fr/man1/* | |
511 | %lang(hu) %{_mandir}/hu/man1/* | |
512 | %lang(ja) %{_mandir}/ja/man1/* | |
513 | %lang(pl) %{_mandir}/pl/man1/* | |
7566401a ER |
514 | %{_infodir}/annotate.info* |
515 | %{_infodir}/gdb.info* | |
516 | %{_infodir}/gdbint.info* | |
517 | %{_infodir}/stabs.info* | |
518 | ||
519 | %if %{with python} | |
fc1b3e2b ER |
520 | %files -n python-%{name} |
521 | %defattr(644,root,root,755) | |
522 | %dir %{py_sitescriptdir}/gdb | |
523 | %{py_sitescriptdir}/gdb/*.py[co] | |
524 | %dir %{py_sitescriptdir}/gdb/command | |
525 | %{py_sitescriptdir}/gdb/command/*.py[co] | |
526 | %dir %{py_sitescriptdir}/gdb/function | |
527 | %{py_sitescriptdir}/gdb/function/*.py[co] | |
528 | ||
529 | # likely oneday gcc.spec will provide this | |
530 | %dir %{py_sitescriptdir}/libstdcxx | |
531 | %{py_sitescriptdir}/libstdcxx/*.py[co] | |
532 | %dir %{py_sitescriptdir}/libstdcxx/v6 | |
533 | %{py_sitescriptdir}/libstdcxx/v6/*.py[co] | |
534 | ||
535 | # or should we include it in base package? | |
7566401a | 536 | %{_datadir}/gdb/auto-load |
7566401a ER |
537 | %endif |
538 | ||
539 | %files gdbserver | |
540 | %defattr(644,root,root,755) | |
541 | %attr(755,root,root) %{_bindir}/gdbserver | |
542 | %{_mandir}/man1/gdbserver.1* | |
f02a934e JR |
543 | |
544 | %files lib | |
545 | %defattr(644,root,root,755) | |
546 | %{_libdir}/libgdb.a |