1# $Id$ 2 3# This file is part of avahi. 4# 5# avahi is free software; you can redistribute it and/or modify it 6# under the terms of the GNU Lesser General Public License as 7# published by the Free Software Foundation; either version 2 of the 8# License, or (at your option) any later version. 9# 10# avahi is distributed in the hope that it will be useful, but WITHOUT 11# ANY WARRANTY; without even the implied warranty of MERCHANTABILITY 12# or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public 13# License for more details. 14# 15# You should have received a copy of the GNU Lesser General Public 16# License along with avahi; if not, write to the Free Software 17# Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 18# USA. 19 20AM_CFLAGS=-I$(top_srcdir) 21 22# This cool debug trap works on i386/gcc only 23AM_CFLAGS+='-DDEBUG_TRAP=__asm__("int $$3")' 24 25if HAVE_DBUS 26 27bin_PROGRAMS = avahi-browse avahi-resolve avahi-publish avahi-set-host-name 28 29avahi_browse_SOURCES = avahi-browse.c sigint.c sigint.h 30avahi_browse_CFLAGS = $(AM_CFLAGS) 31avahi_browse_LDADD = $(AM_LDADD) ../avahi-client/libavahi-client.la ../avahi-common/libavahi-common.la 32 33if HAVE_GDBM 34avahi_browse_SOURCES += stdb.h stdb.c 35avahi_browse_CFLAGS += -DDATABASE_FILE=\"$(pkglibdir)/service-types.db\" 36avahi_browse_LDADD += -lgdbm 37endif 38 39if HAVE_DBM 40avahi_browse_SOURCES += stdb.h stdb.c 41avahi_browse_CFLAGS += -DDATABASE_FILE=\"$(pkglibdir)/service-types.db\" 42endif 43 44avahi_resolve_SOURCES = avahi-resolve.c sigint.c sigint.h 45avahi_resolve_CFLAGS = $(AM_CFLAGS) 46avahi_resolve_LDADD = $(AM_LDADD) ../avahi-client/libavahi-client.la ../avahi-common/libavahi-common.la 47 48avahi_publish_SOURCES = avahi-publish.c sigint.c sigint.h 49avahi_publish_CFLAGS = $(AM_CFLAGS) 50avahi_publish_LDADD = $(AM_LDADD) ../avahi-client/libavahi-client.la ../avahi-common/libavahi-common.la 51 52avahi_set_host_name_SOURCES = avahi-set-host-name.c sigint.c sigint.h 53avahi_set_host_name_CFLAGS = $(AM_CFLAGS) 54avahi_set_host_name_LDADD = $(AM_LDADD) ../avahi-client/libavahi-client.la ../avahi-common/libavahi-common.la 55 56install-exec-local: 57 cd $(DESTDIR)/$(bindir) && \ 58 rm -f avahi-resolve-host-name avahi-resolve-address avahi-browse-domains avahi-publish-address avahi-publish-service && \ 59 $(LN_S) avahi-resolve avahi-resolve-host-name && \ 60 $(LN_S) avahi-resolve avahi-resolve-address && \ 61 $(LN_S) avahi-browse avahi-browse-domains && \ 62 $(LN_S) avahi-publish avahi-publish-address && \ 63 $(LN_S) avahi-publish avahi-publish-service 64 65endif 66