Compare commits
No commits in common. "rawhide" and "f28" have entirely different histories.
10 changed files with 331 additions and 1 deletions
1
.gitignore
vendored
Normal file
1
.gitignore
vendored
Normal file
|
|
@ -0,0 +1 @@
|
|||
/hdfview-2.13.0-nolibs.tar.xz
|
||||
|
|
@ -1 +0,0 @@
|
|||
Retired: Fails to install
|
||||
22
getsources.sh
Executable file
22
getsources.sh
Executable file
|
|
@ -0,0 +1,22 @@
|
|||
#!/bin/sh -e
|
||||
|
||||
# Usage: ./getsources.sh
|
||||
# (this produces hdfview-%version-nolibs.tar.xz)
|
||||
url="$(rpmspec -P *spec | awk '/^#Source0:/{print $2}')"
|
||||
version="$(rpmspec -q --srpm --qf %{version} *spec)"
|
||||
|
||||
fname="hdfview-${version}-nolibs.tar.xz"
|
||||
if [ -e "$fname" ]; then
|
||||
echo "$fname already exists, not downloading"
|
||||
exit 0
|
||||
fi
|
||||
|
||||
echo "Downloading version ${version}"
|
||||
[ -x /bin/pxz ] && xz=pxz || xz=xz
|
||||
|
||||
curl -sSL $url | \
|
||||
gunzip | \
|
||||
tar --delete --wildcards -f - '*/lib/*' | \
|
||||
$xz -9v > "$fname"
|
||||
|
||||
echo "$fname is ready"
|
||||
17
hdfview
Executable file
17
hdfview
Executable file
|
|
@ -0,0 +1,17 @@
|
|||
#!/bin/sh -e
|
||||
|
||||
CLASSPATH="$CLASSPATH:/usr/share/java/jhdfview.jar"
|
||||
|
||||
CLASSPATH="$CLASSPATH:/usr/lib/java/jhdf.jar:/usr/lib/java/jhdf5.jar"
|
||||
|
||||
CLASSPATH="$CLASSPATH:/usr/share/java/jhdfobj.jar"
|
||||
CLASSPATH="$CLASSPATH:/usr/share/java/slf4j/api.jar:/usr/share/java/slf4j/simple.jar"
|
||||
export CLASSPATH
|
||||
|
||||
LD_LIBRARY_PATH="$LD_LIBRARY_PATH:/usr/lib64/jhdf:/usr/lib64/jhdf5:/usr/lib/jhdf:/usr/lib/jhdf5"
|
||||
export LD_LIBRARY_PATH
|
||||
|
||||
HDF5_DISABLE_VERSION_CHECK=1
|
||||
export HDF5_DISABLE_VERSION_CHECK
|
||||
|
||||
exec java -Xmx1000m hdf.view.HDFView $*
|
||||
26
hdfview-jars.patch
Normal file
26
hdfview-jars.patch
Normal file
|
|
@ -0,0 +1,26 @@
|
|||
diff --git hdfview-2.13.0-Source/build.xml~ hdfview-2.13.0-Source/build.xml
|
||||
index e5c213f319..dc287f0f51 100644
|
||||
--- hdfview-2.13.0-Source/build.xml~
|
||||
+++ hdfview-2.13.0-Source/build.xml
|
||||
@@ -273,15 +273,17 @@
|
||||
</mapper>
|
||||
</pathconvert>
|
||||
|
||||
+ <jar destfile="${jar.dir}/jhdfobj.jar"
|
||||
+ basedir="${classes.dir}"
|
||||
+ includes="hdf/object/*.class hdf/object/h4/** hdf/object/h5/**"
|
||||
+ excludes="examples/** test/** *.log *.h5" />
|
||||
+
|
||||
<jar destfile="${jar.dir}/${ant.project.name}.jar"
|
||||
basedir="${classes.dir}"
|
||||
- excludes="examples/** test/** *.log *.h5">
|
||||
- <zipgroupfileset dir="lib"
|
||||
- includes="jarhdf*.jar" />
|
||||
+ excludes="examples/** test/** *.log *.h5 hdf/object/**">
|
||||
|
||||
<manifest>
|
||||
<attribute name="Main-Class" value="${main-class}" />
|
||||
- <attribute name="Class-Path" value="${manifest.classpath}" />
|
||||
</manifest>
|
||||
</jar>
|
||||
</target>
|
||||
30
hdfview.appdata.xml
Normal file
30
hdfview.appdata.xml
Normal file
|
|
@ -0,0 +1,30 @@
|
|||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<!-- Copyright 2016 Zbigniew Jędrzejewski-Szmek <zbyszek@in.waw.pl> -->
|
||||
|
||||
<application>
|
||||
<name>HDFView</name>
|
||||
<id type="desktop">hdfview.desktop</id>
|
||||
<metadata_license>CC0-1.0</metadata_license>
|
||||
<summary>Java HDF5 Object viewer</summary>
|
||||
<update_contact>zbyszek@in.waw.pl</update_contact>
|
||||
<translation>https://bugzilla.redhat.com/enter_bug.cgi?product=Fedora&component=hdfview</translation>
|
||||
<description>
|
||||
<p>
|
||||
HDF is a versatile data model that can represent very complex data objects
|
||||
and a wide variety of meta-data. It is a completely portable file format
|
||||
with no limit on the number or size of data objects in the collection.
|
||||
</p>
|
||||
<p>
|
||||
HDFView is a graphical viewer with the ability to load multiple HDF5 files.
|
||||
It shows a tree of objects inside the file and allows individual objects to
|
||||
be displayed. Tables of numbers are displayed as in a spreadsheet, and
|
||||
images are shown graphically.
|
||||
</p>
|
||||
</description>
|
||||
<url type="homepage">https://support.hdfgroup.org/products/java/</url>
|
||||
<screenshots>
|
||||
<screenshot width="1200" height="675" type="default">http://in.waw.pl/~zbyszek/fedora/hdfview/hdfview-multiple-tables.png</screenshot>
|
||||
<screenshot width="1200" height="675">http://in.waw.pl/~zbyszek/fedora/hdfview/hdfview-table.png</screenshot>
|
||||
<screenshot width="1200" height="675">http://in.waw.pl/~zbyszek/fedora/hdfview/hdfview-map-of-world.png</screenshot>
|
||||
</screenshots>
|
||||
</application>
|
||||
15
hdfview.desktop
Normal file
15
hdfview.desktop
Normal file
|
|
@ -0,0 +1,15 @@
|
|||
[Desktop Entry]
|
||||
Name=HDFView
|
||||
Name[de]=HDFView
|
||||
Name[en]=HDFView
|
||||
Comment=HDF4/5 Data Browser
|
||||
Comment[DE]=HDF4/5 Daten Browser
|
||||
Comment[EN]=HDF4/5 Data Browser
|
||||
Exec=/usr/bin/hdfview %F
|
||||
Icon=hdfview
|
||||
Terminal=false
|
||||
MimeType=application/x-hdf;application/x-hdf5;
|
||||
Type=Application
|
||||
X-MultipleArgs=true
|
||||
Categories=Science;Physics;DataVisualization;Education;
|
||||
|
||||
204
hdfview.spec
Normal file
204
hdfview.spec
Normal file
|
|
@ -0,0 +1,204 @@
|
|||
Name: hdfview
|
||||
Version: 2.13.0
|
||||
Release: 5%{?dist}
|
||||
Summary: Java HDF5 Object viewer
|
||||
|
||||
License: BSD with advertising
|
||||
URL: https://support.hdfgroup.org/products/java/
|
||||
#Source0: https://support.hdfgroup.org/ftp/HDF5/hdf-java/current/src/hdfview-%{version}-Source.tar.gz
|
||||
Source0: hdfview-%{version}-nolibs.tar.xz
|
||||
Source1: hdfview
|
||||
Source2: hdfview.xml
|
||||
Source3: hdfview.desktop
|
||||
Source4: hdfview.appdata.xml
|
||||
|
||||
# ./getsources.sh will download Source0 and remove bundled libs
|
||||
Source9: getsources.sh
|
||||
|
||||
# Upstream creates a single jar with both the jhdfobj interface and
|
||||
# the HDFView parts. Split that into separate jars.
|
||||
Patch0: hdfview-jars.patch
|
||||
|
||||
BuildRequires: maven-local
|
||||
BuildRequires: ant
|
||||
BuildRequires: mvn(org.hdfgroup:jhdf) >= 3.2.1
|
||||
BuildRequires: mvn(org.hdfgroup:jhdf5) >= 3.2.1
|
||||
BuildRequires: mvn(gov.nasa.gsfc.heasarc:nom-tam-fits)
|
||||
BuildRequires: mvn(edu.ucar:cdm)
|
||||
BuildRequires: mvn(org.slf4j:slf4j-api)
|
||||
BuildRequires: mvn(org.slf4j:slf4j-nop)
|
||||
BuildRequires: ImageMagick
|
||||
BuildRequires: libappstream-glib
|
||||
BuildRequires: desktop-file-utils
|
||||
|
||||
Requires: java
|
||||
Requires: javapackages-tools
|
||||
Requires: mvn(org.slf4j:slf4j-api)
|
||||
Requires: mvn(org.slf4j:slf4j-simple)
|
||||
Requires: mvn(org.hdfgroup:jhdf) >= 3.2.1
|
||||
Requires: mvn(org.hdfgroup:jhdf5) >= 3.2.1
|
||||
Requires: mvn(gov.nasa.gsfc.heasarc:nom-tam-fits)
|
||||
Requires: mvn(edu.ucar:cdm)
|
||||
Requires: jhdfobj = %{version}-%{release}
|
||||
Requires: hicolor-icon-theme
|
||||
|
||||
Requires(post): desktop-file-utils
|
||||
Requires(postun): desktop-file-utils
|
||||
|
||||
BuildArch: noarch
|
||||
|
||||
%description
|
||||
HDF is a versatile data model that can represent very complex data objects
|
||||
and a wide variety of meta-data. It is a completely portable file format
|
||||
with no limit on the number or size of data objects in the collection.
|
||||
|
||||
This package provides a HDF4/HDF5 viewer.
|
||||
|
||||
%package -n jhdfobj
|
||||
Summary: Java HDF/HDF5 Object Package
|
||||
Requires: javapackages-tools
|
||||
Requires: mvn(org.hdfgroup:jhdf)
|
||||
Requires: mvn(org.hdfgroup:jhdf5)
|
||||
Requires: mvn(org.slf4j:slf4j-api)
|
||||
|
||||
%description -n jhdfobj
|
||||
HDF is a versatile data model that can represent very complex data objects
|
||||
and a wide variety of meta-data. It is a completely portable file format
|
||||
with no limit on the number or size of data objects in the collection.
|
||||
|
||||
This Java package implements HDF4/HDF5 data objects in an
|
||||
object-oriented form. It provides a common Java API for accessing HDF files.
|
||||
|
||||
%package doc
|
||||
Summary: Sample files and example code for %{name}
|
||||
Enhances: %{name}
|
||||
Requires: %{name}-javadoc
|
||||
|
||||
%description doc
|
||||
%{summary}.
|
||||
|
||||
%package javadoc
|
||||
Summary: API documentation for %{name}
|
||||
|
||||
%description javadoc
|
||||
%{summary}.
|
||||
|
||||
%prep
|
||||
%autosetup -n hdfview-%{version}-Source
|
||||
|
||||
# build jar repo
|
||||
mkdir -p lib/extra
|
||||
build-jar-repository -p lib/ junit slf4j- jhdf jhdf5 nom-tam-fits thredds/cdm
|
||||
ln -s slf4j-api.jar lib/slf4j-api-1.7.5.jar
|
||||
ln -s slf4j-nop.jar lib/slf4j-nop-1.7.5.jar
|
||||
ln -s nom-tam-fits.jar lib/fits.jar
|
||||
ln -s jhdf.jar lib/jarhdf.jar
|
||||
ln -s jhdf5.jar lib/jarhdf5.jar
|
||||
ln -s thredds_cdm.jar lib/netcdf.jar
|
||||
|
||||
# simulate the settings files
|
||||
echo 'HDF4 Version: %_hdf5_version' >lib/libhdf4.settings
|
||||
echo 'HDF5 Version: %_hdf5_version' >lib/libhdf5.settings
|
||||
|
||||
# artifacts location
|
||||
%mvn_package org.hdfgroup:jhdfobj jhdfobj
|
||||
%mvn_file org.hdfgroup:jhdfobj jhdfobj
|
||||
%mvn_package org.hdfgroup:jhdfview jhdfview
|
||||
%mvn_file org.hdfgroup:jhdfview jhdfview
|
||||
|
||||
echo hdf.lib.dir=$(pwd)/lib >> build.properties
|
||||
|
||||
%build
|
||||
ant jar
|
||||
ant javadoc
|
||||
|
||||
%install
|
||||
# jars and depmap
|
||||
%mvn_artifact org.hdfgroup:jhdfobj:%{version} build/jar/jhdfobj.jar
|
||||
%mvn_artifact org.hdfgroup:jhdfview:%{version} build/jar/HDFView.jar
|
||||
%mvn_install -J build/javadocs
|
||||
|
||||
install -Dpm0755 %{SOURCE1} -t %{buildroot}%{_bindir}/
|
||||
|
||||
# Create and install hicolor icons.
|
||||
for i in 16 22 32 48 ; do
|
||||
mkdir -p icons/${i}x${i}/apps
|
||||
convert -resize ${i}x${i} src/hdf/view/icons/hdf_large.gif \
|
||||
icons/${i}x${i}/apps/hdfview.png
|
||||
|
||||
install -Dpm 0644 icons/${i}x${i}/apps/hdfview.png \
|
||||
%{buildroot}%{_datadir}/icons/hicolor/${i}x${i}/apps/hdfview.png
|
||||
|
||||
install -Dpm 0644 icons/${i}x${i}/apps/hdfview.png \
|
||||
%{buildroot}%{_datadir}/icons/hicolor/${i}x${i}/mimetypes/application-x-hdf.png
|
||||
|
||||
done
|
||||
|
||||
# .desktop file
|
||||
mkdir -p %{buildroot}%{_datadir}/applications
|
||||
desktop-file-install \
|
||||
--dir %{buildroot}%{_datadir}/applications \
|
||||
%{SOURCE3}
|
||||
|
||||
# mime types
|
||||
install -Dpm644 -t %{buildroot}%{_datadir}/mime/packages/ %{SOURCE2}
|
||||
|
||||
# appdata
|
||||
install -Dpm644 -t %{buildroot}%{_datadir}/appdata/ %{SOURCE4}
|
||||
|
||||
rm src/examples/testfiles/*.txt
|
||||
|
||||
%check
|
||||
appstream-util validate-relax --nonet %{buildroot}/%{_datadir}/appdata/*.appdata.xml
|
||||
|
||||
%global _docdir_fmt %{name}
|
||||
|
||||
%files -f .mfiles-jhdfview
|
||||
%_bindir/hdfview
|
||||
%{_datadir}/applications/hdfview.desktop
|
||||
%{_datadir}/icons/hicolor/*/*/*.png
|
||||
%dir %{_datadir}/mime
|
||||
%dir %{_datadir}/mime/packages
|
||||
%{_datadir}/mime/packages/hdfview.xml
|
||||
%{_datadir}/appdata/hdfview.appdata.xml
|
||||
|
||||
%files -n jhdfobj -f .mfiles-jhdfobj
|
||||
%doc Readme.txt docs/RELEASE.txt
|
||||
# other docs are very outdated, stuff that's on the web seems better
|
||||
%license COPYING
|
||||
|
||||
%files doc
|
||||
%doc samples/
|
||||
%doc src/examples/
|
||||
%license COPYING
|
||||
|
||||
%files javadoc -f .mfiles-javadoc
|
||||
%license COPYING
|
||||
|
||||
%changelog
|
||||
* Wed Feb 07 2018 Fedora Release Engineering <releng@fedoraproject.org> - 2.13.0-5
|
||||
- Rebuilt for https://fedoraproject.org/wiki/Fedora_28_Mass_Rebuild
|
||||
|
||||
* Thu Jan 11 2018 Igor Gnatenko <ignatenkobrain@fedoraproject.org> - 2.13.0-4
|
||||
- Remove obsolete scriptlets
|
||||
|
||||
* Wed Jul 26 2017 Fedora Release Engineering <releng@fedoraproject.org> - 2.13.0-3
|
||||
- Rebuilt for https://fedoraproject.org/wiki/Fedora_27_Mass_Rebuild
|
||||
|
||||
* Fri Feb 10 2017 Fedora Release Engineering <releng@fedoraproject.org> - 2.13.0-2
|
||||
- Rebuilt for https://fedoraproject.org/wiki/Fedora_26_Mass_Rebuild
|
||||
|
||||
* Thu Dec 15 2016 Zbigniew Jędrzejewski-Szmek <zbyszek@in.waw.pl> - 2.13.0-1
|
||||
- Also add /usr/share/mime, /usr/share/mime/packages to %%files
|
||||
|
||||
* Tue Dec 13 2016 Zbigniew Jędrzejewski-Szmek <zbyszek@in.waw.pl> - 2.13.0-1
|
||||
- Add versioned requirement on jhdf5 in hdfview binary package
|
||||
- New javadoc subpackage
|
||||
- Fix ownership issues in icons directory
|
||||
- Exclude text files in examples/testfiles
|
||||
|
||||
* Sat Dec 10 2016 Zbigniew Jędrzejewski-Szmek <zbyszek@in.waw.pl> - 2.13.0-1
|
||||
- Fix BuildRequires
|
||||
|
||||
* Thu Dec 8 2016 Zbigniew Jędrzejewski-Szmek <zbyszek@in.waw.pl> - 2.13.0-1
|
||||
- Initial split from jhdf5
|
||||
15
hdfview.xml
Normal file
15
hdfview.xml
Normal file
|
|
@ -0,0 +1,15 @@
|
|||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<mime-info xmlns="http://www.freedesktop.org/standards/shared-mime-info">
|
||||
<mime-type type="application/x-hdf">
|
||||
<comment xml:lang="en">HDF files</comment>
|
||||
<glob pattern="*.hdf" />
|
||||
<glob pattern="*.h4" />
|
||||
<glob pattern="*.hdf4" />
|
||||
</mime-type>
|
||||
<mime-type type="application/x-hdf5">
|
||||
<comment xml:lang="en">HDF5 files</comment>
|
||||
<glob pattern="*.h5" />
|
||||
<glob pattern="*.hdf5" />
|
||||
</mime-type>
|
||||
</mime-info>
|
||||
|
||||
1
sources
Normal file
1
sources
Normal file
|
|
@ -0,0 +1 @@
|
|||
SHA512 (hdfview-2.13.0-nolibs.tar.xz) = b054e4c6491100b14d1331069b7f7e554f64f718a04cf1483ca7dd71981cdb772d977b02d1a912a7069ab53053ae16c860e8d972bba37d2a870e38340edbbc94
|
||||
Loading…
Add table
Add a link
Reference in a new issue