Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 0 additions & 1 deletion README

This file was deleted.

3 changes: 3 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@

This project is unmaintained and I will delete it soon. If someone like it, please fork.
==
3 changes: 3 additions & 0 deletions autogen.sh
Original file line number Diff line number Diff line change
Expand Up @@ -2,3 +2,6 @@

autoreconf -i --force --warnings=none
./configure --enable-maintainer-mode $*

# And now, regenerate the API
make -C sources api
114 changes: 89 additions & 25 deletions configure.ac
Original file line number Diff line number Diff line change
@@ -1,10 +1,20 @@
dnl The initialization part
AC_INIT([webkit-sharp], [0.3])
AC_CONFIG_SRCDIR([README])
AC_CANONICAL_TARGET
AM_INIT_AUTOMAKE
AM_MAINTAINER_MODE
AC_PROG_INSTALL

dnl Version information
MONO_REQUIRED_VERSION=2.6.0
WEBKIT_REQUIRED_VERSION=1.3
GTKSHARP_REQUIRED_VERSION=1.9.0

AC_SUBST(MONO_REQUIRED_VERSION)
AC_SUBST(WEBKIT_REQUIRED_VERSION)
AC_SUBST(GTKSHARP_REQUIRED_VERSION)

dnl Package settings
ASSEMBLY_NAME=$PACKAGE
ASSEMBLY_VERSION="1.1.15.0"
Expand All @@ -15,6 +25,8 @@ ASSEMBLY_DESCRIPTION="WebKit bindings for Mono"
ASSEMBLY_COMPANY="Novell, Inc."
ASSEMBLY_COPYRIGHT="2008, 2009 Novell, Inc."
ASSEMBLY_PC=$ASSEMBLY_NAME-1.0
ASSEMBLY_LICENSE="X11/MIT"
ASSEMBLY_URL="http://www.go-mono.org/"

AC_SUBST(ASSEMBLY_NAME)
AC_SUBST(ASSEMBLY_VERSION)
Expand All @@ -25,18 +37,40 @@ AC_SUBST(ASSEMBLY_DESCRIPTION)
AC_SUBST(ASSEMBLY_COMPANY)
AC_SUBST(ASSEMBLY_COPYRIGHT)
AC_SUBST(ASSEMBLY_PC)
AC_SUBST(ASSEMBLY_LICENSE)
AC_SUBST(ASSEMBLY_URL)

dnl Add additional configuration options
AC_ARG_ENABLE(monodoc,
AS_HELP_STRING([--enable-monodoc],[Enable the generation of documentation using monodoc (defaults to yes)]),
[ case "${enableval}" in
yes) enable_monodoc="yes" ;;
no) enable_monodoc="no" ;;
*) AC_MSG_ERROR(bad value ${enableval} for --enable-monodoc) ;;
esac ],
[ enable_monodoc="yes" ])


dnl Check for pkg-config
AC_PATH_PROG(PKG_CONFIG, pkg-config, no)
if test "x$PKG_CONFIG" = "xno"; then
AC_MSG_ERROR(['pkg-config' is not in your PATH.])
fi

dnl Check for Mono
PKG_CHECK_MODULES(MONO_DEPENDENCY, mono >= 1.0, has_mono=true, has_mono=false)
PKG_CHECK_MODULES(MONO_DEPENDENCY, mint >= 1.0, has_mint=true, has_mint=false)

if test "x$has_mono" = "xtrue"; then
dnl Check for mono
PKG_CHECK_MODULES(MONO, mono >= $MONO_REQUIRED_VERSION, has_mono="yes", has_mono="no")
if test "x$has_mono" = "xno" ; then
AC_MSG_ERROR([Mono at version at least $MONO_REQUIRED_VERSION not found])
fi


dnl Check for mono interpreter (mint)
PKG_CHECK_MODULES(MINT_DEPENDENCY, mint >= $MONO_REQUIRED_VERSION, has_mint="yes", has_mint="no")


dnl Check whether to use Mono or Mint
if test "x$has_mono" = "xyes"; then
if test `uname -s` = "Darwin"; then
AC_PATH_PROG(RUNTIME, mono, no)
AC_PATH_PROG(CSC, mcs, no)
Expand All @@ -49,7 +83,7 @@ if test "x$has_mono" = "xtrue"; then
LIB_SUFFIX=
fi
else
if test "x$has_mint" = "xtrue"; then
if test "x$has_mint" = "xyes"; then
AC_PATH_PROG(RUNTIME, mint, no)
AC_PATH_PROG(CSC, mcs, no)
LIB_PREFIX=.so
Expand All @@ -66,37 +100,51 @@ else
fi
fi

AC_SUBST(LIB_PREFIX)
AC_SUBST(LIB_SUFFIX)
AC_SUBST(RUNTIME)


dnl C# compiler checks
CS="C#"
if test "x$CSC" = "xno" ; then
AC_MSG_ERROR([No $CS compiler found])
fi

AC_SUBST(CSC)


dnl Global Assembly Cache util check
AC_PATH_PROG(GACUTIL, gacutil, no)
if test "x$GACUTIL" = "xno" ; then
AC_MSG_ERROR([No gacutil tool found])
fi

GACUTIL_FLAGS="/package $ASSEMBLY_NAME /root "'$(DESTDIR)$(prefix)/lib'
GACUTIL_FLAGS="/package $ASSEMBLY_NAME /root "'$(DESTDIR)$(libdir)'

AC_SUBST(RUNTIME)
AC_SUBST(CSC)
AC_SUBST(GACUTIL)
AC_SUBST(GACUTIL_FLAGS)
AC_SUBST(LIB_PREFIX)
AC_SUBST(LIB_SUFFIX)


dnl Check for gtk-sharp
PKG_CHECK_MODULES(GTK_SHARP, gtk-sharp-2.0 >= 1.9.0)
PKG_CHECK_MODULES(GTK_SHARP, gtk-sharp-2.0 >= $GTKSHARP_REQUIRED_VERSION)
gtksharp_prefix=`pkg-config --variable=prefix gtk-sharp-2.0`

AC_SUBST(GTK_SHARP_CFLAGS)
AC_SUBST(GTK_SHARP_LIBS)
gtksharp_prefix=`pkg-config --variable=prefix gtk-sharp-2.0`
AC_SUBST(gtksharp_prefix)


dnl Check for WebKit
PKG_CHECK_MODULES(WEBKIT, webkit-1.0 >= 1.1.15)
AC_SUBST(WEBKIT_LIBS)
PKG_CHECK_MODULES(WEBKIT, webkit-1.0 >= $WEBKIT_REQUIRED_VERSION)
webkit_prefix=`pkg-config --variable=prefix webkit-1.0`
webkit_version=`pkg-config --modversion webkit-1.0`
ASSEMBLY_PACKAGE_VERSION=$webkit_version

AC_SUBST(WEBKIT_LIBS)
AC_SUBST(webkit_prefix)
AC_SUBST(ASSEMBLY_PACKAGE_VERSION)


dnl Check for gapi
AC_PATH_PROG(GAPI_PARSER, gapi2-parser, no)
Expand All @@ -109,7 +157,6 @@ if test "x$GAPI_PARSER" = "xno"; then
AC_MSG_RESULT($GAPI_PARSER)
GAPI_PARSER="$MONO $GAPI_PARSER"
fi
AC_SUBST(GAPI_PARSER)

AC_PATH_PROG(GAPI_FIXUP, gapi2-fixup, no)
if test "x$GAPI_FIXUP" = "xno"; then
Expand All @@ -121,7 +168,6 @@ if test "x$GAPI_FIXUP" = "xno"; then
AC_MSG_RESULT($GAPI_FIXUP)
GAPI_FIXUP="$MONO $GAPI_FIXUP"
fi
AC_SUBST(GAPI_FIXUP)

AC_PATH_PROG(GAPI_CODEGEN, gapi2-codegen, no)
if test "x$GAPI_CODEGEN" = "xno"; then
Expand All @@ -133,23 +179,37 @@ if test "x$GAPI_CODEGEN" = "xno"; then
AC_MSG_RESULT([$GAPI_CODEGEN])
GAPI_CODEGEN="$MONO $GAPI_CODEGEN"
fi

AC_SUBST(GAPI_PARSER)
AC_SUBST(GAPI_FIXUP)
AC_SUBST(GAPI_CODEGEN)


dnl Check for monodoc
AC_PATH_PROG(MDASSEMBLER, mdassembler, no)
AC_PATH_PROG(MONODOCER, monodocer, no)
if test "x$MONODOCER" = "xno" -o "x$MDASSEMBLER" = "xno"; then
enable_monodoc=no
doc_sources_dir=
# We check existance only if documentation is wanted
if test "x$enable_monodoc" = "xyes" ; then
AC_PATH_PROG(MDASSEMBLER, mdassembler, no)
AC_PATH_PROG(MONODOCER, monodocer, no)
if test "x$MONODOCER" = "xno" -o "x$MDASSEMBLER" = "xno"; then
enable_monodoc=no
doc_sources_dir=
else
enable_monodoc=yes
doc_sources_dir="`pkg-config --variable=sourcesdir monodoc`"
fi
else
enable_monodoc=yes
doc_sources_dir="`pkg-config --variable=sourcesdir monodoc`"
MDASSEMBLER=
MONODOCER=
fi

AM_CONDITIONAL(ENABLE_MONODOC, test "x$enable_monodoc" = "xyes")

AC_SUBST(MDASSEMBLER)
AC_SUBST(MONODOCER)
AC_SUBST(enable_monodoc)

AM_CONDITIONAL(ENABLE_MONODOC, test "x$enable_monodoc" = "xyes")

dnl Configuration files
AC_CONFIG_FILES([
Makefile
webkit-sharp.spec
Expand All @@ -161,6 +221,9 @@ AC_CONFIG_FILES([
sources/webkit-sharp.dll.config
])
AC_CONFIG_COMMANDS([default],[[ echo timestamp > stamp-h ]],[[]])


dnl Output for user info
AC_OUTPUT

echo ""
Expand All @@ -169,6 +232,7 @@ echo "---------------------"
echo ""
echo " * Installation prefix: $prefix"
echo " * compiler: $CSC"
echo " * Documentation: $enable_monodoc ($MONODOC)"
echo " * Documentation: $enable_monodoc ($MONODOCER)"
echo " * WebKit version: $webkit_version"
echo ""

2 changes: 1 addition & 1 deletion doc/Makefile.am
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
if ENABLE_MONODOC
TARGETS = $(ASSEMBLY_NAME)-docs.source $(ASSEMBLY_NAME)-docs.zip $(ASSEMBLY_NAME)-docs.tree
docsdir = $(prefix)/lib/monodoc/sources
docsdir = $(libdir)/monodoc/sources
docs_DATA = $(TARGETS)
else
TARGETS =
Expand Down
6 changes: 3 additions & 3 deletions samples/FunnyBrowser.cs
Original file line number Diff line number Diff line change
Expand Up @@ -40,10 +40,10 @@ public static void Main (string[] args)
{
string url = (args.Length > 0) ? args[0] : "";

Application.Init ();
Gtk.Application.Init ();
MainWindow window = new MainWindow (url);
window.Show ();
Application.Run ();
Gtk.Application.Run ();
}
}

Expand Down Expand Up @@ -181,7 +181,7 @@ private void CreateFindbar ()

protected void OnDeleteEvent (object sender, DeleteEventArgs args)
{
Application.Quit ();
Gtk.Application.Quit ();
args.RetVal = true;
}

Expand Down
Loading