-
Notifications
You must be signed in to change notification settings - Fork 0
/
SFEastyle.spec
96 lines (77 loc) · 3.1 KB
/
SFEastyle.spec
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
# ===========================================================================
# Spec File
# ===========================================================================
%include Solaris.inc
# +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
# Software specific variable definitions
# +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
%define src_name astyle
%define src_version 1.21
%define pkg_release 1
%define src_tarball %{src_name}_%{src_version}__linux.tar.gz
# ===========================================================================
# SVR4 required definitions
# ===========================================================================
SUNW_Pkg: SFE%{src_name}-%{base_arch}
SUNW_ProdVers: %{src_version}
SUNW_BaseDir: %{_basedir}
# +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
# Tag definitions
# +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Name: %{src_name}
Summary: astyle : source code indenter, formatter, and beautifier for the C, C++, C# and Java programming languages
Version: %{src_version}
Release: %{pkg_release}
License: GPLv2
Group: Development/Tools
Source: %{sf_download}/astyle/%{src_tarball}
URL: http://astyle.sourceforge.net
Packager: Shivakumar GN
BuildRoot: %{_tmppath}/%{src_name}-%{version}-build
#Ideally these should be included for requires: glib2, gtk2, pango
#Requires:
#BuildRequires:
%description
Artistic Style is a source code indenter, formatter, and beautifier for the C, C++, C# and Java programming languages.
# +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
# Packages to build
# +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
#%package -n SFE%{src_name}-l10n
#Summary: %{summary} - l10n files
#SUNW_BaseDir: %{_basedir}
#Requires: %{name}
#%package -n SFEgeany-docs
#Summary: %{summary} - documentation, man pages
#SUNW_BaseDir: %{_basedir}
#Requires: %{name}
# +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
# Prep-Section
# +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
%prep
%setup -q -n %{name}
# +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
# Build-Section
# +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
%build
CPUS=`/usr/sbin/psrinfo | grep on-line | wc -l | tr -d ' '`
if test "x$CPUS" = "x" -o $CPUS = 0; then
CPUS=1
fi
export CFLAGS="%optflags"
export CXXFLAGS="%cxx_optflags"
export LDFLAGS="%_ldflags"
cd src
make -j$CPUS
%install
mkdir -p $RPM_BUILD_ROOT/%{_bindir}
install -m 755 -c ./src/astyle $RPM_BUILD_ROOT%{_bindir}/
%clean
rm -rf $RPM_BUILD_ROOT
%files
%defattr(0755,root,bin)
%dir %attr (0755, root, bin) %{_bindir}
%{_bindir}/*
%changelog
* Tue Feb 12 2008 <pradhap (at) gmail.com>
- Bumped up the version to 1.21
* 2007.Aug.08 - <shivakumar dot gn at gmail dot com>