1 | %define ver 1.0.1 |
---|
2 | %define rel 1 |
---|
3 | |
---|
4 | Name: libwebp |
---|
5 | Version: %{ver} |
---|
6 | Release: %{rel}%{?_dist_release} |
---|
7 | Group: System Environment/Libraries |
---|
8 | |
---|
9 | Vendor: Project Vine |
---|
10 | Distribution: Vine Linux |
---|
11 | |
---|
12 | URL: http://webmproject.org/ |
---|
13 | Summary: Library and tools for the WebP graphics format |
---|
14 | Summary(ja): WebP 画像フォーマットのためのライブラリとツール |
---|
15 | # Additional IPR is licensed as well. See PATENTS file for details |
---|
16 | License: BSD |
---|
17 | Source0: https://storage.googleapis.com/downloads.webmproject.org/releases/webp/libwebp-%{version}.tar.gz |
---|
18 | Source1: libwebp_jni_example.java |
---|
19 | |
---|
20 | BuildRoot: %{_tmppath}/%{name}-%{version}-root |
---|
21 | BuildRequires: libjpeg-devel |
---|
22 | BuildRequires: libpng-devel |
---|
23 | BuildRequires: libtool |
---|
24 | BuildRequires: java-1.8.0-openjdk-devel |
---|
25 | BuildRequires: jpackage-utils |
---|
26 | BuildRequires: swig |
---|
27 | BuildRequires: freeglut-devel |
---|
28 | |
---|
29 | %description |
---|
30 | WebP is an image format that does lossy compression of digital |
---|
31 | photographic images. WebP consists of a codec based on VP8, and a |
---|
32 | container based on RIFF. Webmasters, web developers and browser |
---|
33 | developers can use WebP to compress, archive and distribute digital |
---|
34 | images more efficiently. |
---|
35 | |
---|
36 | %package tools |
---|
37 | Summary: The WebP command line tools |
---|
38 | Summary(ja): WebP コマンドラインツール |
---|
39 | Group: Development/Tools |
---|
40 | |
---|
41 | %description tools |
---|
42 | WebP is an image format that does lossy compression of digital |
---|
43 | photographic images. WebP consists of a codec based on VP8, and a |
---|
44 | container based on RIFF. Webmasters, web developers and browser |
---|
45 | developers can use WebP to compress, archive and distribute digital |
---|
46 | images more efficiently. |
---|
47 | |
---|
48 | %package devel |
---|
49 | Summary: Development files for libwebp, a library for the WebP format |
---|
50 | Summary(ja): WebP フォーマットのためのライブラリ libwebp の開発ファイル |
---|
51 | Group: Development/Libraries |
---|
52 | Requires: %{name} = %{version}-%{release} |
---|
53 | |
---|
54 | %description devel |
---|
55 | WebP is an image format that does lossy compression of digital |
---|
56 | photographic images. WebP consists of a codec based on VP8, and a |
---|
57 | container based on RIFF. Webmasters, web developers and browser |
---|
58 | developers can use WebP to compress, archive and distribute digital |
---|
59 | images more efficiently. |
---|
60 | |
---|
61 | %package java |
---|
62 | Summary: Java bindings for libwebp, a library for the WebP format |
---|
63 | Summary(ja): WebP フォーマットのためのライブラリ libwebp の Java バインディング |
---|
64 | Group: Development/Libraries |
---|
65 | Requires: %{name} = %{version}-%{release} |
---|
66 | Requires: java |
---|
67 | Requires: jpackage-utils |
---|
68 | |
---|
69 | %description java |
---|
70 | Java bindings for libwebp. |
---|
71 | |
---|
72 | Vendor: Project Vine |
---|
73 | Distribution: Vine Linux |
---|
74 | Packager: iwaim |
---|
75 | |
---|
76 | %prep |
---|
77 | %setup -q |
---|
78 | |
---|
79 | %build |
---|
80 | %global optflags %{optflags} -fPIC |
---|
81 | |
---|
82 | mkdir -p m4 |
---|
83 | ./autogen.sh |
---|
84 | %configure --disable-static --enable-libwebpmux \ |
---|
85 | --enable-libwebpdemux --enable-libwebpdecoder \ |
---|
86 | --disable-neon |
---|
87 | make %{?_smp_mflags} |
---|
88 | |
---|
89 | # swig generated Java bindings |
---|
90 | cp %{SOURCE1} . |
---|
91 | cd swig |
---|
92 | rm -rf libwebp.jar libwebp_java_wrap.c |
---|
93 | mkdir -p java/com/google/webp |
---|
94 | swig -ignoremissing -I../src -java \ |
---|
95 | -package com.google.webp \ |
---|
96 | -outdir java/com/google/webp \ |
---|
97 | -o libwebp_java_wrap.c libwebp.swig |
---|
98 | |
---|
99 | gcc %{optflags} -shared \ |
---|
100 | -I/usr/lib/jvm/java/include \ |
---|
101 | -I/usr/lib/jvm/java/include/linux \ |
---|
102 | -I../src \ |
---|
103 | -L../src/.libs -lwebp libwebp_java_wrap.c \ |
---|
104 | -o libwebp_jni.so |
---|
105 | |
---|
106 | cd java |
---|
107 | javac com/google/webp/libwebp.java |
---|
108 | jar cvf ../libwebp.jar com/google/webp/*.class |
---|
109 | |
---|
110 | %install |
---|
111 | make install DESTDIR=%{buildroot} |
---|
112 | find "%{buildroot}/%{_libdir}" -type f -name "*.la" -delete |
---|
113 | |
---|
114 | # swig generated Java bindings |
---|
115 | mkdir -p %{buildroot}/%{_libdir}/%{name}-java |
---|
116 | cp swig/*.jar swig/*.so %{buildroot}/%{_libdir}/%{name}-java/ |
---|
117 | |
---|
118 | %post -n %{name} -p /sbin/ldconfig |
---|
119 | |
---|
120 | %postun -n %{name} -p /sbin/ldconfig |
---|
121 | |
---|
122 | %files tools |
---|
123 | %{_bindir}/* |
---|
124 | %{_mandir}/man*/* |
---|
125 | |
---|
126 | %files -n %{name} |
---|
127 | %license COPYING |
---|
128 | %doc README PATENTS NEWS AUTHORS |
---|
129 | %{_libdir}/%{name}*.so.* |
---|
130 | |
---|
131 | %files devel |
---|
132 | %{_libdir}/%{name}*.so |
---|
133 | %{_includedir}/* |
---|
134 | %{_libdir}/pkgconfig/* |
---|
135 | |
---|
136 | %files java |
---|
137 | %doc libwebp_jni_example.java |
---|
138 | %{_libdir}/%{name}-java/ |
---|
139 | |
---|
140 | %changelog |
---|
141 | * Thu Jan 03 2019 Tomohiro "Tomo-p" KATO <tomop@teamgedoh.net> 1.0.1-1 |
---|
142 | - new upstream release. |
---|
143 | |
---|
144 | * Sun Oct 12 2014 Ryoichi INAGAKI <ryo1@toki.waseda.jp> 0.3.1-3 |
---|
145 | - moved libwebp to System Environment/Libraries Group |
---|
146 | |
---|
147 | * Tue Jul 15 2014 Yoji TOYODA <bsyamato@sea.plala.or.jp> 0.3.1-2 |
---|
148 | - rebuild with libpng-1.6.12 |
---|
149 | |
---|
150 | * Sat Oct 12 2013 Toshiharu Kudoh <toshi.kd2@gmail.com> 0.3.1-1 |
---|
151 | - new upstream release |
---|
152 | |
---|
153 | * Sat Jan 12 2013 IWAI, Masaharu <iwai@alib.jp> 0.2.1-1 |
---|
154 | - initial build for Vine Linux |
---|
155 | |
---|
156 | * Thu Dec 27 2012 Rahul Sundaram <sundaram@fedoraproject.org> - 0.2.1-1 |
---|
157 | - new upstream release 0.2.1 |
---|
158 | |
---|
159 | * Fri Dec 21 2012 Adam Tkac <atkac redhat com> - 0.1.3-3 |
---|
160 | - rebuild against new libjpeg |
---|
161 | |
---|
162 | * Thu Jul 19 2012 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 0.1.3-2 |
---|
163 | - Rebuilt for https://fedoraproject.org/wiki/Fedora_18_Mass_Rebuild |
---|
164 | |
---|
165 | * Thu Feb 02 2012 Rahul Sundaram <sundaram@fedoraproject.org> - 0.1.3-1 |
---|
166 | - Several spec improvements by Scott Tsai <scottt.tw@gmail.com> |
---|
167 | |
---|
168 | * Wed May 25 2011 Rahul Sundaram <sundaram@fedoraproject.org> - 0.1.2-1 |
---|
169 | - Initial spec. Based on openSUSE one |
---|
170 | |
---|