Using the Ice-E 3.6.1 Debian Binary Distribution

This page provides important information for users of the Ice-E Debian binary distribution.

On this page:

Overview of the Ice-E Debian binary distribution

The Ice-E binary distribution provides the required packages to develop applications targeting Debian 7.8 (Wheezy) armhf and Ubuntu 15.04 (Vivid) amd64. The only supported development platform is Ubuntu 15.04 (Vivid) amd64; applications targeting Debian 7.8 (Wheezy) armhf are cross-compiled using a Ubuntu 15.04 (Vivid) amd64 machine. Ice-E Debian is an add-on to Ice and uses the same Slice-to-C++ compiler, Slice files and C++ header files provided by the Ice C++ development package.

Ice-E has been extensively tested on the BeagleBone Black board (Rev C) with the default Debian distribution for this board.

DEB packages

ZeroC provides the following DEB packages for Ubuntu 15.04 (Vivid) amd64 and Debian 7.8 (Wheezy) armhf:

PackageDescription
libzeroc-ice-python2.7Ice for python run-time
libzeroc-ice3.6

Ice for C++ dynamic libraries

libzeroc-icee-dev

armhf: C++ static libraries, C++ dynamic libraries and .so symbolic links

amd64: C++ static libraries

zeroc-ice-sliceSlice files required by python package
zeroc-icebox

IceBox server for C++

zeroc-glacier2Glacier2 service
zeroc-ice-utilsIce utilities and admin tools

You cannot install libzeroc-ice3.6 for Debian 7.8 armhf on Ubuntu 15.04 amd64 because libzeroc-ice3.6 for Debian 7.8 armhf depends on Debian 7.8 packages that cannot be installed on Ubuntu 15.04: bzip2, openssl and more.

As a result, we included a copy of this package's contents in the libzeroc-icee-dev package for Debian 7.8 armhf. Use libzeroc-icee-dev for Debian 7.8 armhf to build your Debian 7.8 armhf application on Ubuntu 15.04, and libzeroc-ice3.6 for Debian 7.8 armhf to install the Ice C++ dynamic libraries on your armhf target.

Installing the Ice-E binary distribution

Installing DEB packages

Use the following commands to install the development packages in Ubuntu Vivid. First you need to add the Ubuntu repository:

wget https://zeroc.com/download/GPG-KEY-zeroc-release
sudo apt-key add GPG-KEY-zeroc-release
sudo apt-add-repository "deb [arch=amd64,armhf] http://zeroc.com/download/apt/ubuntu15.04 stable main"

Before you can install packages from a foreign architecture, you must first tell dpkg about it. Run the following command to make dpkg aware of the armhf architecture:

sudo dpkg --add-architecture armhf
sudo apt-get update

Note that the apt-get update command will show some warnings for repositories that don't support the newly-added architecture. To avoid these warnings you can edit your repository lists and set the architectures supported by each repository (see "Setting up apt sources" in the Multiarch HOWTO).

Now you can install the armhf development libraries using the command shown below. These libraries are used for cross-compiling Ice-E applications for Debian Wheezy armhf.

sudo apt-get install libzeroc-ice-dev libzeroc-icee-dev:armhf

You can also install Ice-E development libraries for Ubuntu Vivid amd64 with the following command:

sudo apt-get install libzeroc-ice-dev libzeroc-icee-dev

The Glacier2 service and IceBox C++ server are provided by the zeroc-glacier2 and zeroc-icebox packages respectively. For Ubuntu Vivid amd64, the packages are included in the ubuntu15.04 repository shown above, and for Debian 7.8 (Wheezy) armhf you'll need to add an extra repository:

wget https://zeroc.com/download/GPG-KEY-zeroc-release
sudo apt-key add GPG-KEY-zeroc-release
sudo bash -c 'echo "deb http://download.zeroc.com/apt/debian7.8 stable main" > /etc/apt/sources.list.d/icee3.6.list'
sudo apt-get update

Setting up your cross development environment to use Ice-E

This section explains how to setup your cross development environment in Ubuntu 15.04 (Vivid) amd64 for developing applications targeting Debian 7.8 armhf. First we need to install a compatible cross tool-chain. For that purpose we will be using the g++-4.6-arm-linux-gnueabihf package available in the Ubuntu precise repository:

sudo apt-add-repository "deb [arch=amd64,i386] http://es.archive.ubuntu.com/ubuntu/  precise main"  
sudo apt-add-repository "deb [arch=amd64,i386] http://es.archive.ubuntu.com/ubuntu/  precise universe"
sudo apt-get update
sudo apt-get install g++-4.6-arm-linux-gnueabihf

Next you need to install the third-party libraries for the target OS. For your convenience we provide a script that downloads the required libraries from Debian 7.8 (Wheezy) repository and sets them up:

wget https://github.com/zeroc-ice/icee/raw/v3.6.1/config/install_wheezy_thirdparty.sh
sudo bash install_wheezy_thirdparty.sh

When cross compiling Ice-E applications you must use arm-linux-gnueabihf-g++-4.6 instead of g++. You also need to link your executable with the Ice library and with the third-party libraries from the cross third party package.

Sample compile command:

arm-linux-gnueabihf-g++-4.6 -pthread Hello.cpp

Sample link command:

arm-linux-gnueabihf-g++-4.6 -L/opt/IceE-3.6.0-ThirdParty/usr/lib/arm-linux-gnueabihf -Wl,-rpath-link,/opt/IceE-3.6.0-ThirdParty/lib/arm-linux-gnueabihf \
    -o client Hello.o Client.o -lIce -lcrypto -lssl -pthread -lbz2 -ldl -lrt

Using the Ice-E sample programs

Sample programs are available in a separate GitHub repository. Simply clone this repository and use its 3.6 branch:

git clone -b 3.6 https://github.com/zeroc-ice/ice-demos.git
cd ice-demos

The Ice-E demos for C++ and Python are located in the cpp and python directories respectively. Review the build instructions for more information.