%VOSWARNING% %VOSNAV% ---+ Building on Windows %TOC% ---++ Introduction This page gives instructions for building Virtuoso Open-Source Edition on Windows 32- or 64-bit platforms.
Note: The build process on Windows is rather more complex than on other platforms, so we make pre-built Windows packages available [[http://sourceforge.net/projects/virtuoso/files/virtuoso/][in the SourceForge Project]]. We recommend you use the latest build available for your platform. As of 2018-02-01, the latest available VOS binaries for Windows are [[https://sourceforge.net/projects/virtuoso/files/virtuoso/7.2.4.2/virtuoso-opensource-win-x64-20160425.zip/download][64-bit (x86_64) version 7.2.4.2 (built 2016-04-25)]] and [[https://sourceforge.net/projects/virtuoso/files/virtuoso/6.1.8/virtuoso-opensource-x86-20131211.zip/download][32-bit (x86) version 6.1.8 (built 2013-12-11)]].---++ Prerequisites You must have the following development tools and software installed: * Microsoft Visual Studio 2003 or later for 32-bit builds; 2005 or later for 64-bit builds %BR%Note: The Virtuoso projects and solution are maintained under VS 2003, so they must be converted to the VS 2005 format if you are using VS 2005 or later. To do this, just open the solution with your VS, and you will be asked to confirm project conversion. Then follow the instructions on screen. * Cygwin bash with developer tools (gawk, flex, bison) installed. * Bison must be version 1.875b; newer versions (2.x+) are not compatible. * Active Perl, available from http://www.activestate.com/ActivePerl *
INSTALL.W32
document in the <OpenSSL dir</util/pl/VC-32.pl
and change the "cflags
" to use the "/MT
" and "/MTd
" compiler switches instead of "/MD
" and "/MDd
".
Finally, the libeay32.lib
and ssleay32.lib
from <OpenSSL dir>/out32
and
files from <OpenSSL dir>/inc32/openssl must be copied to <Virtuoso
Open Source dir>/win32/openssl/
.
---+++ Microsoft Visual Studio settings
For Visual Studio to find the Cygwin developer tools (gawk, bison,
flex), the path to the Cygwin programs (e.g., c:\cygwin\bin
) must be
added to standard settings.
To do this, execute the following steps:
1 Open the IDE
1 Open "Tools", then "Options"
1 In the "Options" menu select "Projects" settings
1 From "Projects" settings select "VC++ Directories"
1 Add the Cygwin programs path to the list for "Executable files", before <WIN>/system32
, so VS will use cygwin's "find
" command
1 Confirm the changes.
---+++ Known issues
* Bison version 2.1 that comes with Cygwin bash generates buggy code. To resolve this, you must either
* install an older version of bison (1.875b is recommended) or
* edit the generated files (sql3.c
and turtle_p.c
in <Virtuoso Open Source dir>/libsrc/Wi
) and remove the ';' after the start of the 'yyparse
' function:
...
#else
int
yyparse ()
; <-- remove this
#endif
#endif
...
* The OLE DB Provider for Virtuoso cannot be built under VS 2005; it should be disabled.
---++ Build targets
---+++ Core components
* virtuoso_t
- the Virtuoso Server
* isql
, isqlo
- SQL command line tools
* virtoledb
- Virtuoso OLEDB provider
* wi
, wic
, dk1t
, dksrv
, threads
, threadw
, xml
, zlib
, tidy
, util
- library modules
---+++ Optional components
* tpcc
, blobs
, scroll
, burstoff
, cutter
, cursor
- test suite programs
* libvirtuoso_t
- the Virtuoso server shared object, needed for hosting servers
* virtodbc
- Virtuoso ODBC Driver
* virtuoso_clr_t
- .NET CLR-hosting server (requires .NET Framework SDK v1.1)
* virtuoso_javavm_t
- Java hosting server (requires Java SDK)
* virtuoso_php_t
- PHP4 hosting server (requires PHP4 library)
* virtuoso_sample_t
- sample of the Virtuoso server with extensions
* hosting_perl
- Perl hosting plugin (requires Active Perl)
* hosting_python
- Python hosting plugin (requires Active Python)
* wikiv
- Virtuoso Wiki plugin
* im
- ImageMagick
plugin (requires ImageMagick
library)
---++ Building Virtuoso Open Source with Microsoft Visual Studio
1 Open the IDE.
1 Open the appropriate solution file
* For 32-bit, from <Virtuoso Open Source dir>/win32/virtuoso-opensource.sln
.
* For 64-bit, from <Virtuoso Open Source dir>/win64/virtuoso-opensource.sln
.
1 Select desired configuration (Debug or Release).
1 Build the solution.
---++ Building optional components
---+++ PHP4 library notes
The following directories with the header files from the PHP4 source tree
need to be placed under <Virtuoso Open Source dir>/win32/php4/
:
* ext/
* main/
* regex/
* TSRM/
* win32/
* Zend/
To the same directory (<Virtuoso Open Source dir>/win32/php4/
), you should
also copy the following:
* php4ts.dll
* php4ts.lib
* php_version.h
---+++ Building the Virtuoso Open-Source Java hosting binary under Microsoft Visual Studio 2003
1 Make sure that JDK 1.4 or later is installed. (A JRE is not sufficient.)
1 Add environment setting JDK_PATH
with value of JDK installation directory (e.g., c:\jdk1.5
).
1 Start the Visual Studio IDE and enable the virtuoso_javavm_t
target in the solution.
1 Build the virtuoso_javavm_t
target.
---+++ Building the Virtuoso Open-Source Perl hosting plugin
1 Make sure Active Perl is installed.
1 From the VS.NET 2003 command prompt, go to <Virtuoso Open Source dir>/win32
.
1 Run 'perl mkperlenv.pl
'; this should produce output like:
PERL_CFLAGS=...
PERL_LDFLAGS=...
1 Add the PERL_CFLAGS
and PERL_LDFLAGS
in the environment with values printed from the step above.
1 Start the Visual Studio IDE and enable the hosting_perl
target in the solution.
1 Build the hosting_perl
plugin.
---+++ Building the Virtuoso Open-Source Python hosting plugin
1 Make sure Active Python is installed
1 From the VS.NET 2003 command prompt, go to <Virtuoso Open Source dir>/win32
.
1 Run 'python mkpythonenv.py
'; this should produce output like:
PYTHON_CFLAGS=...
PYTHON_LDFLAGS=...
1 add the PYTHON_CFLAGS
and PYTHON_LDFLAGS
in the environment with values printed from the step above
1 Start the Visual Studio IDE and enable the hosting_python
target in the solution.
1 Build the hosting_python
plugin
---+++ Building the Virtuoso Open-Source Imagemagick plugin
1 Install the ImageMagick library, available from http://www.imagemagick.org/
1 add the IM_PATH
in the environment with a value of ImageMagick installation directory
1 Start the Visual Studio IDE and enable the im
target in the solution
1 Build the ImageMagick plugin
---++ Testing your build
1 Make sure that following binaries exist in <Virtuoso Open Source dir>/win32/[Release|Debug]
:
* virtuoso-t.exe
* isql.exe
* blobs.exe
* ins.exe
* scroll.exe
1 Open a Cygwin bash shell
1 Change directory to <Virtuoso Open Source dir>/
1 Execute the following commands (Note: replace in $PATH the 'Release' with 'Debug' if you are going to run the tests using debug binaries.)
export HOME=`pwd`
export PATH=$HOME/win32/Release:$PATH
export BLOBS=blobs.exe
export INS=ins.exe
export ISQL=isql.exe
export PORT=5555
export ENABLE_MTS_TEST=0
export SCROLL=scroll.exe
export GETDATA=getdata.exe
1 Change directory to <Virtuoso Open Source dir>/binsrc/tests/suite
1 Run the tests:
./test_server virtuoso-t
---++ Installation
---+++ ODBC Driver registration
Perform the following steps to register the ODBC Driver for Virtuoso:
1 Open a Command prompt
1 Navigate to the directory where the virtodbc.dll
(Virtuoso Open Source ODBC Driver) is built.
1 execute:
regsvr32 virtodbc.dll
1 A confirmation dialog stating that the driver was registered should be displayed.
---+++ Running the Demo Database
1 Make a folder, e.g., c:\dbs\virtuoso
.
1 Copy the Demo database (demo.db) and default demo.ini
file to the new directory.
cd c:
cd \dbs\virtuoso
copy <Virtuoso Open Source dir>\binsrc\samples\demo\demo.db
copy <Virtuoso Open Source dir>\binsrc\samples\demo\demo.ini
1 Create a Windows service to run the Virtuoso Open-Source server:
SET PATH=%PATH%;<irtuoso Open Source dir>\win32\Release
virtuoso-t -c demo -I Demo -S create
virtuoso-t -c demo -I Demo -S start
To connect with the command line SQL tool,
isql 1112 dba dba
gives a SQL>
prompt.
To switch to the demo database, containing the Microsoft Northwind sample
tables, type:
SQL> use Demo;
The help command in iSQL can give further instructions.
To use a web admin interface, point the browser to http://localhost:8890/conductor .
To read the online documentation: http://localhost:8890/doc/html
To experiment with online tutorials, http://localhost:8890/tutorial
For VAD Packages, read the README file for Linux.
---+++ .NET CLR hosting server
In order to run the .NET CLR hosting server (virtuoso-clr-t
),
1 Make a folder, e.g., c:\dbs\virtuoso
1 Copy the Demo database (demo.db) and default demo.ini
file to the new directory.
cd c:
cd \dbs\virtuoso
copy <Virtuoso Open Source dir>\binsrc\samples\demo\demo.db
copy <Virtuoso Open Source dir>\binsrc\samples\demo\demo.ini
1 Register the virt_http.dll
in the GAC:
gacutil /i <Virtuoso Open Source dir>\win32\Release\virt_http.dll
1 Make sure virtclr.dll
and virtuoso-clr-t
are in the search path.
1 To try the tutorial examples, Point.dll
and tax.dll
must be copied from <Virtuoso Open Source dir>\binsrc\tutorial\hosting\ho_s_2
to <Virtuoso Open Source dir>\win32\Release\
:
SET PATH=%PATH%;<Virtuoso Open Source dir>\win32\Release
virtuoso-clr-t -c demo -I Demo -S create
virtuoso-clr-t -c demo -I Demo -S start
IMPORTANT: The current version of the .NET CLR hosting server is supported in .NET Framework v1.1 environment.
---+++ Java hosting server
In order to run the Java hosting server (virtuoso-javavm-t
),
1 Make a folder, e.g., c:\dbs\virtuoso
1 Copy the Demo database (demo.db) and default demo.ini
file to the new directory.
cd c:
cd \dbs\virtuoso
copy <Virtuoso Open Source dir>\binsrc\samples\demo\demo.db
copy <Virtuoso Open Source dir>\binsrc\samples\demo\demo.ini
1 Set the CLASSPATH
to the place where Java classes are.
1 Make sure virtuoso-javavm-t
is in the search path
set CLASSPATH=<Virtuoso Open Source dir>\binsrc\tutorial\hosting\ho_s_1;%CLASSPATH%
SET PATH=%PATH%;<Virtuoso Open Source dir>\win32\Release
virtuoso-javavm-t -c demo -I Demo -S create
virtuoso-javavm-t -c demo -I Demo -S start