File astyle.spec of Package astyle
#
# spec file for package astyle (Version 1.24)
#
# Copyright (c) 2010 SUSE LINUX Products GmbH, Nuernberg, Germany.
#
# All modifications and additions to the file contributed by third parties
# remain the property of their copyright owners, unless otherwise agreed
# upon. The license for this file, and modifications and additions to the
# file, is the same license as for the pristine package itself (unless the
# license for the pristine package is not an Open Source License, in which
# case the license is the MIT License). An "Open Source License" is a
# license that conforms to the Open Source Definition (Version 1.9)
# published by the Open Source Initiative.
# Please submit bugfixes or comments via http://bugs.opensuse.org/
#
# norootforbuild
Name: astyle
BuildRequires: gcc-c++
Version: 1.24
Release: 1
Summary: Source code indenter, formatter, and beautifier for C, C++, C# and Java
Group: Development/Tools/Other
License: LGPLv3+
Url: http://astyle.sourceforge.net/
Source: %{name}_%{version}_linux.tar.bz2
Patch0: astyle-1.24-cxxflags.patch
BuildRoot: %{_tmppath}/%{name}-%{version}-build
%description
Artistic Style is a source code indenter, formatter, and beautifier for the C,
C++, C# and Java programming languages. It automatically re-indents and
re-formats C / C++ / C# / Java source files. It can be used from a command
line, or it can be incorporated as classes in another C++ program.
%prep
%setup -q -n %{name}
%patch0 -b .cxxflags
%build
export CFLAGS="%{optflags}"
export CXXFLAGS="%{optflags}"
cd build/gcc
make release
%install
install -d -m 0755 %{buildroot}%{_bindir}
install -m 0755 build/gcc/bin/%{name} %{buildroot}%{_bindir}
%clean
rm -rf %{buildroot}
%files
%defattr(0644,root,root,0755)
%doc doc/astyle.html doc/license.html
%defattr(-,root,root,0755)
%{_bindir}/%{name}
%changelog