]>
Commit | Line | Data |
---|---|---|
e4496910 ER |
1 | # |
2 | # Conditional build: | |
e03499dd ER |
3 | %bcond_without ffmpeg # build with ffmpeg for thumbnails and previews |
4 | %bcond_without freeimage # build with freeimage to manage thumbnails/previews | |
f7ed37d0 ER |
5 | %bcond_without fuse # build megafuse |
6 | %bcond_without libmediainfo # build with libmediainfo for media file attributes | |
e4496910 | 7 | |
87cee7c0 ER |
8 | Summary: Command Line Interactive and Scriptable Application to access MEGA |
9 | Name: megacmd | |
22621376 ER |
10 | Version: 1.1.0 |
11 | Release: 1 | |
c1b11adc ER |
12 | # https://github.com/meganz/MEGAcmd/commit/b366c77370c277223be123e05e5ef15fafbce185#r31261647 |
13 | License: BSD 2-Clause "Simplified" License | |
87cee7c0 | 14 | Group: Applications |
22621376 ER |
15 | Source0: https://github.com/meganz/MEGAcmd/archive/%{version}_Linux/%{name}-%{version}.tar.gz |
16 | # Source0-md5: 533eaddbb893d5e1a614109cbb78c9a9 | |
17 | Source1: https://github.com/meganz/sdk/archive/2c7713d/mega-sdk-v3.4.8.tar.gz | |
18 | # Source1-md5: 73218bcc1c5c1cbfbaf6923ad5938427 | |
87cee7c0 | 19 | URL: https://mega.nz/ |
e03499dd | 20 | %{?with_freeimage:BuildRequires: FreeImage-devel} |
b33e7950 ER |
21 | BuildRequires: autoconf |
22 | BuildRequires: automake | |
23 | BuildRequires: c-ares-devel | |
b33e7950 | 24 | BuildRequires: cryptopp-devel |
f7ed37d0 | 25 | %{?with_ffmpeg:BuildRequires: ffmpeg-devel} |
e4496910 | 26 | %{?with_fuse:BuildRequires: libfuse-devel} |
7b4a00eb | 27 | %{?with_mediainfo:BuildRequires: libmediainfo-devel} |
b33e7950 ER |
28 | BuildRequires: libraw-devel |
29 | BuildRequires: libsodium-devel | |
30 | BuildRequires: libstdc++-devel | |
31 | BuildRequires: libtool | |
32 | BuildRequires: libuv-devel | |
b33e7950 ER |
33 | BuildRequires: openssl-devel |
34 | BuildRequires: pcre-cxx-devel | |
35 | BuildRequires: pcre-devel | |
36 | BuildRequires: pkgconfig | |
37 | BuildRequires: readline-devel | |
38 | BuildRequires: sqlite3-devel | |
39 | BuildRequires: zlib-devel | |
8e4e3a4f | 40 | Requires: %{name}-libs = %{version}-%{release} |
87cee7c0 ER |
41 | BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n) |
42 | ||
43 | %description | |
44 | MEGAcmd provides non UI access to MEGA services. It intends to offer | |
45 | all the functionality with your MEGA account via commands. It features | |
46 | synchronization and backup of local folders into your MEGA account. | |
47 | ||
8e4e3a4f ER |
48 | %package libs |
49 | Summary: Shared libmega library | |
50 | Group: Libraries | |
e4496910 | 51 | Requires: %{name}-libs = %{version}-%{release} |
8e4e3a4f ER |
52 | |
53 | %description libs | |
54 | Shared libmega library. | |
55 | ||
56 | %package devel | |
57 | Summary: Header files for %{name} library | |
58 | Summary(pl.UTF-8): Pliki nagłówkowe biblioteki %{name} | |
59 | Group: Development/Libraries | |
60 | Requires: %{name}-libs = %{version}-%{release} | |
61 | ||
62 | %description devel | |
63 | Header files for %{name} library. | |
64 | ||
65 | %description devel -l pl.UTF-8 | |
66 | Pliki nagłówkowe biblioteki %{name}. | |
67 | ||
e4496910 ER |
68 | %package fuse |
69 | Summary: megafuse | |
70 | Group: Libraries | |
71 | ||
72 | %description fuse | |
73 | megafuse. | |
74 | ||
87cee7c0 | 75 | %prep |
22621376 | 76 | %setup -q -n MEGAcmd-%{version}_Linux -a1 |
87cee7c0 | 77 | mv sdk-*/* sdk |
87cee7c0 ER |
78 | |
79 | %build | |
80 | autoreconf -vif | |
81 | %configure \ | |
cce502db | 82 | ac_cv_prog_HAVE_CPPCHECK=/usr/bin/cppcheck \ |
f7ed37d0 | 83 | %{__with_without ffmpeg} \ |
e03499dd | 84 | %{__with_without freeimage} \ |
6773bcd0 | 85 | %{__with_without fuse} \ |
7b4a00eb | 86 | %{__with_without libmediainfo} \ |
87cee7c0 ER |
87 | --disable-silent-rules |
88 | %{__make} | |
89 | ||
90 | %install | |
91 | rm -rf $RPM_BUILD_ROOT | |
92 | %{__make} install \ | |
93 | DESTDIR=$RPM_BUILD_ROOT | |
94 | ||
8e4e3a4f ER |
95 | %{__rm} $RPM_BUILD_ROOT%{_libdir}/libmega.la |
96 | ||
87cee7c0 ER |
97 | %clean |
98 | rm -rf $RPM_BUILD_ROOT | |
99 | ||
8e4e3a4f ER |
100 | %post libs -p /sbin/ldconfig |
101 | %postun libs -p /sbin/ldconfig | |
102 | ||
87cee7c0 ER |
103 | %files |
104 | %defattr(644,root,root,755) | |
8e4e3a4f ER |
105 | %doc README.md LICENSE |
106 | /etc/bash_completion.d/megacmd_completion.sh | |
107 | %attr(755,root,root) %{_bindir}/mega-attr | |
108 | %attr(755,root,root) %{_bindir}/mega-backup | |
109 | %attr(755,root,root) %{_bindir}/mega-cancel | |
22621376 | 110 | %attr(755,root,root) %{_bindir}/mega-cat |
8e4e3a4f ER |
111 | %attr(755,root,root) %{_bindir}/mega-cd |
112 | %attr(755,root,root) %{_bindir}/mega-cmd | |
113 | %attr(755,root,root) %{_bindir}/mega-cmd-server | |
114 | %attr(755,root,root) %{_bindir}/mega-confirm | |
115 | %attr(755,root,root) %{_bindir}/mega-confirmcancel | |
116 | %attr(755,root,root) %{_bindir}/mega-cp | |
117 | %attr(755,root,root) %{_bindir}/mega-debug | |
118 | %attr(755,root,root) %{_bindir}/mega-deleteversions | |
22621376 | 119 | %attr(755,root,root) %{_bindir}/mega-df |
8e4e3a4f ER |
120 | %attr(755,root,root) %{_bindir}/mega-du |
121 | %attr(755,root,root) %{_bindir}/mega-errorcode | |
122 | %attr(755,root,root) %{_bindir}/mega-exclude | |
123 | %attr(755,root,root) %{_bindir}/mega-exec | |
124 | %attr(755,root,root) %{_bindir}/mega-export | |
125 | %attr(755,root,root) %{_bindir}/mega-find | |
126 | %attr(755,root,root) %{_bindir}/mega-ftp | |
127 | %attr(755,root,root) %{_bindir}/mega-get | |
128 | %attr(755,root,root) %{_bindir}/mega-graphics | |
129 | %attr(755,root,root) %{_bindir}/mega-help | |
130 | %attr(755,root,root) %{_bindir}/mega-https | |
131 | %attr(755,root,root) %{_bindir}/mega-import | |
132 | %attr(755,root,root) %{_bindir}/mega-invite | |
133 | %attr(755,root,root) %{_bindir}/mega-ipc | |
134 | %attr(755,root,root) %{_bindir}/mega-killsession | |
135 | %attr(755,root,root) %{_bindir}/mega-lcd | |
136 | %attr(755,root,root) %{_bindir}/mega-log | |
137 | %attr(755,root,root) %{_bindir}/mega-login | |
138 | %attr(755,root,root) %{_bindir}/mega-logout | |
139 | %attr(755,root,root) %{_bindir}/mega-lpwd | |
140 | %attr(755,root,root) %{_bindir}/mega-ls | |
22621376 | 141 | %attr(755,root,root) %{_bindir}/mega-mediainfo |
8e4e3a4f ER |
142 | %attr(755,root,root) %{_bindir}/mega-mkdir |
143 | %attr(755,root,root) %{_bindir}/mega-mount | |
144 | %attr(755,root,root) %{_bindir}/mega-mv | |
145 | %attr(755,root,root) %{_bindir}/mega-passwd | |
146 | %attr(755,root,root) %{_bindir}/mega-permissions | |
147 | %attr(755,root,root) %{_bindir}/mega-preview | |
148 | %attr(755,root,root) %{_bindir}/mega-put | |
149 | %attr(755,root,root) %{_bindir}/mega-pwd | |
150 | %attr(755,root,root) %{_bindir}/mega-quit | |
151 | %attr(755,root,root) %{_bindir}/mega-reload | |
152 | %attr(755,root,root) %{_bindir}/mega-rm | |
153 | %attr(755,root,root) %{_bindir}/mega-session | |
154 | %attr(755,root,root) %{_bindir}/mega-share | |
155 | %attr(755,root,root) %{_bindir}/mega-showpcr | |
156 | %attr(755,root,root) %{_bindir}/mega-signup | |
157 | %attr(755,root,root) %{_bindir}/mega-speedlimit | |
158 | %attr(755,root,root) %{_bindir}/mega-sync | |
159 | %attr(755,root,root) %{_bindir}/mega-thumbnail | |
160 | %attr(755,root,root) %{_bindir}/mega-transfers | |
22621376 | 161 | %attr(755,root,root) %{_bindir}/mega-tree |
8e4e3a4f ER |
162 | %attr(755,root,root) %{_bindir}/mega-userattr |
163 | %attr(755,root,root) %{_bindir}/mega-users | |
164 | %attr(755,root,root) %{_bindir}/mega-version | |
165 | %attr(755,root,root) %{_bindir}/mega-webdav | |
166 | %attr(755,root,root) %{_bindir}/mega-whoami | |
167 | %attr(755,root,root) %{_bindir}/megacli | |
8e4e3a4f ER |
168 | %attr(755,root,root) %{_bindir}/megasimplesync |
169 | ||
e4496910 ER |
170 | %if %{with fuse} |
171 | %files fuse | |
172 | %defattr(644,root,root,755) | |
173 | %attr(755,root,root) %{_bindir}/megafuse | |
174 | %endif | |
175 | ||
8e4e3a4f ER |
176 | %files libs |
177 | %defattr(644,root,root,755) | |
f3c91bd4 | 178 | %attr(755,root,root) %{_libdir}/libmega.so.*.*.* |
22621376 | 179 | %attr(755,root,root) %ghost %{_libdir}/libmega.so.30408 |
8e4e3a4f ER |
180 | |
181 | %files devel | |
182 | %defattr(644,root,root,755) | |
183 | %{_includedir}/mega | |
184 | %{_includedir}/mega.h | |
185 | %{_includedir}/megaapi.h | |
186 | %{_includedir}/megaapi_impl.h | |
187 | %{_libdir}/libmega.so | |
188 | %{_pkgconfigdir}/libmega.pc |