michael@421: ## michael@421: ## gdb.spec -- OpenPKG RPM Package Specification michael@421: ## Copyright (c) 2000-2012 OpenPKG Foundation e.V. michael@421: ## michael@421: ## Permission to use, copy, modify, and distribute this software for michael@421: ## any purpose with or without fee is hereby granted, provided that michael@421: ## the above copyright notice and this permission notice appear in all michael@421: ## copies. michael@421: ## michael@421: ## THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED michael@421: ## WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF michael@421: ## MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. michael@421: ## IN NO EVENT SHALL THE AUTHORS AND COPYRIGHT HOLDERS AND THEIR michael@421: ## CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, michael@421: ## SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT michael@421: ## LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF michael@421: ## USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND michael@421: ## ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, michael@421: ## OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT michael@421: ## OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF michael@421: ## SUCH DAMAGE. michael@421: ## michael@421: michael@421: # package version michael@421: %define V_tarball 7.4.1 michael@421: %define V_subdir 7.4.1 michael@421: michael@421: # package information michael@421: Name: gdb michael@421: Summary: GNU Debugger michael@421: URL: http://www.gnu.org/software/gdb/ michael@421: Vendor: Free Software Foundation michael@421: Packager: OpenPKG Foundation e.V. michael@421: Distribution: OpenPKG Community michael@421: Class: BASE michael@421: Group: Debugging michael@421: License: GPL michael@421: Version: %{V_tarball} michael@422: Release: 20120800 michael@421: michael@421: # list of sources michael@421: Source0: ftp://ftp.gnu.org/gnu/gdb/gdb-%{V_tarball}.tar.gz michael@421: Patch0: gdb.patch michael@421: michael@421: # build information michael@421: BuildPreReq: OpenPKG, openpkg >= 20100101, make, flex, m4 michael@421: PreReq: OpenPKG, openpkg >= 20100101 michael@421: BuildPreReq: ncurses, libiconv michael@421: PreReq: ncurses, libiconv michael@421: michael@421: %description michael@421: The purpose of a debugger such as GDB is to allow you to see what michael@421: is going on `inside' another program while it executes -- or what michael@421: another program was doing at the moment it crashed. michael@421: michael@421: %track michael@421: prog gdb = { michael@421: version = %{V_tarball} michael@421: url = ftp://ftp.gnu.org/gnu/gdb/ michael@421: regex = gdb-(__VER__)\.tar\.gz michael@421: } michael@421: michael@421: %prep michael@421: %setup -q -n gdb-%{V_subdir} michael@421: %patch -p0 michael@421: michael@421: %build michael@421: %{l_shtool} subst \ michael@421: -e 's;-Werror;;' \ michael@421: `find . -type f -name configure -print` michael@421: CC="%{l_cc} %{l_ldflags}" \ michael@421: CFLAGS="%{l_cflags -O} %{l_cppflags ncurses .}" \ michael@421: CPPFLAGS="%{l_cppflags ncurses .}" \ michael@421: LDFLAGS="%{l_ldflags}" \ michael@421: LIBS="%{l_ldflags} -liconv" \ michael@421: ./configure \ michael@421: --prefix=%{l_prefix} \ michael@421: --libdir=%{l_prefix}/lib \ michael@421: --mandir=%{l_prefix}/man \ michael@421: --infodir=%{l_prefix}/info \ michael@421: --without-expat \ michael@421: --with-libiconv-prefix=%{l_prefix} \ michael@421: --disable-werror \ michael@421: --disable-nls michael@421: %{l_make} %{l_mflags -O} michael@421: michael@421: %install michael@421: %{l_make} %{l_mflags} install DESTDIR=$RPM_BUILD_ROOT michael@422: rm -rf $RPM_BUILD_ROOT%{l_prefix}/lib* michael@421: rm -rf $RPM_BUILD_ROOT%{l_prefix}/include michael@421: rm -f $RPM_BUILD_ROOT%{l_prefix}/info/dir michael@421: rm -f $RPM_BUILD_ROOT%{l_prefix}/info/configure.info* michael@421: rm -f $RPM_BUILD_ROOT%{l_prefix}/info/standards.info* michael@421: rm -f $RPM_BUILD_ROOT%{l_prefix}/info/bfd.info* michael@421: strip $RPM_BUILD_ROOT%{l_prefix}/bin/* >/dev/null 2>&1 || true michael@421: %{l_rpmtool} files -v -ofiles -r$RPM_BUILD_ROOT %{l_files_std} michael@421: michael@421: %files -f files michael@421: michael@421: %clean michael@421: