# # spec file for package josm %global svn_revision 3329 Name: josm Version: 0 Release: 0.5.%{svn_revision}svn%{?dist} Summary: An editor for OpenStreetMap (OSM) Group: Applications/Internet License: GPLv2+ URL: http://josm.openstreetmap.de/ Source0: %{name}-%{version}.%{svn_revision}svn.tar.gz Source1: %{name} Source2: %{name}.desktop Source3: %{name}-generate-tarball.sh Source4: %{name}.1 Source5: REVISION.XML #Source built using the following commands : ./josm-generate-tarball.sh 3329 #remove call to "svn info" and fix in build.xml revision and commit date Patch0: %{name}-%{version}-remove_svn_call.patch #patch to disable oauth, it is needed because oauth requires maven 2.0.9 and a maven > 2.0.8 seels to be only planned for F14 Patch1: %{name}-%{version}-disable_oauth.patch #patch to add javadoc generation in build.xml Patch2: %{name}-%{version}-add_javadoc.patch #patch to use ant.jar (for bzip2) and jakarta-commons-codec Patch3: %{name}-%{version}-bzip2.patch BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n) BuildArch: noarch BuildRequires: jpackage-utils BuildRequires: desktop-file-utils BuildRequires: ant BuildRequires: jakarta-commons-codec >= 1.3 BuildRequires: java-devel >= 1:1.6.0 BuildRequires: gettext BuildRequires: metadata-extractor >= 2.3.1 Requires: java >= 1:1.6.0 Requires: jpackage-utils Requires: hicolor-icon-theme Requires: metadata-extractor >= 2.3.1 %description JOSM is an editor for OpenStreetMap (OSM) written in Java Currently it supports loading stand alone GPX track data from the OSM database, loading and editing existing nodes, ways, metadata tags and relations. OpenStreetMap is a project aimed squarely at creating and providing free geographic data such as street maps to anyone who wants them. The project was started because most maps you think of as free actually have legal or technical restrictions on their use, holding back people from using them in creative, productive or unexpected ways. %package javadoc Summary: Javadocs for %{name} Group: Documentation Requires: %{name} = %{version}-%{release} Requires: jpackage-utils %description javadoc This package contains the API documentation for %{name}. %prep %setup -q %patch0 -p0 %patch1 -p1 %patch2 -p0 %patch3 -p0 find . -name '*.jar' -exec rm -f '{}' \; find . -name '*.class' -exec rm -f '{}' \; ln -s $(build-classpath metadata-extractor) lib/metadata-extractor-2.3.1-nosun.jar iconv -f iso8859-15 -t utf-8 CONTRIBUTION > CONTRIBUTION.conv && mv -f CONTRIBUTION.conv CONTRIBUTION %build ant javadoc ant %install rm -rf %{buildroot} mkdir -p %{buildroot}%{_javadir} mkdir -p %{buildroot}%{_javadocdir}/%{name} cp -rp javadoc \ %{buildroot}%{_javadocdir}/%{name} install -p -m 644 dist/%{name}-custom.jar %{buildroot}%{_javadir}/%{name}-snapshot-%{svn_revision}svn.jar ln -s %{name}-snapshot-%{svn_revision}svn.jar %{buildroot}%{_javadir}/%{name}.jar install -Dp -m 755 %SOURCE1 %{buildroot}%{_bindir}/%{name} install -d %{buildroot}%{_datadir}/icons/hicolor/128x128/apps install -p -m 644 images/logo.png %{buildroot}%{_datadir}/icons/hicolor/128x128/apps/%{name}.png install -Dp -m 644 %SOURCE4 %{buildroot}%{_mandir}/man1/%{name}.1 desktop-file-install --dir=%{buildroot}%{_datadir}/applications/ %SOURCE2 %clean rm -rf %{buildroot} %post touch --no-create %{_datadir}/icons/hicolor &>/dev/null || : %postun if [ $1 -eq 0 ] ; then touch --no-create %{_datadir}/icons/hicolor &>/dev/null gtk-update-icon-cache %{_datadir}/icons/hicolor &>/dev/null || : fi %posttrans gtk-update-icon-cache %{_datadir}/icons/hicolor &>/dev/null || : %files %defattr(-,root,root,-) %doc README LICENSE CONTRIBUTION gpl-2.0.txt gpl-3.0.txt %{_mandir}/man1/%{name}.1.gz %{_javadir}/%{name}-snapshot-%{svn_revision}svn.jar %{_javadir}/%{name}.jar %{_bindir}/%{name} %{_datadir}/applications/%{name}.desktop %{_datadir}/icons/hicolor/128x128/apps/%{name}.png %files javadoc %defattr(-,root,root,-) %{_javadocdir}/%{name} %changelog * Wed Jun 16 2010 Cedric OLIVIER 0-0.5.3329svn - Update to 3329 svn revision * Mon Jun 14 2010 Cedric OLIVIER 0-0.4.3208svn - Convert CONTRIBUTION file from ISO8859-1 to UTF-8 * Fri Jun 11 2010 Cedric OLIVIER 0-0.3.3208svn - Cosmetic Modifications in SPEC file * Thu Jun 03 2010 Cedric OLIVIER 0-0.2.3208svn - Remove an incorrect 755 in install -d directive * Thu May 13 2010 Cedric OLIVIER 0-0.1.3208svn - Update to 3208 svn revision - Remove oauth waiting fedora include maven > 2.0.8 (needed for oauth build) - Change license to GPLv2+ and add GPLv3 to %%doc - Remove bzip2 and codec source to use of ant and jakarta-common-codec package * Sun Mar 14 2010 Cedric OLIVIER 0-0.1.3094svn - Update to 3094 svn revision * Sat Nov 21 2009 Cedric OLIVIER 0-0.3.2255svn - Add ScriptletSnippet for Icon Cache - Change on man page section * Sat Nov 14 2009 Cedric OLIVIER 0-0.2.2255svn - Update of version number according GuideLines * Fri Oct 16 2009 Cedric OLIVIER 0-0.1.2255svn - Update to 2255 svn revision * Fri Oct 09 2009 Cedric OLIVIER 0-0.1.2221svn - Update to 2221 svn revision - Add doc files * Tue Aug 17 2009 Cedric OLIVIER 0-0.2.1788svn - Add josm translation * Sun Aug 02 2009 Cedric OLIVIER 0-0.1.1788svn - Update to 1788 svn revision - Remove jar files from sources * Fri Jun 26 2009 Cedric OLIVIER 0-0.1.1607svn - First release