blob: afaf917433178b085530d76891044c6ae5042a8f [file] [log] [blame]
DRC2c0ea902010-04-16 07:33:41 +00001*******************************************************************************
2** Building TigerVNC
3*******************************************************************************
4
5
6==================
7Build Requirements
8==================
9
10-- autoconf 2.57 or later
11
12-- automake 1.7 or later
13
14-- libtool 1.4 or later
15
16-- NASM
17 * 0.98 or later is required for a 32-bit build
18 * NASM 2.05 or later is required for a 64-bit build
19 * NASM 2.07 or later is required for a 64-bit build on OS/X (10.6 "Snow
20 Leopard" or later.) This can be obtained from MacPorts
21 (http://www.macports.org/).
22
23 The NASM 2.05 RPMs do not work on older Linux systems, such as Enterprise
24 Linux 4. On such systems, you can easily build and install NASM 2.05
25 from the source RPM by executing the following as root:
26
27 ARCH=`uname -m`
28 wget http://www.nasm.us/pub/nasm/releasebuilds/2.05.01/nasm-2.05.01-1.src.rpm
29 rpmbuild --rebuild nasm-2.05.01-1.src.rpm
30 rpm -Uvh /usr/src/redhat/RPMS/$ARCH/nasm-2.05.01-1.$ARCH.rpm
31
32 NOTE: NASM build will fail if texinfo is not installed.
33
34-- GCC v4.1 or later recommended for best performance
35
36-- X11 development kit
37
38-- If building Xvnc:
39 * Python v2.3 or later
40 * zlib v1.2 or later
41 * OpenSSL v0.9.7 or later
42
43
44=================
45Building TigerVNC
46=================
47
48The following procedure will build the TigerVNC viewer on Linux and Unix
49systems. On 64-bit systems, this may build a 32-bit version of TigerVNC,
50depending on the default compiler configuration for your system. See below for
51specific build instructions for 64-bit systems.
52
53 cd tigervnc
54 autoreconf -fiv
55 sh ./configure [additional configure flags]
56 make
57
58NOTE: Running autoreconf is only necessary if building TigerVNC from the SVN
59repository.
60
61Building the TigerVNC server (Xvnc) is a bit trickier. On newer systems, such
62as Fedora, Xvnc is typically built to use the X11 shared libraries provided
63with the system. This requires a system with Xorg 7.4 or later, however.
64Systems with older versions of Xorg must build a "legacy-friendly" version of
65the TigerVNC server. This is accomplished by downloading and building the
66more recent Xorg modules in a local directory and then building Xvnc such that
67it links against the local build of these libraries, not the X11 libraries
68installed on the system. The "build-xorg" script in the TigerVNC source
69distribution automates this process.
70
71The following procedure will build both the TigerVNC viewer and a
72"legacy-friendly" version of the TigerVNC server:
73
74 cd tigervnc
75 unix/build-xorg init -version 7.4
76 unix/build-xorg build -version 7.4 [-static] [additional configure flags]
77
78Passing an argument of "-static" to the build command line will generate a
79version of Xvnc that has no external dependencies on the X11 shared libraries
80or any other distribution-specific shared libraries. This version of Xvnc
81should be transportable across multiple O/S distributions. The legacy-friendly
82build should work on RedHat Enterprise 4, its contemporaries, and later
83systems. It probably will not work on older systems. It has not been tested
84on non-Linux systems (yet).
85
86build-xorg can also be used to rebuild just the TigerVNC server and viewer,
87once the X11 modules and other dependencies have been built the first time.
88This is convenient for testing changes that just apply to the TigerVNC source
89code. To accomplish this, run:
90
91 unix/build-xorg rebuild [additional make flags]
92
93For instance,
94
95 unix/build-xorg rebuild clean
96
97will clean both the Xvnc and vncviewer builds without destroying any of the
98build configuration or module dependencies.
99
100
101==================================
102Build Recipes for Specific Systems
103==================================
104
105
10632-bit Build on 64-bit Linux
107----------------------------
108
109Add
110
111 --host i686-pc-linux-gnu CFLAGS='-O3 -m32' CXXFLAGS='-O3 -m32'
112
113to the configure and build command lines.
114
115
11664-bit Build on 64-bit OS/X
117---------------------------
118
119Add
120
121 --host x86_64-apple-darwin10.0.0 NASM=/opt/local/bin/nasm
122
123to the configure command line. NASM 2.07 or later from MacPorts must be
124installed.
125
126
12732-bit Build on 64-bit OS/X
128---------------------------
129
130Add
131
132 CFLAGS='-O3 -m32' CXXFLAGS='-O3 -m32' LDFLAGS=-m32
133
134to the configure command line.
135
136
13732-bit Backward-Compatible Build on 64-bit OS/X
138-----------------------------------------------
139
140Add
141
142 CC=gcc-4.0 CXX=g++-4.0 CFLAGS='-isysroot /Developer/SDKs/MacOSX10.4u.sdk \
143 -mmacosx-version-min=10.4 -O3 -m32' \
144 CXXFLAGS='-isysroot /Developer/SDKs/MacOSX10.4u.sdk \
145 -mmacosx-version-min=10.4 -O3 -m32' \
146 LDFLAGS='-isysroot /Developer/SDKs/MacOSX10.4u.sdk \
147 -mmacosx-version-min=10.4 -m32'
148
149to the configure command line. The OS X 10.4 SDK must be installed.
150
151
152*******************************************************************************
153** Creating Release Packages
154*******************************************************************************
155
156The following commands can be used to create various types of release packages:
157
158make dmg
159
160 Create Macintosh package/disk image. This requires the PackageMaker
161 application, which must be installed in /Developer/Applications/Utilities.
162
163make udmg
164
165 On 64-bit OS X (10.6 "Snow Leopard" or later), this creates a version of the
166 Macintosh package/disk image which contains universal i386/x86-64 binaries.
167 The 32-bit fork of these binaries is backward compatible with OS X 10.4 and
168 later, whereas the 64-bit fork is compatible with OS X 10.6 and later. OS X
169 10.4 compatibility SDK required.