]>
Commit | Line | Data |
---|---|---|
e4496910 ER |
1 | # |
2 | # Conditional build: | |
7b4a00eb ER |
3 | %bcond_without fuse # build megafuse |
4 | %bcond_without libmediainfo # build with libmediainfo | |
e4496910 | 5 | |
87cee7c0 ER |
6 | Summary: Command Line Interactive and Scriptable Application to access MEGA |
7 | Name: megacmd | |
a38be195 | 8 | Version: 1.0.0 |
f3c91bd4 | 9 | Release: 2 |
c1b11adc ER |
10 | # https://github.com/meganz/MEGAcmd/commit/b366c77370c277223be123e05e5ef15fafbce185#r31261647 |
11 | License: BSD 2-Clause "Simplified" License | |
87cee7c0 ER |
12 | Group: Applications |
13 | Source0: https://github.com/meganz/MEGAcmd/archive/%{version}/%{name}-%{version}.tar.gz | |
a38be195 ER |
14 | # Source0-md5: 8af6215ce167b15b92f8683c4c1caa7c |
15 | Source1: https://github.com/meganz/sdk/archive/f3a3b810/mega-sdk-v3.4.0-216-gf3a3b810.tar.gz | |
16 | # Source1-md5: dccc60aa2ac5680a719b74bc0968984f | |
8eb3178f | 17 | Patch0: libtool.patch |
87cee7c0 | 18 | URL: https://mega.nz/ |
b33e7950 ER |
19 | BuildRequires: FreeImage-devel |
20 | BuildRequires: autoconf | |
21 | BuildRequires: automake | |
22 | BuildRequires: c-ares-devel | |
23 | BuildRequires: cppcheck | |
24 | BuildRequires: cryptopp-devel | |
25 | 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 ER |
75 | %prep |
76 | %setup -q -n MEGAcmd-%{version} -a1 | |
77 | mv sdk-*/* sdk | |
78 | %patch0 -p1 | |
79 | ||
80 | %build | |
81 | autoreconf -vif | |
82 | %configure \ | |
6773bcd0 | 83 | %{__with_without fuse} \ |
7b4a00eb | 84 | %{__with_without libmediainfo} \ |
87cee7c0 ER |
85 | --disable-silent-rules |
86 | %{__make} | |
87 | ||
88 | %install | |
89 | rm -rf $RPM_BUILD_ROOT | |
90 | %{__make} install \ | |
91 | DESTDIR=$RPM_BUILD_ROOT | |
92 | ||
8e4e3a4f ER |
93 | %{__rm} $RPM_BUILD_ROOT%{_libdir}/libmega.la |
94 | ||
87cee7c0 ER |
95 | %clean |
96 | rm -rf $RPM_BUILD_ROOT | |
97 | ||
8e4e3a4f ER |
98 | %post libs -p /sbin/ldconfig |
99 | %postun libs -p /sbin/ldconfig | |
100 | ||
87cee7c0 ER |
101 | %files |
102 | %defattr(644,root,root,755) | |
8e4e3a4f ER |
103 | %doc README.md LICENSE |
104 | /etc/bash_completion.d/megacmd_completion.sh | |
105 | %attr(755,root,root) %{_bindir}/mega-attr | |
106 | %attr(755,root,root) %{_bindir}/mega-backup | |
107 | %attr(755,root,root) %{_bindir}/mega-cancel | |
108 | %attr(755,root,root) %{_bindir}/mega-cd | |
109 | %attr(755,root,root) %{_bindir}/mega-cmd | |
110 | %attr(755,root,root) %{_bindir}/mega-cmd-server | |
111 | %attr(755,root,root) %{_bindir}/mega-confirm | |
112 | %attr(755,root,root) %{_bindir}/mega-confirmcancel | |
113 | %attr(755,root,root) %{_bindir}/mega-cp | |
114 | %attr(755,root,root) %{_bindir}/mega-debug | |
115 | %attr(755,root,root) %{_bindir}/mega-deleteversions | |
116 | %attr(755,root,root) %{_bindir}/mega-du | |
117 | %attr(755,root,root) %{_bindir}/mega-errorcode | |
118 | %attr(755,root,root) %{_bindir}/mega-exclude | |
119 | %attr(755,root,root) %{_bindir}/mega-exec | |
120 | %attr(755,root,root) %{_bindir}/mega-export | |
121 | %attr(755,root,root) %{_bindir}/mega-find | |
122 | %attr(755,root,root) %{_bindir}/mega-ftp | |
123 | %attr(755,root,root) %{_bindir}/mega-get | |
124 | %attr(755,root,root) %{_bindir}/mega-graphics | |
125 | %attr(755,root,root) %{_bindir}/mega-help | |
126 | %attr(755,root,root) %{_bindir}/mega-https | |
127 | %attr(755,root,root) %{_bindir}/mega-import | |
128 | %attr(755,root,root) %{_bindir}/mega-invite | |
129 | %attr(755,root,root) %{_bindir}/mega-ipc | |
130 | %attr(755,root,root) %{_bindir}/mega-killsession | |
131 | %attr(755,root,root) %{_bindir}/mega-lcd | |
132 | %attr(755,root,root) %{_bindir}/mega-log | |
133 | %attr(755,root,root) %{_bindir}/mega-login | |
134 | %attr(755,root,root) %{_bindir}/mega-logout | |
135 | %attr(755,root,root) %{_bindir}/mega-lpwd | |
136 | %attr(755,root,root) %{_bindir}/mega-ls | |
137 | %attr(755,root,root) %{_bindir}/mega-mkdir | |
138 | %attr(755,root,root) %{_bindir}/mega-mount | |
139 | %attr(755,root,root) %{_bindir}/mega-mv | |
140 | %attr(755,root,root) %{_bindir}/mega-passwd | |
141 | %attr(755,root,root) %{_bindir}/mega-permissions | |
142 | %attr(755,root,root) %{_bindir}/mega-preview | |
143 | %attr(755,root,root) %{_bindir}/mega-put | |
144 | %attr(755,root,root) %{_bindir}/mega-pwd | |
145 | %attr(755,root,root) %{_bindir}/mega-quit | |
146 | %attr(755,root,root) %{_bindir}/mega-reload | |
147 | %attr(755,root,root) %{_bindir}/mega-rm | |
148 | %attr(755,root,root) %{_bindir}/mega-session | |
149 | %attr(755,root,root) %{_bindir}/mega-share | |
150 | %attr(755,root,root) %{_bindir}/mega-showpcr | |
151 | %attr(755,root,root) %{_bindir}/mega-signup | |
152 | %attr(755,root,root) %{_bindir}/mega-speedlimit | |
153 | %attr(755,root,root) %{_bindir}/mega-sync | |
154 | %attr(755,root,root) %{_bindir}/mega-thumbnail | |
155 | %attr(755,root,root) %{_bindir}/mega-transfers | |
156 | %attr(755,root,root) %{_bindir}/mega-userattr | |
157 | %attr(755,root,root) %{_bindir}/mega-users | |
158 | %attr(755,root,root) %{_bindir}/mega-version | |
159 | %attr(755,root,root) %{_bindir}/mega-webdav | |
160 | %attr(755,root,root) %{_bindir}/mega-whoami | |
161 | %attr(755,root,root) %{_bindir}/megacli | |
8e4e3a4f ER |
162 | %attr(755,root,root) %{_bindir}/megasimplesync |
163 | ||
e4496910 ER |
164 | %if %{with fuse} |
165 | %files fuse | |
166 | %defattr(644,root,root,755) | |
167 | %attr(755,root,root) %{_bindir}/megafuse | |
168 | %endif | |
169 | ||
8e4e3a4f ER |
170 | %files libs |
171 | %defattr(644,root,root,755) | |
f3c91bd4 ER |
172 | %attr(755,root,root) %{_libdir}/libmega.so.*.*.* |
173 | %attr(755,root,root) %ghost %{_libdir}/libmega.so.30401 | |
8e4e3a4f ER |
174 | |
175 | %files devel | |
176 | %defattr(644,root,root,755) | |
177 | %{_includedir}/mega | |
178 | %{_includedir}/mega.h | |
179 | %{_includedir}/megaapi.h | |
180 | %{_includedir}/megaapi_impl.h | |
181 | %{_libdir}/libmega.so | |
182 | %{_pkgconfigdir}/libmega.pc |