User Tools

Site Tools


building_owncloud_client_for_raspberry_pi

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revision Previous revision
Next revision
Previous revision
Last revision Both sides next revision
building_owncloud_client_for_raspberry_pi [2018/11/01 19:18]
sgripon [Build a debian package]
building_owncloud_client_for_raspberry_pi [2018/11/02 08:42]
sgripon [Download binaries]
Line 4: Line 4:
 I use my Raspberry pi as an owncloud client to synchronize my NAS and my server. Unfortunately, the official package is not up-to-date so I have to build it by myself.  I use my Raspberry pi as an owncloud client to synchronize my NAS and my server. Unfortunately, the official package is not up-to-date so I have to build it by myself. 
  
-**Update!**: this page has been updated for client 2.3.2+**Update!**: this page has been updated for client 2.5.0 compatible with raspbian stretch
  
-**DISCLAIMER :!:** Tested on raspbian jessie on raspi 1 and 3. Feedback welcome on twitter.+**DISCLAIMER :!:** Tested on raspbian stretch on raspberry pi 3. Feedback welcome on twitter.
  
 **Note:** if you need a newer version of the client, just tweet me [[https://twitter.com/sgripon|@sgripon]]. **Note:** if you need a newer version of the client, just tweet me [[https://twitter.com/sgripon|@sgripon]].
 ===== Download binaries ===== ===== Download binaries =====
  
-If you don't want to compile by yourself, you can get the debian package installer from [[http://pub.sgripon.net/owncloud-client/rpi/]] (tested on raspberry pi 1) or [[http://pub.sgripon.net/owncloud-client/rpi3/]] (tested on raspberry pi 3).+If you don't want to compile by yourself, you can get the debian package installer from
 +  * [[http://pub.sgripon.net/owncloud-client/rpi3/]]tested on raspberry pi 3 stretch. 
 +  * [[http://pub.sgripon.net/owncloud-client/rpi/]]: <2.3.2 tested on raspberry pi 1 jessie.
  
 To install: To install:
  
-  sudo dpkg -i owncloud-client-2.3.2_armhf.deb+  sudo dpkg -i owncloud-client-2.5.0_armhf.deb
  
 If there are missing dependencies, this command should automatically install all: If there are missing dependencies, this command should automatically install all:
Line 26: Line 28:
 ===== ppa ===== ===== ppa =====
  
-I also experiment ppa. You can try it by adding my ppa to the source.list. Add line:+I also experiment ppa. 
  
 +**DISCLAIMER! I have an issue with ppa signing so it will probably not work. If someone can provide me a good tutorial!**
 +
 +You can try it by adding my ppa to the source.list. Add line:
 +
 +  # For jessie until version 2.3.2
   deb http://pub.sgripon.net ppa/   deb http://pub.sgripon.net ppa/
 +
 +  # For stretch, support versions > 2.5.0.
 +  deb http://pub.sgripon.net/ppa-raspbian stretch/
      
 to /etc/apt/sources.list to /etc/apt/sources.list
Line 34: Line 44:
 Then: Then:
  
 +  wget -O - http://pub.sgripon.net/ppa-raspbian/sgripon.asc | apt-key add -
   sudo apt-get update   sudo apt-get update
   sudo apt-get install owncloud-client   sudo apt-get install owncloud-client
Line 42: Line 53:
 ===== Build ===== ===== Build =====
  
-Most of the build instructions are from owncloud official website (http://doc.owncloud.org/desktop/2.2/building.html) with some adjustments for RPI.+Most of the build instructions are from owncloud official website (http://doc.owncloud.org/desktop/2.4/building.html) with some adjustments for RPI.
  
-Get owncloud client sources from official web site here: https://download.owncloud.com/desktop/stable/owncloudclient-2.3.2.tar.xz.+Get owncloud client sources from official github web site here: https://github.com/owncloud/client/archive/v2.5.0.zip.
  
 This tutorial assumes that the work is done on raspbian in folder /home/pi/dev/owncloud-client. If not, change all paths. This tutorial assumes that the work is done on raspbian in folder /home/pi/dev/owncloud-client. If not, change all paths.
Line 59: Line 70:
   sudo apt-get install libssl-dev   sudo apt-get install libssl-dev
   sudo apt-get install libsqlite3-dev   sudo apt-get install libsqlite3-dev
-  sudo apt-get install libqt4-dev libqtkeychain0 qtkeychain-dev libqt4-sql-sqlite+  sudo apt-get install zlib1g-dev 
 +  sudo apt-get install qt5-default libqt5webkit5-dev qttools-dev-tools qt5keychain-dev
 </code> </code>
  
Line 78: Line 90:
 #!/bin/sh #!/bin/sh
      
-# Download and extract source from official website +# Download and extract source from official github website 
-if [ ! -f owncloudclient-$1.tar.xz ]; then +if [ ! -f v$1.zip ]; then 
-  wget https://download.owncloud.com/desktop/stable/owncloudclient-$1.tar.xz+  wget https://github.com/owncloud/client/archive/v$1.zip
 fi fi
  
-tar -xf owncloudclient-$1.tar.xz+unzip v$1.zip
  
 # Build # Build
 mkdir client-build  mkdir client-build 
 cd client-build cd client-build
-cmake -DWITH_DOC=TRUE -DCMAKE_BUILD_TYPE="Release" ../owncloudclient-$1+cmake -DWITH_DOC=TRUE -DCMAKE_BUILD_TYPE="Release" ../client-$1
 make make
  
Line 109: Line 121:
 make install make install
  
-# It seems that libocsync and libowncloudsync shared libraries must be installed manually: 
-cp src/csync/libowncloud_csync.so.$1 /usr/local/lib 
-cp src/libsync/libowncloudsync.so.$1 /usr/local/lib 
-ldconfig 
 </file> </file>
 ===== Build a debian package ===== ===== Build a debian package =====
Line 130: Line 138:
   cp /usr/local/lib/arm-linux-gnueabihf/libowncloud_csync.so.2.5.0 usr/local/lib   cp /usr/local/lib/arm-linux-gnueabihf/libowncloud_csync.so.2.5.0 usr/local/lib
   cp /usr/local/lib/arm-linux-gnueabihf/libowncloudsync.so.2.5.0 usr/local/lib   cp /usr/local/lib/arm-linux-gnueabihf/libowncloudsync.so.2.5.0 usr/local/lib
-  +
 Then, follow tutorial [[How To Build a Debian Package]]. Then, follow tutorial [[How To Build a Debian Package]].
  
Line 145: Line 153:
 rsync --files-from $DIR/client-build/install_manifest.txt / . rsync --files-from $DIR/client-build/install_manifest.txt / .
  
-cp /usr/local/lib/arm-linux-gnueabihf/libowncloud_csync.so.$1 usr/local/lib +cp /usr/local/lib/libocsync.so.$1 usr/local/lib 
-cp /usr/local/lib/arm-linux-gnueabihf/libowncloudsync.so.$1 usr/local/lib+cp /usr/local/lib/libowncloudsync.so.$1 usr/local/lib
  
 mkdir DEBIAN mkdir DEBIAN
Line 152: Line 160:
 cat <<EOT>> DEBIAN/control cat <<EOT>> DEBIAN/control
 Package: owncloud-client Package: owncloud-client
-Version: $1+debian+rpi1+Version: $1+debian+rpi3
 Homepage: https://wiki.sgripon.net/doku.php?id=building_owncloud_client_for_raspberry_pi Homepage: https://wiki.sgripon.net/doku.php?id=building_owncloud_client_for_raspberry_pi
 Depends: libqt5dbus5, libqt5webkit5, libqt5xml5, libsqlite3-0, libqt5concurrent5, zlib1g, libqt5keychain1, libqt5network5, libqt5gui5, libqt5core5a, libstdc++6, libgcc1, libc6 Depends: libqt5dbus5, libqt5webkit5, libqt5xml5, libsqlite3-0, libqt5concurrent5, zlib1g, libqt5keychain1, libqt5network5, libqt5gui5, libqt5core5a, libstdc++6, libgcc1, libc6
Line 188: Line 196:
  
 Must be invoked as sudo with version number as argument: Must be invoked as sudo with version number as argument:
-  sudo ./oc-build-deb.sh 2.3.2+  sudo ./oc-build-deb.sh 2.5.0
  
 ===== Launch at startup ===== ===== Launch at startup =====
Line 202: Line 210:
  
 Older versions can have a different build sequence: Older versions can have a different build sequence:
 +  * [[building_owncloud_client_for_raspberry_pi_232|Owncloud client 2.3.2]]
   * [[building_owncloud_client_for_raspberry_pi_170|Owncloud client 1.7.0]]   * [[building_owncloud_client_for_raspberry_pi_170|Owncloud client 1.7.0]]
  
 **Share this page:** **Share this page:**
 ~~socialite~~ ~~socialite~~
building_owncloud_client_for_raspberry_pi.txt · Last modified: 2018/11/02 09:06 by sgripon