]> git.pld-linux.org Git - packages/dropbox.git/blob - dropbox.spec
470795110a0d0e5b63dee53dd99117d59f7bb42d
[packages/dropbox.git] / dropbox.spec
1 # TODO
2 # - avoid dropboxd relaunching itself with newer version if there's update available (disable auto updating):
3 #   glen     25034 19.9  1.5 1496132 81256 pts/46  Sl+  11:02   1:02 /home/glen/.dropbox-dist/dropbox /newerversion
4 # NOTES:
5 # - Upstream Dropbox Support (https://www.dropbox.com/ticket)
6 # - Release Notes (check new versions here): https://www.dropbox.com/release_notes
7 # - Download instructions (click the download link to find current version):
8 #   http://www.dropbox.com/downloading?os=lnx
9 #   http://wiki.dropbox.com/TipsAndTricks/TextBasedLinuxInstall
10 Summary:        Sync and backup files between computers
11 Name:           dropbox
12 # https://www.dropboxforum.com/hc/en-us/community/posts/206682016-New-Versioning-Scheme
13 Version:        89.4.278
14 Release:        2
15 License:        Proprietary
16 Group:          Daemons
17 Source0:        https://clientupdates.dropboxstatic.com/dbx-releng/client/%{name}-lnx.x86-%{version}.tar.gz
18 # NoSource0-md5:        c8f19efec158b4aec27ac65aea4b2c95
19 NoSource:       0
20 Source1:        https://clientupdates.dropboxstatic.com/dbx-releng/client/%{name}-lnx.x86_64-%{version}.tar.gz
21 # NoSource1-md5:        2c285eeeec6c95f68b4082e1f60b1fe6
22 NoSource:       1
23 URL:            https://www.dropbox.com/
24 BuildRequires:  rpmbuild(macros) >= 1.566
25 BuildRequires:  sed >= 4.0
26 BuildRequires:  tar >= 1:1.15.1
27 BuildRequires:  unzip
28 BuildRequires:  zip
29 Conflicts:      nautilus-dropbox < 0.6.3-2
30 ExclusiveArch:  %{ix86} %{x8664}
31 BuildRoot:      %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
32
33 # generate no Provides from private modules
34 %define         _noautoprovfiles        %{_libdir}/%{name}
35
36 # libicu-42, but pld th already has 59+
37 %define         icu_libs        libicudata.so.42 libicui18n.so.42 libicuuc.so.42
38
39 # provided by package itself, but autodeps disabled
40 %define         _noautoreq              libwx_.*.so %{icu_libs} libffi.so.6 librsync.so.1 libdropbox_apex.so libdropbox_nucleus.so libdropbox_tprt.so
41
42 # a zip and executable at the same time
43 %define         _noautostrip    .*/library.zip\\|.*/dropbox
44
45 # debuginfo wouldn't be useful
46 %define         _enable_debug_packages  0
47
48 # prelinked library, it is missing some cairo symbols
49 #define         skip_post_check_so      libwx_gtk2ud_core-2.8.so.0
50
51 %description
52 Dropbox is software that syncs your files online and across your
53 computers.
54
55 Put your files into your Dropbox on one computer, and they'll be
56 instantly available on any of your other computers that you've
57 installed Dropbox on (Windows, Mac, and Linux too!) Because a copy of
58 your files are stored on Dropbox's secure servers, you can also access
59 them from any computer or mobile device using the Dropbox website.
60
61 %package gui
62 Summary:        Gtk+2 GUI of Dropbox
63 Group:          X11/Applications
64 Requires:       %{name} = %{version}-%{release}
65
66 %description gui
67 Gtk+2 Systray of Dropbox Daemon status.
68
69 %prep
70 %setup -qcT
71 %ifarch %{ix86}
72 %{__tar} --strip-components=1 -xzf %{SOURCE0}
73 %endif
74 %ifarch %{x8664}
75 %{__tar} --strip-components=1 -xzf %{SOURCE1}
76 %endif
77 mv dropbox-lnx.*-%{version}/* .
78
79 # no need to package this
80 # altho system python is also 2.7, don't know how to enforce using it system libs
81 #%{__rm} -r distribute-0.6.26-py2.7.egg
82
83 # libraries to be taken from system
84 # for a in *.so*; do ls -ld /lib64/$a /us?/lib64/$a; done 2>/dev/null
85 %{__rm} libpopt.so.0 libdrm.so.2 libGL.so.1
86 %{__rm} libX11-xcb.so.1
87 %{__rm} libQt5{Core,DBus,Gui,Network,OpenGL,PrintSupport,Qml,Quick,Sql,WebKit,WebKitWidgets,Widgets,XcbQpa}.so.5
88 %{__rm} qt.conf
89 %{__rm} -r plugins
90
91 # keep librsync, won't finish syncing if not using upstream copy
92 test -f librsync.so.1
93
94 %if 1
95 # fun, let's delete non-linux files from archive
96 d=.delete-lib.txt
97 unzip -l python-packages.zip | \
98         grep -E '(arch|dropbox)/(mac|win32)|_(win32|mac)\.py|pymac|ui/cocoa|unittest' | \
99         grep -vE 'pymac/(__init__|constants|types|lazydll|lazyframework)\.py' | \
100         grep -vE 'dropbox/mac/(version|__init__)\.py' | \
101         grep -vF 'dropbox/client/features/files/local/operations/_mac.py' | \
102         awk '{print $NF}' > $d
103 zip python-packages.zip -d $(cat $d)
104 %endif
105
106 %install
107 rm -rf $RPM_BUILD_ROOT
108 install -d $RPM_BUILD_ROOT%{_bindir}
109 ln -s %{_libdir}/%{name}/dropboxd $RPM_BUILD_ROOT%{_bindir}/dropboxd
110
111 # install everything else
112 install -d $RPM_BUILD_ROOT%{_libdir}/%{name}
113 cp -a * $RPM_BUILD_ROOT%{_libdir}/%{name}
114
115 # in doc
116 %{__rm} $RPM_BUILD_ROOT%{_libdir}/%{name}/{ACKNOWLEDGEMENTS,VERSION,README}
117
118 %clean
119 rm -rf $RPM_BUILD_ROOT
120
121 %files
122 %defattr(644,root,root,755)
123 %doc ACKNOWLEDGEMENTS VERSION README
124 %attr(755,root,root) %{_bindir}/dropboxd
125 %dir %{_libdir}/%{name}
126 %attr(755,root,root) %{_libdir}/%{name}/*-linux-gnu.so
127 %attr(755,root,root) %{_libdir}/%{name}/dropbox
128 %attr(755,root,root) %{_libdir}/%{name}/dropboxd
129 %attr(755,root,root) %{_libdir}/%{name}/libatomic.so.1
130 %attr(755,root,root) %{_libdir}/%{name}/libdropbox_apex.so
131 %attr(755,root,root) %{_libdir}/%{name}/libdropbox_nucleus.so
132 %attr(755,root,root) %{_libdir}/%{name}/libdropbox_sqlite_ext.so
133 %attr(755,root,root) %{_libdir}/%{name}/libdropbox_tprt.so
134 %attr(755,root,root) %{_libdir}/%{name}/libffi.so.6
135 %attr(755,root,root) %{_libdir}/%{name}/libicudata.so.*
136 %attr(755,root,root) %{_libdir}/%{name}/libicui18n.so.*
137 %attr(755,root,root) %{_libdir}/%{name}/libicuuc.so.*
138 %attr(755,root,root) %{_libdir}/%{name}/librsync.so.1
139 %{_libdir}/%{name}/python-packages.zip
140
141 # need +x bits for .so files
142 %defattr(-,root,root,-)
143
144 # GUI parts
145 %exclude %{_libdir}/%{name}/PyQt5.*.so
146
147 %files gui
148 %defattr(644,root,root,755)
149 %attr(755,root,root) %{_libdir}/%{name}/PyQt5.*.so
150 %attr(755,root,root) %{_libdir}/%{name}/wmctrl
151 %dir %{_libdir}/%{name}/images
152 %{_libdir}/%{name}/images/emblems
153 %{_libdir}/%{name}/images/hicolor
154 %{_libdir}/%{name}/resources
This page took 0.154399 seconds and 3 git commands to generate.