File jgoodies-looks.spec of Package jgoodies-looks

#
# spec file for package jgoodies-looks (Version 1.3.2)
#
# Copyright (c) 2008 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

%define _shortname looks

Name:           jgoodies-looks
Summary:        JGoodies Windows l&f and Plastic l&f family
Url:            http://www.jgoodies.com 
Group:          Development/Libraries/Java
Version:        1.3.2
Release:        2
License:        BSD 3-Clause
BuildRequires:  ant
BuildRequires:  java-devel
BuildRequires:  jgoodies-forms >= 1.0.5
BuildRequires:  jpackage-utils >= 1.5
BuildRequires:  update-alternatives
BuildRequires:  xml-commons-apis
BuildRequires:  xml-commons-resolver
Requires:       jre >= 1.5
Requires:       jgoodies-forms >= 1.0.5
BuildArch:      noarch
BuildRoot:      %{_tmppath}/%{name}-%{version}-build
Source0:        %{_shortname}-%{version}.tar.bz2
Patch0:         %{name}-default.properties.diff

%description
The JGoodies Looks make your Swing applications and applets look
better. The package consists of a Windows look&feel and the Plastic
look&feel family.

These have been optimized for readability, precise micro-design and
usability.



Authors:
--------
    Karsten Lentzsch

%package javadoc
License:        BSD 3-Clause
Summary:        JGoodies Windows l&f and Plastic l&f family
Group:          Development/Libraries/Java

%description javadoc
The JGoodies Looks make your Swing applications and applets look
better. The package consists of a Windows look&feel and the Plastic
look&feel family.

These have been optimized for readability, precise micro-design and
usability.



Authors:
--------
    Karsten Lentzsch

%package manual
License:        BSD 3-Clause
Summary:        jgoodies-forms
Group:          Development/Languages/Java

%description manual
The Forms framework helps you lay out and implement elegant Swing
panels quickly and consistently. It makes simple things easy and the
hard stuff possible, the good design easy and the bad difficult.

Main Benefits: * Powerful, flexible and precise layout

* Easy to work with and quite easy to learn

* Faster UI production

* Better UI code readability

* Leads to better style guide compliance



Authors:
--------
    Karsten Lentzsch

%package demo
License:        BSD 3-Clause
Summary:        JGoodies Windows l&f and Plastic l&f family
Group:          Development/Libraries/Java
Requires:       %{name} = %{version}

%description demo
The JGoodies Looks make your Swing applications and applets look
better. The package consists of a Windows look&feel and the Plastic
look&feel family.

These have been optimized for readability, precise micro-design and
usability.



Authors:
--------
    Karsten Lentzsch

%prep
%setup -q -n %{_shortname}-%{version}
%patch0 -p0
%__mkdir -p src/plastic
%__mkdir -p src/windows
# wrong end of line encoding
sed -i -e 's/.$//' LICENSE.txt README.html RELEASE-NOTES.txt
find docs -iname '*.html' | xargs sed -i -e 's/.$//'

%build
%ant compile jar javadoc

%install
# jars
%__install -dm 755 %{buildroot}%{_javadir}
%__install -pm 644 build/%{_shortname}.jar \
	%{buildroot}%{_javadir}/%{_shortname}-%{version}.jar
pushd %{buildroot}%{_javadir}
	for jar in *-%{version}*; do
		ln -sf ${jar} `echo $jar| sed "s|-%{version}||g"`
	done
popd
# javadoc
%__install -dm 755 %{buildroot}%{_javadocdir}/%{name}-%{version}
%__cp -pr build/docs/api/* %{buildroot}%{_javadocdir}/%{name}-%{version}
ln -s %{name}-%{version} %{buildroot}%{_javadocdir}/%{name} # ghost symlink
# demo
%__install -dm 755 %{buildroot}%{_datadir}/%{name}
%__install -pm 644 build/demo.jar %{buildroot}%{_datadir}/%{name}
%__install -pm 644 build/tiny.jar %{buildroot}%{_datadir}/%{name}

%clean
[ -d %{buildroot} -a "%{buildroot}" != "" ] && %__rm -rf %{buildroot}

%files
%defattr(-,root,root)
%{_javadir}/%{_shortname}*.jar
%doc LICENSE.txt README.html RELEASE-NOTES.txt

%files javadoc
%defattr(-,root,root)
%doc %{_javadocdir}/%{name}-%{version}
%doc %{_javadocdir}/%{name}

%files manual
%defattr(-,root,root,-)
%doc docs/faq.html docs/netbeans.html docs/guide/ docs/images/ docs/quickstart.html docs/tips.html

%files demo
%defattr(-,root,root,-)
%doc docs/examples.html docs/style.css docs/guide/ docs/images/
%{_datadir}/%{name}

%changelog
* Tue Aug 19 2008 mvyskocil@suse.cz
- Initial packaging of 1.3.2 (thanks to Packman)