ENVvariable set to a script that was resetting his
gcccould no longer be found. Make sure you do not have any
BASH_ENVin your environment doing things like that. Typing "
unset ENV", etc. before configuring and building should clear it.
bashshell compiled with
--enable-xpg-echo-defaultthat causes some strange behavior with things like
echo "\\1 ..."the
configurescript executes. In particular instead of getting "
\1" the non-printable character "
^A" is produced, and causes failures at compile time like:
../rfb/rfbconfig.h:9:22: warning: extra tokens at end of #ifndef directiveThe workaround is to configure like this:
env CONFIG_SHELL=/bin/sh /bin/sh ./configurei.e. avoid using the bash with the misbehavior. A bug has been filed against autoconf to guard against this.
apt-get install build-essential make bin86 libjpeg62-dev libssl-dev libxtst-devNote that Ubuntu is based on Debian, so perhaps this is the list needed on Debian (testing?) as well. To build in Avahi (mDNS service advertising) support it would appear that
libavahi-client-devis needed as well.
The two files with the large number of cases,
x11vnc.c, have no real need to be optimized
(the code is used only very infrequently). So it is fine to supply
-O0" (disables optimization) to
compiling them. However, it is tricky with autoconf/automake to do this
(especially since both the compiler and make versions have a big effect).
So if the compile times are getting too long for you for these two files
you will need to manually change some things.
configure and when it has finished, edit the
x11vnc/Makefile and put these lines at
the very top:
x11vnc-x11vnc.o : CFLAGS += -O0 x11vnc-remote.o : CFLAGS += -O0Those lines assume gnu make (
gmake) is being used. If you are using another make, say Solaris make, insert these instead:
x11vnc-x11vnc.o := CFLAGS += -O0 x11vnc-remote.o := CFLAGS += -O0You could write a build shell script that modified the Makefile this way before running
-O0" (note it is "capital Oh" followed by "zero")
gcc compiler. If you are using a different
compiler you will need to find the command line option to disable
optimization, or otherwise have the lines set
the empty string.
__threadkeyword to make some of the encodings (i.e. tight) thread safe (multiple VNC clients can be using tight at the same time in x11vnc
-threadsmode.) Evidently on the old SuSE 9.2 system the compiler does not support the thread local storage properly. Here is an example build failure:
tight.c:1126: error: unrecognizable insn: (insn:HI 11 10 13 0 (nil) (set (reg/f:SI 59) (const:SI (plus:SI (symbol_ref:SI ("%lpalette")) (const_int 2048 [0x800])))) -1 (nil) (expr_list:REG_EQUAL (const:SI (plus:SI (symbol_ref:SI ("%lpalette")) (const_int 2048 [0x800]))) (nil))) tight.c:1126: internal compiler error: in extract_insn, at recog.c:2175 Please submit a full bug report, with preprocessed source if appropriate. See URL:http://www.suse.de/feedback for instructions.The workaround is to disable thread local storage at configure time like this:
env CPPFLAGS="-DTLS=''" ./configureand then build it.