Henriette's Notes

Home » Operating Systems » Setting up Virtuoso on Ubuntu 18.04

Setting up Virtuoso on Ubuntu 18.04

I recently needed to setup a local instance of Virtuoso on my Ubuntu 18.04 laptop. In particular I needed to be able to specify the directory that Virtuoso is installed. This meant that using a Linux package manager was not an option. I therefore opted to install Virtuoso from source.

  1. Here are the steps I followed to do this:
    We are using Virtuoso 7.2.2. in our production environment, hence I downloaded virtuoso-opensource-7.2.2.tar.gz from Virtuoso downloads.
  2. Then I followed the instructions to build Virtuoso from Building from Upstream Source.
    1. Check build environment by running the following commands:
      sudo apt-get install dpkg-dev build-essential 
      sudo apt-get install autoconf automake libtool flex bison gperf gawk m4 make odbcinst libxml2-dev libssl-dev libreadline-dev
      
    2. Extract the file:
      tar xvpfz virtuoso-opensource-7.2.2.tar.gz
    3. Now to configure Virtuoso to install to a directory of your choice, in the directory you extracted the .tar.gz, run the following:
      ./configure --prefix=directory_of_choice
      
    4. To build Virtuoso, run:
      make nice
      

      This step failed for me with an error message that looks something like the following

      make[3]: Entering directory '~/virtuoso-opensource/libsrc/Wi'
      /bin/bash ../../libtool  --tag=CC   --mode=compile gcc -DHAVE_CONFIG_H -I. -I../../libsrc/Dk    -fno-strict-aliasing -O2  -Wall  -DNDEBUG -DPOINTER_64   -I/home/klimek/virtuoso-opensource/libsrc/Xml.new  -DOPENSSL_NO_KRB5 -Dlinux -D_GNU_SOURCE -DFILE64 -D_LARGEFILE64_SOURCE   -I../../libsrc -I../../libsrc/Dk -I../../libsrc/zlib -I. -I../../libsrc/langfunc -I../../libsrc/plugin -I../../libsrc/Tidy -I../../libsrc/Xml.new -I../../libsrc/odbcsdk/include -DVAD -DDBP -DBIF_XPER -DOPSYS=\"Linux\" -DHOST=\"x86_64-unknown-linux-gnu\" -g -O2 -MT libwi_la-bif_crypto.lo -MD -MP -MF .deps/libwi_la-bif_crypto.Tpo -c -o libwi_la-bif_crypto.lo `test -f 'bif_crypto.c' || echo './'`bif_crypto.c
      libtool: compile:  gcc -DHAVE_CONFIG_H -I. -I../../libsrc/Dk -fno-strict-aliasing -O2 -Wall -DNDEBUG -DPOINTER_64 -I/home/klimek/virtuoso-opensource/libsrc/Xml.new -DOPENSSL_NO_KRB5 -Dlinux -D_GNU_SOURCE -DFILE64 -D_LARGEFILE64_SOURCE -I../../libsrc -I../../libsrc/Dk -I../../libsrc/zlib -I. -I../../libsrc/langfunc -I../../libsrc/plugin -I../../libsrc/Tidy -I../../libsrc/Xml.new -I../../libsrc/odbcsdk/include -DVAD -DDBP -DBIF_XPER -DOPSYS=\"Linux\" -DHOST=\"x86_64-unknown-linux-gnu\" -g -O2 -MT libwi_la-bif_crypto.lo -MD -MP -MF .deps/libwi_la-bif_crypto.Tpo -c bif_crypto.c  -fPIC -DPIC -o .libs/libwi_la-bif_crypto.o
      bif_crypto.c: In function ‘box_hmac’:
      bif_crypto.c:184:12: error: storage size of ‘ctx’ isn’t known
         HMAC_CTX ctx;
                  ^~~
      bif_crypto.c:190:3: warning: ‘HMAC_Init’ is deprecated [-Wdeprecated-declarations]
         HMAC_Init (&ctx, key, box_length (key) - DV_STRINGP (key) ? 1 : 0, md);
       ...

      which I fixed by installing libssl1.0-dev with

      sudo apt-get install libssl1.0-dev
      

      You can read more on this error here.
      After this re-run make nice.

    5. Lastly, I ran
      make install
      

      because I installed Virtuoso in my home directory. If you are not installing it in you home directory, you will need to run

      sudo make install
      
  3. To test your installation, go to localhost:8890.

 


Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out /  Change )

Google photo

You are commenting using your Google account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s

%d bloggers like this: