# # spec file for package zip4j # # Copyright (c) 2023 SUSE LLC # # 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 https://bugs.opensuse.org/ # Name: zip4j Version: 2.11.5 Release: 0 Summary: A Java library for zip files and streams License: Apache-2.0 Group: Development/Libraries/Java URL: https://github.com/srikanth-lingala/%{name} Source0: %{url}/archive/refs/tags/v%{version}.tar.gz#/%{name}-%{version}.tar.gz BuildRequires: fdupes BuildRequires: maven-local BuildRequires: mvn(org.apache.felix:maven-bundle-plugin) BuildArch: noarch %description Zip4j is the most comprehensive Java library for zip files or streams. As of this writing, it is the only Java library which has support for zip encryption, apart from several other features. It tries to make handling zip files/streams a lot more easier. No more clunky boiler plate code with input streams and output streams. As you can see in the usage section below, working with zip files can now even be a single line of code, compared to this. I mean no offense to the Java’s built-in zip support. In fact, this library depends on Java’s built-in zip code and it would have been significantly more complicated challenging if I had to write compression logic as well. But lets be honest, working with zip files or streams can be a lot of boiler plate code. The main goal of this library is to provide a simple API for all usual actions of a zip file or streams by doing the heavy lifting within the library and not have developers worry about having to deal with streams, etc. Apart from usability, another important goal of this library is to provide support for as many zip features as possible, which brings me to: • Create, Add, Extract, Update, Remove files from a zip file • Support for streams (ZipInputStream and ZipOutputStream) • Read/Write password protected zip files and streams • Support for both AES and zip standard encryption methods • Support for Zip64 format • Store (No Compression) and Deflate compression method • Create or extract files from split zip files (Ex: z01, z02,...zip) • Support for Unicode file names and comments in zip • Progress Monitor - for integration into apps and user facing applications %package javadoc Summary: API documentation for %{name} Group: Documentation/HTML %description javadoc API documentation for %{name}. %prep %setup -q %pom_remove_plugin org.sonatype.plugins:nexus-staging-maven-plugin %pom_remove_plugin :maven-failsafe-plugin %{mvn_file} : %{name} %build %{mvn_build} -f -- \ -Dproject.build.outputTimestamp=$(date -u -d @${SOURCE_DATE_EPOCH:-$(date +%%s)} +%%Y-%%m-%%dT%%H:%%M:%%SZ) \ %if %{?pkg_vcmp:%pkg_vcmp java-devel >= 9}%{!?pkg_vcmp:0} -Dmaven.compiler.release=8 \ %endif -Dsource=8 %install %mvn_install %fdupes %{buildroot}%{_javadocdir}/%{name} %files -f .mfiles %license NOTICE LICENSE %doc README.md %files javadoc -f .mfiles-javadoc %license NOTICE LICENSE %changelog