]>
Commit | Line | Data |
---|---|---|
166a6c21 | 1 | ############################################################################### |
802ea3af MT |
2 | # IPFire.org - An Open Source Firewall Solution # |
3 | # Copyright (C) - IPFire Development Team <info@ipfire.org> # | |
166a6c21 MT |
4 | ############################################################################### |
5 | ||
802ea3af | 6 | name = binutils |
62c04d4f | 7 | version = 2.40 |
4c4a5d3c | 8 | release = 1 |
166a6c21 | 9 | |
802ea3af MT |
10 | maintainer = Michael Tremer <michael.tremer@ipfire.org> |
11 | groups = Development/Tools | |
62c04d4f | 12 | url = https://www.gnu.org/software/binutils/ |
802ea3af | 13 | license = GPLv2+ |
62c04d4f | 14 | summary = The GNU Binutils are a collection of binary tools |
166a6c21 | 15 | |
802ea3af MT |
16 | description |
17 | The GNU Binary Utilities, or binutils, is a collection of programming | |
166a6c21 | 18 | tools for the manipulation of object code in various object file formats. |
802ea3af MT |
19 | end |
20 | ||
3e4070b5 MT |
21 | source_dl = https://ftp.gnu.org/gnu/binutils/ \ |
22 | https://sourceware.org/pub/binutils/releases/ | |
23 | sources = %{thisapp}.tar.xz | |
802ea3af MT |
24 | |
25 | build | |
26 | requires | |
27 | bison | |
28 | dejagnu | |
29 | flex | |
30 | gcc-c++ | |
602900c1 | 31 | perl |
802ea3af MT |
32 | texinfo |
33 | zlib-devel | |
62c04d4f | 34 | zstd-devel |
802ea3af MT |
35 | end |
36 | ||
62c04d4f MT |
37 | LDFLAGS += -Wl,--enable-new-dtags |
38 | ||
802ea3af MT |
39 | prepare_cmds |
40 | mkdir -pv %{DIR_SRC}/binutils-build | |
802ea3af MT |
41 | end |
42 | ||
bb86d46e | 43 | configure_options += \ |
f71c9576 MT |
44 | --build=%{DISTRO_BUILDTARGET} \ |
45 | --host=%{DISTRO_BUILDTARGET} \ | |
bb86d46e MT |
46 | --target=%{DISTRO_BUILDTARGET} \ |
47 | --disable-werror \ | |
f71c9576 | 48 | --disable-static \ |
62c04d4f | 49 | --enable-shared \ |
f71c9576 MT |
50 | --enable-64-bit-bfd \ |
51 | --enable-plugins \ | |
5be519d0 | 52 | --with-bugurl="https://bugzilla.ipfire.org/" \ |
3e4070b5 | 53 | --enable-relro=yes \ |
62c04d4f MT |
54 | --enable-ld \ |
55 | --disable-gold \ | |
56 | --enable-lto \ | |
57 | --with-system-zlib \ | |
58 | --enable-new-dtags \ | |
59 | --disable-rpath \ | |
60 | --enable-separate-code | |
802ea3af MT |
61 | |
62 | build | |
68b0def9 MT |
63 | cd %{DIR_SRC}/binutils-build |
64 | ../%{thisapp}/configure \ | |
bb86d46e | 65 | %{configure_options} |
68b0def9 MT |
66 | |
67 | make tooldir=/usr %{PARALLELISMFLAGS} | |
802ea3af MT |
68 | end |
69 | ||
0c98d65a MT |
70 | test |
71 | cd %{DIR_SRC}/binutils-build | |
72 | make -k check </dev/null || : | |
73 | ||
74 | echo "==== RESULTS ====" | |
75 | cat {gas/testsuite/gas,ld/ld,binutils/binutils}.sum | |
76 | end | |
802ea3af MT |
77 | |
78 | install | |
0c98d65a MT |
79 | cd %{DIR_SRC}/binutils-build |
80 | make tooldir=/usr install DESTDIR=%{BUILDROOT} | |
802ea3af MT |
81 | |
82 | cp -fv %{DIR_APP}/include/libiberty.h %{BUILDROOT}/usr/include | |
d5518e81 MT |
83 | |
84 | # Prevent packages from linking against libbfd and libopcodes, | |
85 | # because they change too often. | |
bb86d46e | 86 | rm -rfv %{BUILDROOT}%{libdir}/lib{bfd,opcodes}.so |
0c98d65a MT |
87 | |
88 | # Remove Windows/Novell only man pages. | |
89 | rm -vf %{BUILDROOT}%{mandir}/man1/{dlltool,nlmconv,windres}* | |
802ea3af MT |
90 | end |
91 | end | |
92 | ||
93 | packages | |
94 | package %{name} | |
62c04d4f MT |
95 | |
96 | package %{name}-libs | |
97 | template LIBS | |
98 | ||
99 | files += %{libdir}/*-%{version}.so | |
e5e21531 | 100 | end |
974699b4 MT |
101 | |
102 | package %{name}-devel | |
103 | template DEVEL | |
f45434a7 | 104 | |
e5e21531 | 105 | requires |
62c04d4f | 106 | binutils-libs = %{thisver} |
e5e21531 MT |
107 | zlib-devel |
108 | end | |
109 | ||
62c04d4f | 110 | files += !%{libdir}/*-%{version}.so |
802ea3af | 111 | end |
1f9bc2f0 MT |
112 | |
113 | package %{name}-debuginfo | |
114 | template DEBUGINFO | |
115 | end | |
802ea3af | 116 | end |