From: James Willcox Date: Fri, 9 Sep 2005 18:41:51 +0000 (+0000) Subject: integrate mono bindings into the build X-Git-Url: https://git.meshlink.io/?a=commitdiff_plain;h=a21074b9ea4b11b74d114e2669248f979caf0d3a;p=catta integrate mono bindings into the build git-svn-id: file:///home/lennart/svn/public/avahi/trunk@540 941a03a8-eaeb-0310-b9a0-b1bbd8fe43fe --- diff --git a/Makefile.am b/Makefile.am index 68abb4f..ace4a05 100644 --- a/Makefile.am +++ b/Makefile.am @@ -51,6 +51,7 @@ SUBDIRS = \ avahi-qt \ avahi-client \ avahi-daemon \ + avahi-sharp \ initscript \ avahi-dnsconfd \ avahi-utils \ @@ -59,6 +60,7 @@ SUBDIRS = \ tests \ service-type-database + DX_INPUT = \ $(srcdir)/avahi-common/cdecl.h \ $(srcdir)/avahi-core/core.h \ diff --git a/avahi-sharp/AddressResolver.cs b/avahi-sharp/AddressResolver.cs index 730645f..a1bc7b2 100644 --- a/avahi-sharp/AddressResolver.cs +++ b/avahi-sharp/AddressResolver.cs @@ -1,3 +1,22 @@ +/*** + This file is part of avahi. + + avahi is free software; you can redistribute it and/or modify it + under the terms of the GNU Lesser General Public License as + published by the Free Software Foundation; either version 2.1 of the + License, or (at your option) any later version. + + avahi is distributed in the hope that it will be useful, but WITHOUT + ANY WARRANTY; without even the implied warranty of MERCHANTABILITY + or FITNESS FOR A PARTICULAR PURPOSE. See the GNU Lesser General + Public License for more details. + + You should have received a copy of the GNU Lesser General Public + License along with avahi; if not, write to the Free Software + Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 + USA. +***/ + using System; using System.Collections; using System.Net; diff --git a/avahi-sharp/AvahiTest.cs b/avahi-sharp/AvahiTest.cs index 0507204..dcc6434 100644 --- a/avahi-sharp/AvahiTest.cs +++ b/avahi-sharp/AvahiTest.cs @@ -1,3 +1,22 @@ +/*** + This file is part of avahi. + + avahi is free software; you can redistribute it and/or modify it + under the terms of the GNU Lesser General Public License as + published by the Free Software Foundation; either version 2.1 of the + License, or (at your option) any later version. + + avahi is distributed in the hope that it will be useful, but WITHOUT + ANY WARRANTY; without even the implied warranty of MERCHANTABILITY + or FITNESS FOR A PARTICULAR PURPOSE. See the GNU Lesser General + Public License for more details. + + You should have received a copy of the GNU Lesser General Public + License along with avahi; if not, write to the Free Software + Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 + USA. +***/ + using System; using System.Net; using Gtk; diff --git a/avahi-sharp/Client.cs b/avahi-sharp/Client.cs index 99651cd..8905110 100644 --- a/avahi-sharp/Client.cs +++ b/avahi-sharp/Client.cs @@ -1,3 +1,22 @@ +/*** + This file is part of avahi. + + avahi is free software; you can redistribute it and/or modify it + under the terms of the GNU Lesser General Public License as + published by the Free Software Foundation; either version 2.1 of the + License, or (at your option) any later version. + + avahi is distributed in the hope that it will be useful, but WITHOUT + ANY WARRANTY; without even the implied warranty of MERCHANTABILITY + or FITNESS FOR A PARTICULAR PURPOSE. See the GNU Lesser General + Public License for more details. + + You should have received a copy of the GNU Lesser General Public + License along with avahi; if not, write to the Free Software + Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 + USA. +***/ + using System; using System.Collections; diff --git a/avahi-sharp/ClientException.cs b/avahi-sharp/ClientException.cs index f38f438..8ed5436 100644 --- a/avahi-sharp/ClientException.cs +++ b/avahi-sharp/ClientException.cs @@ -1,3 +1,22 @@ +/*** + This file is part of avahi. + + avahi is free software; you can redistribute it and/or modify it + under the terms of the GNU Lesser General Public License as + published by the Free Software Foundation; either version 2.1 of the + License, or (at your option) any later version. + + avahi is distributed in the hope that it will be useful, but WITHOUT + ANY WARRANTY; without even the implied warranty of MERCHANTABILITY + or FITNESS FOR A PARTICULAR PURPOSE. See the GNU Lesser General + Public License for more details. + + You should have received a copy of the GNU Lesser General Public + License along with avahi; if not, write to the Free Software + Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 + USA. +***/ + using System; using System.Runtime.InteropServices; diff --git a/avahi-sharp/DomainBrowser.cs b/avahi-sharp/DomainBrowser.cs index deed9b8..32948df 100644 --- a/avahi-sharp/DomainBrowser.cs +++ b/avahi-sharp/DomainBrowser.cs @@ -1,3 +1,22 @@ +/*** + This file is part of avahi. + + avahi is free software; you can redistribute it and/or modify it + under the terms of the GNU Lesser General Public License as + published by the Free Software Foundation; either version 2.1 of the + License, or (at your option) any later version. + + avahi is distributed in the hope that it will be useful, but WITHOUT + ANY WARRANTY; without even the implied warranty of MERCHANTABILITY + or FITNESS FOR A PARTICULAR PURPOSE. See the GNU Lesser General + Public License for more details. + + You should have received a copy of the GNU Lesser General Public + License along with avahi; if not, write to the Free Software + Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 + USA. +***/ + using System; using System.Collections; using System.Runtime.InteropServices; diff --git a/avahi-sharp/EntryGroup.cs b/avahi-sharp/EntryGroup.cs index 74a127c..d8765f3 100644 --- a/avahi-sharp/EntryGroup.cs +++ b/avahi-sharp/EntryGroup.cs @@ -1,3 +1,22 @@ +/*** + This file is part of avahi. + + avahi is free software; you can redistribute it and/or modify it + under the terms of the GNU Lesser General Public License as + published by the Free Software Foundation; either version 2.1 of the + License, or (at your option) any later version. + + avahi is distributed in the hope that it will be useful, but WITHOUT + ANY WARRANTY; without even the implied warranty of MERCHANTABILITY + or FITNESS FOR A PARTICULAR PURPOSE. See the GNU Lesser General + Public License for more details. + + You should have received a copy of the GNU Lesser General Public + License along with avahi; if not, write to the Free Software + Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 + USA. +***/ + using System; using System.Runtime.InteropServices; diff --git a/avahi-sharp/HostNameResolver.cs b/avahi-sharp/HostNameResolver.cs index 62f4149..de2ff51 100644 --- a/avahi-sharp/HostNameResolver.cs +++ b/avahi-sharp/HostNameResolver.cs @@ -1,3 +1,22 @@ +/*** + This file is part of avahi. + + avahi is free software; you can redistribute it and/or modify it + under the terms of the GNU Lesser General Public License as + published by the Free Software Foundation; either version 2.1 of the + License, or (at your option) any later version. + + avahi is distributed in the hope that it will be useful, but WITHOUT + ANY WARRANTY; without even the implied warranty of MERCHANTABILITY + or FITNESS FOR A PARTICULAR PURPOSE. See the GNU Lesser General + Public License for more details. + + You should have received a copy of the GNU Lesser General Public + License along with avahi; if not, write to the Free Software + Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 + USA. +***/ + using System; using System.Collections; using System.Net; diff --git a/avahi-sharp/Makefile.am b/avahi-sharp/Makefile.am index a82f4e6..ffee4cd 100644 --- a/avahi-sharp/Makefile.am +++ b/avahi-sharp/Makefile.am @@ -1,6 +1,9 @@ -all: avahi-sharp.dll +ASSEMBLY = avahi-sharp.dll + +CLEANFILES = $(ASSEMBLY) $(ASSEMBLY).mdb +EXTRA_DIST = $(AVAHISOURCES) avahi.snk AVAHISOURCES = \ $(srcdir)/AddressResolver.cs \ @@ -12,9 +15,14 @@ AVAHISOURCES = \ $(srcdir)/ServiceBrowser.cs \ $(srcdir)/ServiceResolver.cs \ $(srcdir)/ServiceTypeBrowser.cs \ - Utility.cs + $(srcdir)/Utility.cs + +$(ASSEMBLY): $(AVAHISOURCES) + mcs -keyfile:$(srcdir)/avahi.snk -target:library -o $@ -debug $(AVAHISOURCES) -r:Mono.Posix -avahi-sharp.dll: $(AVAHISOURCES) - mcs -target:library -o $@ -debug $(AVAHISOURCES) -r:Mono.Posix +if HAVE_MONO +all: $(ASSEMBLY) -CLEANFILES = avahi-sharp.dll avahi-sharp.dll.mdb +install-data-hook: + $(GACUTIL) /i $(ASSEMBLY) /package avahi-sharp /gacdir $(libdir) /root $(DESTDIR)$(libdir) +endif diff --git a/avahi-sharp/ServiceBrowser.cs b/avahi-sharp/ServiceBrowser.cs index 975746b..d7ae558 100644 --- a/avahi-sharp/ServiceBrowser.cs +++ b/avahi-sharp/ServiceBrowser.cs @@ -1,3 +1,22 @@ +/*** + This file is part of avahi. + + avahi is free software; you can redistribute it and/or modify it + under the terms of the GNU Lesser General Public License as + published by the Free Software Foundation; either version 2.1 of the + License, or (at your option) any later version. + + avahi is distributed in the hope that it will be useful, but WITHOUT + ANY WARRANTY; without even the implied warranty of MERCHANTABILITY + or FITNESS FOR A PARTICULAR PURPOSE. See the GNU Lesser General + Public License for more details. + + You should have received a copy of the GNU Lesser General Public + License along with avahi; if not, write to the Free Software + Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 + USA. +***/ + using System; using System.Net; using System.Collections; diff --git a/avahi-sharp/ServiceResolver.cs b/avahi-sharp/ServiceResolver.cs index af3bf5b..5014297 100644 --- a/avahi-sharp/ServiceResolver.cs +++ b/avahi-sharp/ServiceResolver.cs @@ -1,3 +1,22 @@ +/*** + This file is part of avahi. + + avahi is free software; you can redistribute it and/or modify it + under the terms of the GNU Lesser General Public License as + published by the Free Software Foundation; either version 2.1 of the + License, or (at your option) any later version. + + avahi is distributed in the hope that it will be useful, but WITHOUT + ANY WARRANTY; without even the implied warranty of MERCHANTABILITY + or FITNESS FOR A PARTICULAR PURPOSE. See the GNU Lesser General + Public License for more details. + + You should have received a copy of the GNU Lesser General Public + License along with avahi; if not, write to the Free Software + Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 + USA. +***/ + using System; using System.Collections; using System.Net; diff --git a/avahi-sharp/ServiceTypeBrowser.cs b/avahi-sharp/ServiceTypeBrowser.cs index 0334b96..cd6bfbb 100644 --- a/avahi-sharp/ServiceTypeBrowser.cs +++ b/avahi-sharp/ServiceTypeBrowser.cs @@ -1,3 +1,22 @@ +/*** + This file is part of avahi. + + avahi is free software; you can redistribute it and/or modify it + under the terms of the GNU Lesser General Public License as + published by the Free Software Foundation; either version 2.1 of the + License, or (at your option) any later version. + + avahi is distributed in the hope that it will be useful, but WITHOUT + ANY WARRANTY; without even the implied warranty of MERCHANTABILITY + or FITNESS FOR A PARTICULAR PURPOSE. See the GNU Lesser General + Public License for more details. + + You should have received a copy of the GNU Lesser General Public + License along with avahi; if not, write to the Free Software + Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 + USA. +***/ + using System; using System.Collections; using System.Runtime.InteropServices; diff --git a/avahi-sharp/Utility.cs b/avahi-sharp/Utility.cs index c621bed..d5bdeeb 100644 --- a/avahi-sharp/Utility.cs +++ b/avahi-sharp/Utility.cs @@ -1,3 +1,22 @@ +/*** + This file is part of avahi. + + avahi is free software; you can redistribute it and/or modify it + under the terms of the GNU Lesser General Public License as + published by the Free Software Foundation; either version 2.1 of the + License, or (at your option) any later version. + + avahi is distributed in the hope that it will be useful, but WITHOUT + ANY WARRANTY; without even the implied warranty of MERCHANTABILITY + or FITNESS FOR A PARTICULAR PURPOSE. See the GNU Lesser General + Public License for more details. + + You should have received a copy of the GNU Lesser General Public + License along with avahi; if not, write to the Free Software + Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 + USA. +***/ + using System; using System.Net; using System.Text; diff --git a/configure.ac b/configure.ac index 2986334..15a6436 100644 --- a/configure.ac +++ b/configure.ac @@ -386,6 +386,34 @@ AM_CONDITIONAL(HAVE_PYTHON, [test "x$HAVE_PYTHON" = "xyes" ]) AM_CONDITIONAL(HAVE_PYGTK, test "x$HAVE_PYGTK" = "xyes") AM_CONDITIONAL(HAVE_PYTHON_DBUS, test "x$HAVE_PYTHON_DBUS" = "xyes") +# +# Check for mono stuff +# +AC_ARG_ENABLE(mono, + AS_HELP_STRING([--disable-mono],[Disable mono bindings]), + [case "${enableval}" in + yes) HAVE_MONO=yes ;; + no) HAVE_MONO=no ;; + *) AC_MSG_ERROR(bad value ${enableval} for --enable-mono) ;; + esac], + [HAVE_MONO=yes]) + +if test "x$HAVE_MONO" = "xyes" ; then + AC_PATH_PROG(MCS, mcs) + if test "x$MCS" = "x" ; then + AC_MSG_ERROR([Can not find "mcs" in your PATH]) + fi + + AC_PATH_PROG(GACUTIL, gacutil) + if test "x$GACUTIL" = "x" ; then + AC_MSG_ERROR([Can not find "gacutil" in your PATH]) + fi + + AC_SUBST(MCS) + AC_SUBST(GACUTIL) +fi +AM_CONDITIONAL(HAVE_MONO, test "x$HAVE_MONO" = "xyes") + # # Defining Avahi User and Group. # @@ -546,4 +574,5 @@ echo " Building avahi-discover-standalone: ${HAVE_GTK} Building libavahi-qt3: ${HAVE_QT3} Building libavahi-qt4: ${HAVE_QT4} + Building avahi-sharp: ${HAVE_MONO} "