Phil Troy Posted May 9, 2015 Posted May 9, 2015 Hi! I am trying to compile and install synergy 1.5.1 for a raspberry pi 2 running on an armhf (hardware float) version of debian (not raspbian) running lxde as a gui. I am using 1.5.1 since that is what I have on my other machines. I have tried the following: - Installing all dependencies (based on synergy's compiling web page) - uncompressing the archive - uncompressing the zip files in the ext subfolder to folders of their own in the source folder - commented out lines 84 to 87 of CMakeLists.txt - ./hm.sh conf -g1 (from the terminal while in the source file) - ./configure (in the source file) - make (in the source file) All of the above worked without errors (but took a long time since these steps were not clearly indicated - to me - in the compiling web page). So next I tried running synergyc and I got command not found. I looked in the bin folder - nothing there (including hidden files). I would really appreciate it if someone could help me with this - I am guessing that it is something small but even if it is it is stopping me. I would also suggest that the compilation instructions be made more step by step and more complete. THANKS . . . Phil
the-wes Posted May 12, 2015 Posted May 12, 2015 I imagine compiling Synergy on a Raspberry Pi would be fairly similar whether you're running Raspbian or Debian, so I'm going to provide a link to an article that walks you through the process on Raspbian. Hopefully you'll be able to adapt this to work on Debian without too much trouble.. https://learn.adafruit.com/synergy-on-r ... r-raspbian
Marc Quentel Posted February 12, 2016 Posted February 12, 2016 Sadly, this link is dead : https://learn.adafruit.com/synergy-on-r ... r-raspbian here is a copy/paste of it : ---------------------------------------------------------- [b]Compiling Synergy for Raspbian[/b] Author : FRANK ZHAO Although you can get Synergy through the package manager, it is an older version that may be incompatible with newer Synergy server versions. We are forced to compile Synergy ourselves to ensure that it is using the latest protocol and runs on Raspberry Pi's ARMv6 processor. Download the source code tarball from Synergy's download page, it must be the .tar.gz file. Save it to /home/pi/downloads (make sure that folder exists first) Download Synergy 1.4.15 Beta Source Code Tarball Alternatively, use wget through the terminal [color=#400000]cd /home/pi/downloads sudo wget http://synergy.googlecode.com/files/syn ... rce.tar.gz[/color] Extract the tarball [color=#400000]sudo tar -xzf synergy-1.4.15-Source.tar.gz[/color] Raspbian does not come with some of the tools you might need, use the APT package manager to install the required tools. The following command will take some time and eat up some disk space. [color=#400000]sudo apt-get update && sudo apt-get upgrade -y sudo apt-get install gcc cmake libx11-dev libxtst-dev[/color] Navigate into the source code directory [color=#400000]cd synergy-1.4.15-Source[/color] Right now, what you should be doing is running cmake, which should generate a makefile. But at this point, cmake will fail with an error regarding not being able to find some header files. An error like "Missing header: X11/Xlib.hX11/XKBlib.h" might show up. This is because Synergy's CMakeList.txt file is looking for header files inside /usr/local/include , but in Raspbian, it should be looking inside /usr/include. We'll fix that by editing CMakeList.txt. [color=#400000] sudo nano CMakeLists.txt[/color] Use the nano text editor to look for the line [color=#400000]set(CMAKE_INCLUDE_PATH "${CMAKE_INCLUDE_PATH}:/usr/local/include")[/color] and change it to [color=#400000]set(CMAKE_INCLUDE_PATH "${CMAKE_INCLUDE_PATH}:/usr/include")[/color] and close nano, the hot-key for closing nano should be CTRL-X It will ask you to save before closing, you must save it Inside the directory synergy-1.4.15-Source/tools , there is a zip file called cryptopp562.zip containing the Crypto++ library, which you must extract into the directory synergy-1.4.15-Source/tools/cryptopp562 , if you don't do this, you will eventually run into an error looking for the files inside. Do this from the terminal [color=#400000] sudo unzip ./tools/cryptopp562.zip -d ./tools/cryptopp562[/color] There's a bit of strangeness inside the synergy-1.4.15-Source/tools/CMakeList.txt file, it wants the C compiler to compile for the native architecture, but this will cause an error when the compiler doesn't understand what the word native means. We need to change this to ARMv6 since we are on a Raspberry Pi. Open the file using nano Copy Code [color=#400000]sudo nano ./tools/CMakeLists.txt[/color] Look for the line [color=#400000]set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -march=native")[/color] and edit it to the following on a Pi 1 [color=#400000]set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -march=armv6zk")[/color] for the Pi 2, do this instead: [color=#400000] set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -march=armv7-a")[/color] and close nano, the hot-key for closing nano should be CTRL-X It will ask you to save before closing, you must save it We have now done all of the steps to preemptively prevent the errors you will face. Now we can use cmake to configure our makefile build [color=#400000]sudo cmake .[/color] This will take a while... grab a coffee. After it finishes, it should say: [color=#400000]-- Configuring done -- Generating done -- Build files have been written to: /home/pi/download/synergy-1.4.15-Source[/color] What it did was check over your system to see if you have all of the required files, and see what kind of tools are available. It uses this information to generate a makefile for you. Now you can use make to build the source code according to the makefile [color=#400000]sudo make[/color] This time, nuke some popcorn and watch a movie, this literally took a few hours. Nobody claimed that the 700MHz Raspberry Pi was very fast. When it finishes with no errors, a new directory at synergy-1.4.15-Source/bin should exist, and inside should be several executables files. Install these by using the copy command to copy the files into the /usr/bin directory [color=#400000]sudo cp -a ./bin/. /usr/bin[/color]
Alan Miller Posted May 22, 2016 Posted May 22, 2016 Has anyone compiled 1.7.6 for Raspberry? If so it'd be great if you could share the binaries? Alan
Alan Miller Posted May 23, 2016 Posted May 23, 2016 I got the 1.7.6-stable branch to compile as follows: pi@raspberrypi:~ $ sudo apt-get update pi@raspberrypi:~ $ sudo apt-get upgrade pi@raspberrypi:~ $ sudo apt-get install gcc cmake libx11-dev libxtst-dev pi@raspberrypi:~ $ tar xzf ~/Downloads/synergy-v1.7.6-stable-bcb9da8-Source.tar.gz pi@raspberrypi:~ $ mv synergy-1.7.6-stable synergy pi@raspberrypi:~/synergy $ vi CMakeLists.txt # ONLY had to change INCLUDE_PATH to this set(CMAKE_INCLUDE_PATH "${CMAKE_INCLUDE_PATH}:/usr/include”) pi@raspberrypi:~/synergy $ cd ext pi@raspberrypi:~/synergy/ext $ mkdir gmock-1.6.0 ; unzip gmock-1.6.0 -d ./gmock-1.6.0; mv gmock-1.6.0/src/* gmock-1.6.0 pi@raspberrypi:~/synergy/ext $ mkdir gtest-1.6.0 ; unzip gtest-1.6.0 –d ./gtest-1.6.0; mv gtest-1.6.0/src/* gtest-1.6.0 pi@raspberrypi:~/synergy/ext $ cd .. pi@raspberrypi:~/synergy $ sudo cmake . -- Configuring done -- Generating done -- Build files have been written to: /home/pi/synergy pi@raspberrypi:~/synergy $ sudo make
dogi Posted June 20, 2016 Posted June 20, 2016 watch out with copy paste the quotes of this example are cursed (wrong) ... ... use following to copy paste [code]set(CMAKE_INCLUDE_PATH "${CMAKE_INCLUDE_PATH}:/usr/include")[/code]
dogi Posted June 20, 2016 Posted June 20, 2016 also we should not forget [code]sudo aptitude install libxcb-xinerama0-dev libcurl4-openssl-dev libxinerama-dev libxrandr-dev libice-dev libsm-dev libxcb-randr0-dev libssl-dev[/code]
Recommended Posts
Archived
This topic is now archived and is closed to further replies.