]> git.pld-linux.org Git - packages/boomerang.git/blame - boomerang.spec
- tabs in preamble
[packages/boomerang.git] / boomerang.spec
CommitLineData
a0eee946
JB
1#
2# Conditional build:
3%bcond_with flex_bison_c++ # use flex++/bison++
4#
f56acf41 5Summary: A general, open source, retargetable decompiler of native executable files
6a754711 6Summary(pl.UTF-8): Ogólny, otwarty dekompilator natywnych plików wykonywalnych
cfcf678f 7Name: boomerang
7466cb14 8Version: 0.0.0.20040708
a0eee946 9Release: 0.2
cfcf678f
AM
10License: GPL
11Group: Development/Languages
12Source0: %{name}.tar.gz
7466cb14
AM
13# Source0-md5: a9f15806eb670686869f67a06e8a6fbb
14Patch0: %{name}-path.patch
a0eee946 15Patch1: %{name}-types.patch
cfcf678f 16URL: http://boomerang.sourceforge.net/
a0eee946 17BuildRequires: automake
9f2ad00e 18%if %{with flex_bison_c++}
cfcf678f 19BuildRequires: bison++
720a611d 20BuildRequires: flex
9f2ad00e 21%endif
720a611d 22BuildRequires: cppunit-devel
cfcf678f 23BuildRequires: expat-devel
f56acf41 24BuildRequires: gc-devel
cfcf678f 25BuildRequires: libstdc++-devel
38c21234 26BuildRequires: sed >= 4.0
cfcf678f
AM
27BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
28
7466cb14
AM
29%define no_install_post_chrpath 1
30
cfcf678f
AM
31%description
32An attempt to develop a real decompiler through the open source
33community. A decompiler takes as input an executable file, and
34attempts to create a high level, compilable, even maintainable source
35file that does the same thing. It is therefore the opposite of a
36compiler, which of course takes a source file and makes an executable.
37It won't of course recreate the original source file; probably nothing
38like it. It does not matter if the executable file has symbols or not,
39or was compiled from any particular language. (However, languages like
40ML that are usually interpreted are not considered.)
41
42The intent is to create a retargetable decompiler (i.e. one that can
43work with different types of input executable files with modest
44effort, e.g. X86-windows, sparc-solaris, etc). It will be highly
45modular, so that different parts of the decompiler can be replaced
46with experimental modules. It is intended to eventually become
47interactive, a la IDA Pro, because some things (not just variable
48names and comments, though these are obviously very important) require
49expert intervention.
50
235c4395
JR
51%description -l pl.UTF-8
52Próba stworzenia prawdziwego dekompilatora przez społeczność otwartego
53oprogramowania. Dekompilator przyjmuje na wejściu plik wykonywalny i
54próbuje stworzyć kompilowalny, a nawet zarządzalny, plik źródłowy w
55języku wyższego poziomu wykonujący to samo zadanie. Jest to więc
56przeciwieństwo kompilatora, który oczywiście przyjmuje plik źródłowy i
57tworzy wykonywalny. Oczywiście dekompilator nie odtworzy oryginalnego
58pliku źródłowego; raczej nic z tych rzeczy. Nie ma znaczenia, czy plik
59wykonywalny ma symbole czy nie, ani czy został skompilowany z jakiegoś
60konkretnego języka (jednak języki w rodzaju ML, które są zwykle
61interpretowane, nie są brane pod uwagę).
f56acf41 62
235c4395
JR
63Intencją jest stworzenie dekompilatora dla wielu architektur (czyli
64takiego, który może działać z różnymi rodzajami wejściowych plików
f56acf41 65wykonywalnych z przyzwoitym efektem, np. x86-windows, sparc-solaris
235c4395
JR
66itp.). Będzie bardzo modularny, więc wiele części dekompilatora może
67zostać zastąpiona eksperymentalnymi modułami. Być może stanie się
68interaktywny, jak IDA Pro, ponieważ niektóre rzeczy (nie tylko nazwy
69zmiennych i komentarze, chociaż te są oczywiście bardzo ważne)
70wymagają interwencji eksperta.
f56acf41 71
cfcf678f
AM
72%prep
73%setup -q -n %{name}
7466cb14 74%patch0 -p1
a0eee946 75%patch1 -p1
cfcf678f 76
7466cb14
AM
77find . -type d -name CVS -exec rm -rf "{}" ";" 2> /dev/null || :
78find . -type f -name 'Makefile*' -exec sed -i -e 's#^BOOMDIR=.*#BOOMDIR=%{_libdir}/%{name}#g' "{}" ";"
9f2ad00e 79
a0eee946
JB
80%build
81ln -sf %{_includedir}/cppunit include/cppunit
82cp -f /usr/share/automake/config.* .
cfcf678f
AM
83%configure
84
9f2ad00e
AM
85%if ! %{with flex_bison_c++}
86%{__make} remote
87%endif
88
cfcf678f 89%{__make} \
720a611d
AM
90 C="%{__cc} %{rpmcflags} -I%{_includedir}/gc" \
91 CC="%{__cxx} %{rpmcflags} -I%{_includedir}/gc"
cfcf678f
AM
92
93%install
94rm -rf $RPM_BUILD_ROOT
7466cb14 95install -d $RPM_BUILD_ROOT{%{_bindir},%{_libdir}/%{name}/frontend/machine}
cfcf678f 96
9f2ad00e 97install %{name} $RPM_BUILD_ROOT%{_bindir}
7466cb14
AM
98cp -a signatures transformations $RPM_BUILD_ROOT%{_libdir}/%{name}
99cp -a frontend/machine/* $RPM_BUILD_ROOT%{_libdir}/%{name}/frontend/machine
100find $RPM_BUILD_ROOT%{_libdir}/%{name}/frontend/machine -type f ! -name '*.ssl' -exec rm -f "{}" ";"
101cp -a lib $RPM_BUILD_ROOT%{_libdir}/%{name}/lib
cfcf678f
AM
102
103%clean
104rm -rf $RPM_BUILD_ROOT
105
106%files
107%defattr(644,root,root,755)
9f2ad00e 108%attr(755,root,root) %{_bindir}/*
9f2ad00e 109%dir %{_libdir}/%{name}
a0eee946 110%dir %{_libdir}/%{name}/lib
7466cb14 111%attr(755,root,root) %{_libdir}/%{name}/lib/*.so
a0eee946 112%dir %{_libdir}/%{name}/frontend
7466cb14
AM
113%dir %{_libdir}/%{name}/frontend/machine
114%dir %{_libdir}/%{name}/frontend/machine/*
115%{_libdir}/%{name}/frontend/machine/*/*.ssl
a0eee946
JB
116%{_libdir}/%{name}/signatures
117%{_libdir}/%{name}/transformations
This page took 0.065312 seconds and 4 git commands to generate.