show.mapped.folders
[tfs.git] / configure.in
blob41365f1c07190b893e97d2f884b88d3f967af290
1 AC_INIT(opentf, [0.5.3])
3 PKG_PROG_PKG_CONFIG
5 AC_ARG_ENABLE(gtk, 
6         [  --disable-gtk           disable gtk gui support],
7         HAVE_GTK=no,
8   PKG_CHECK_EXISTS(gtk-sharp-2.0, HAVE_GTK=yes, HAVE_GTK=no)
11 # disable experimental stuff for now
12 PKG_CHECK_EXISTS(monodevelop, HAVE_MD=yes, HAVE_MD=no)
14 HAVE_DOC_TOOLS=no
15 AC_CHECK_PROG(ASCIIDOC, [asciidoc], yes)
16 AC_CHECK_PROG(XMLTO, [xmlto], yes)
18 if test "x$ASCIIDOC" = "xyes"; then 
19   if test "x$XMLTO" = "xyes"; then 
20          HAVE_DOC_TOOLS=yes
21   fi
24 AC_ARG_ENABLE(highlight, 
25         [  --enable-highlight      enable syntax highlighting support],
26   PKG_CHECK_EXISTS(gtksourceview-sharp-2.0, HAVE_GTK_SOURCEVIEW=yes, HAVE_GTK_SOURCEVIEW=no)
27   PKG_CHECK_EXISTS(gnome-vfs-sharp-2.0, HAVE_GNOME_VFS=yes, HAVE_GNOME_VFS=no)
30 AC_ARG_ENABLE(keyring, 
31         [  --disable-keyring       disable gnome keyring support],
32         HAVE_GNOME_KEYRING=no,
33         PKG_CHECK_EXISTS(gnome-keyring-sharp, HAVE_GNOME_KEYRING=yes, HAVE_GNOME_KEYRING=no)
36 AC_ARG_WITH(mslibs, 
37         [  --with-mslibs=<dir>     location of Microsoft's Team Foundation Assemblies],
38         HAVE_MSLIBS=$withval,
39         HAVE_MSLIBS=no
42 MONO_VERSION=`pkg-config --modversion mono`
43 HAVE_ATLEAST_GTK_210=`pkg-config --atleast-version=2.10 gtk-sharp-2.0 && echo 1`
44 MD_LIBPATH=`pkg-config monodevelop --variable libdir`
46 HAVE_MAGIC=maybe
48 AC_ARG_ENABLE(magic, 
49         [  --disable-magic         disable libmagic file attributes],
50         HAVE_MAGIC=no,
53 if test "x$HAVE_MAGIC" = "xmaybe"; then 
54   AC_CHECK_LIB(magic, magic_open, HAVE_MAGIC=yes, HAVE_MAGIC=no) 
57 if test "x$prefix" = "xNONE"; then 
58          prefix=/usr/local
61 # assume on windows for now
62 if test "x$MONO_VERSION" = "x"; then 
63          MONO_VERSION=csc-2.0
66 HAVE_SYNTAX_HIGHLIGHTING=no
67 if test "x$HAVE_GNOME_VFS" = "xyes" && test "x$HAVE_GTK_SOURCEVIEW" = "xyes"; then
68   HAVE_SYNTAX_HIGHLIGHTING=yes
71 echo "prefix=$prefix" > build/config.make
72 echo "exec_prefix=\${prefix}" >> build/config.make
73 echo "mono_libdir=\${exec_prefix}/lib" >> build/config.make
74 echo "RUNTIME=mono" >> build/config.make
75 echo "PACKAGE_VERSION=$PACKAGE_VERSION" >> build/config.make
76 echo "MONO_VERSION=$MONO_VERSION" >> build/config.make
77 echo "MONODEVELOP_LIBPATH=$MD_LIBPATH" >> build/config.make
78 echo "MCS_FLAGS=-debug+" >> build/config.make
79 echo "HAVE_GTK=$HAVE_GTK" >> build/config.make
80 echo "HAVE_SYNTAX_HIGHLIGHTING=$HAVE_SYNTAX_HIGHLIGHTING" >> build/config.make
81 echo "HAVE_ATLEAST_GTK_210=$HAVE_ATLEAST_GTK_210" >> build/config.make
82 echo "HAVE_MAGIC=$HAVE_MAGIC" >> build/config.make
83 echo "HAVE_MONODEVELOP=$HAVE_MD" >> build/config.make
84 echo "HAVE_GNOME_KEYRING=$HAVE_GNOME_KEYRING" >> build/config.make
85 echo "HAVE_DOC_TOOLS=$HAVE_DOC_TOOLS" >> build/config.make
86 echo "HAVE_MSLIBS=$HAVE_MSLIBS" >> build/config.make
88 AC_CONFIG_FILES([
89   tools/opentf/tf.sh
90   tools/wit/wit.sh
91         tfs.spec
94 AC_OUTPUT
96 echo
97 echo "Configuration Summary"
98 echo "----------------------------------"
99 echo 
100 echo "     File Type Support: " $HAVE_MAGIC
101 echo "   Man Page Generation: " $HAVE_DOC_TOOLS
102 echo " Gnome Keyring Support: " $HAVE_GNOME_KEYRING
103 echo "           Gui Support: " $HAVE_GTK
104 echo "   Syntax Highlighting: " $HAVE_SYNTAX_HIGHLIGHTING
105 echo 
107 if test "${enable_highlight+set}" = set; then
108   if test "x$HAVE_SYNTAX_HIGHLIGHTING" = "xno"; then
109           echo Note: install libgnome-vfs2.0-cil and libgtksourceview2.0-cil
110           echo       for syntax highlighting support in the "explore" command
111   fi
114 if test "x$HAVE_MAGIC" = "xno"; then
115   echo Note: Team Foundation does not natively track file attributes.
116         echo       Install libmagic on debian-based systems, or file-devel on suse-based
117         echo       for automagic file attribute support.
118   echo
121 if test "x$HAVE_DOC_TOOLS" = "xno"; then
122   echo Note: install asciidoc and xmlto for man page generation.
123         echo