Commit | Line | Data |
---|---|---|
21e97d3e EA |
1 | ############################################################# |
2 | # | |
3 | # avahi (zeroconf implementation) | |
4 | # | |
5 | ############################################################# | |
6 | # | |
a2e51135 US |
7 | # This program is free software; you can redistribute it |
8 | # and/or modify it under the terms of the GNU Lesser General | |
6c6cb067 | 9 | # Public License as published by the Free Software Foundation |
a2e51135 | 10 | # either version 2.1 of the License, or (at your option) any |
21e97d3e EA |
11 | # later version. |
12 | ||
68f65195 | 13 | AVAHI_VERSION = 0.6.31 |
744c8224 PK |
14 | AVAHI_SOURCE = avahi-$(AVAHI_VERSION).tar.gz |
15 | AVAHI_SITE = http://www.avahi.org/download/ | |
16 | AVAHI_INSTALL_STAGING = YES | |
17 | AVAHI_INSTALL_TARGET = YES | |
21e97d3e | 18 | |
744c8224 | 19 | AVAHI_CONF_ENV = ac_cv_func_strtod=yes \ |
21e97d3e EA |
20 | ac_fsusage_space=yes \ |
21 | fu_cv_sys_stat_statfs2_bsize=yes \ | |
22 | ac_cv_func_closedir_void=no \ | |
23 | ac_cv_func_getloadavg=no \ | |
24 | ac_cv_lib_util_getloadavg=no \ | |
25 | ac_cv_lib_getloadavg_getloadavg=no \ | |
26 | ac_cv_func_getgroups=yes \ | |
27 | ac_cv_func_getgroups_works=yes \ | |
28 | ac_cv_func_chown_works=yes \ | |
29 | ac_cv_have_decl_euidaccess=no \ | |
30 | ac_cv_func_euidaccess=no \ | |
31 | ac_cv_have_decl_strnlen=yes \ | |
32 | ac_cv_func_strnlen_working=yes \ | |
33 | ac_cv_func_lstat_dereferences_slashed_symlink=yes \ | |
34 | ac_cv_func_lstat_empty_string_bug=no \ | |
35 | ac_cv_func_stat_empty_string_bug=no \ | |
36 | vb_cv_func_rename_trailing_slash_bug=no \ | |
37 | ac_cv_have_decl_nanosleep=yes \ | |
38 | jm_cv_func_nanosleep_works=yes \ | |
39 | gl_cv_func_working_utimes=yes \ | |
40 | ac_cv_func_utime_null=yes \ | |
41 | ac_cv_have_decl_strerror_r=yes \ | |
42 | ac_cv_func_strerror_r_char_p=no \ | |
43 | jm_cv_func_svid_putenv=yes \ | |
44 | ac_cv_func_getcwd_null=yes \ | |
45 | ac_cv_func_getdelim=yes \ | |
46 | ac_cv_func_mkstemp=yes \ | |
47 | utils_cv_func_mkstemp_limitations=no \ | |
48 | utils_cv_func_mkdir_trailing_slash_bug=no \ | |
21e97d3e EA |
49 | jm_cv_func_gettimeofday_clobber=no \ |
50 | am_cv_func_working_getline=yes \ | |
51 | gl_cv_func_working_readdir=yes \ | |
52 | jm_ac_cv_func_link_follows_symlink=no \ | |
53 | utils_cv_localtime_cache=no \ | |
54 | ac_cv_struct_st_mtim_nsec=no \ | |
55 | gl_cv_func_tzset_clobber=no \ | |
56 | gl_cv_func_getcwd_null=yes \ | |
57 | gl_cv_func_getcwd_path_max=yes \ | |
58 | ac_cv_func_fnmatch_gnu=yes \ | |
59 | am_getline_needs_run_time_check=no \ | |
60 | am_cv_func_working_getline=yes \ | |
61 | gl_cv_func_mkdir_trailing_slash_bug=no \ | |
62 | gl_cv_func_mkstemp_limitations=no \ | |
63 | ac_cv_func_working_mktime=yes \ | |
64 | jm_cv_func_working_re_compile_pattern=yes \ | |
65 | ac_use_included_regex=no \ | |
0201ffcd | 66 | avahi_cv_sys_cxx_works=yes \ |
b9d4ab00 | 67 | DATADIRNAME=share |
744c8224 PK |
68 | |
69 | AVAHI_CONF_OPT = --localstatedir=/var \ | |
21e97d3e EA |
70 | --disable-qt3 \ |
71 | --disable-qt4 \ | |
21e97d3e | 72 | --disable-gdbm \ |
21e97d3e EA |
73 | --disable-python-dbus \ |
74 | --disable-pygtk \ | |
4e302ac8 | 75 | --disable-gtk3 \ |
21e97d3e EA |
76 | --disable-mono \ |
77 | --disable-monodoc \ | |
01d97bb0 | 78 | --disable-stack-protector \ |
21e97d3e | 79 | --with-distro=none \ |
0e56099e | 80 | $(if $(BR2_HAVE_DOCUMENTATION),--enable,--disable)-manpages \ |
744c8224 | 81 | $(if $(BR2_PACKAGE_AVAHI_AUTOIPD),--enable,--disable)-autoipd \ |
21e97d3e EA |
82 | --with-avahi-user=default \ |
83 | --with-avahi-group=default \ | |
84 | --with-autoipd-user=default \ | |
744c8224 | 85 | --with-autoipd-group=default |
21e97d3e | 86 | |
9abe052f | 87 | AVAHI_DEPENDENCIES = $(if $(BR2_NEEDS_GETTEXT_IF_LOCALE),gettext libintl) host-intltool host-pkg-config |
21e97d3e | 88 | |
744c8224 PK |
89 | ifneq ($(BR2_PACKAGE_AVAHI_DAEMON)$(BR2_PACKAGE_AVAHI_AUTOIPD),) |
90 | AVAHI_DEPENDENCIES += libdaemon | |
91 | else | |
92 | AVAHI_CONF_OPT += --disable-libdaemon | |
93 | endif | |
21e97d3e | 94 | |
744c8224 PK |
95 | ifeq ($(BR2_PACKAGE_AVAHI_DAEMON),y) |
96 | AVAHI_DEPENDENCIES += expat | |
97 | AVAHI_CONF_OPT += --with-xml=expat | |
98 | else | |
99 | AVAHI_CONF_OPT += --with-xml=none | |
100 | endif | |
21e97d3e | 101 | |
ac1d92c4 | 102 | ifeq ($(BR2_PACKAGE_DBUS),y) |
744c8224 PK |
103 | AVAHI_DEPENDENCIES += dbus |
104 | else | |
105 | AVAHI_CONF_OPT += --disable-dbus | |
fdeb9b1a | 106 | endif |
24cb67ca | 107 | |
4801198a PK |
108 | ifeq ($(BR2_PACKAGE_LIBGLIB2),y) |
109 | AVAHI_DEPENDENCIES += libglib2 | |
110 | else | |
111 | AVAHI_CONF_OPT += --disable-glib --disable-gobject | |
112 | endif | |
113 | ||
90ac14b2 PK |
114 | ifeq ($(BR2_PACKAGE_LIBGLADE),y) |
115 | AVAHI_DEPENDENCIES += libglade | |
4801198a PK |
116 | else |
117 | AVAHI_CONF_OPT += --disable-gtk | |
118 | endif | |
119 | ||
6c687a3f PK |
120 | ifeq ($(BR2_PACKAGE_PYTHON),y) |
121 | AVAHI_CONF_ENV += am_cv_pathless_PYTHON=python \ | |
122 | am_cv_path_PYTHON=$(PYTHON_TARGET_BINARY) \ | |
123 | am_cv_python_version=$(PYTHON_VERSION) \ | |
124 | am_cv_python_platform=linux2 \ | |
d20a2eb9 PK |
125 | am_cv_python_pythondir=/usr/lib/python$(PYTHON_VERSION_MAJOR)/site-packages \ |
126 | am_cv_python_pyexecdir=/usr/lib/python$(PYTHON_VERSION_MAJOR)/site-packages \ | |
6c687a3f PK |
127 | py_cv_mod_socket_=yes |
128 | ||
2c3e18cd | 129 | AVAHI_DEPENDENCIES += python |
6c687a3f PK |
130 | AVAHI_CONF_OPT += --enable-python |
131 | else | |
132 | AVAHI_CONF_OPT += --disable-python | |
133 | endif | |
134 | ||
bc9512c0 PK |
135 | ifeq ($(BR2_PACKAGE_LIBINTL),y) |
136 | AVAHI_DEPENDENCIES += libintl | |
744c8224 PK |
137 | AVAHI_MAKE_OPT = LIBS=-lintl |
138 | endif | |
21e97d3e | 139 | |
28025091 | 140 | define AVAHI_REMOVE_INITSCRIPT |
744c8224 | 141 | rm -rf $(TARGET_DIR)/etc/init.d/avahi-* |
28025091 TP |
142 | endef |
143 | ||
144 | AVAHI_POST_INSTALL_TARGET_HOOKS += AVAHI_REMOVE_INITSCRIPT | |
145 | ||
146 | define AVAHI_INSTALL_AUTOIPD | |
744c8224 PK |
147 | rm -rf $(TARGET_DIR)/etc/dhcp3/ |
148 | $(INSTALL) -D -m 0755 package/avahi/busybox-udhcpc-default.script $(TARGET_DIR)/usr/share/udhcpc/default.script | |
149 | $(INSTALL) -m 0755 package/avahi/S05avahi-setup.sh $(TARGET_DIR)/etc/init.d/ | |
150 | rm -f $(TARGET_DIR)/var/lib/avahi-autoipd | |
7810eebb | 151 | $(INSTALL) -d -m 0755 $(TARGET_DIR)/var/lib |
744c8224 | 152 | ln -sf /tmp/avahi-autoipd $(TARGET_DIR)/var/lib/avahi-autoipd |
28025091 TP |
153 | endef |
154 | ||
155 | ifeq ($(BR2_PACKAGE_AVAHI_AUTOIPD),y) | |
156 | AVAHI_POST_INSTALL_TARGET_HOOKS += AVAHI_INSTALL_AUTOIPD | |
21e97d3e | 157 | endif |
28025091 TP |
158 | |
159 | define AVAHI_INSTALL_DAEMON_INITSCRIPT | |
744c8224 | 160 | $(INSTALL) -m 0755 package/avahi/S50avahi-daemon $(TARGET_DIR)/etc/init.d/ |
28025091 TP |
161 | endef |
162 | ||
163 | ifeq ($(BR2_PACKAGE_AVAHI_DAEMON),y) | |
164 | AVAHI_POST_INSTALL_TARGET_HOOKS += AVAHI_INSTALL_DAEMON_INITSCRIPT | |
744c8224 | 165 | endif |
28025091 | 166 | |
300f9c9c | 167 | $(eval $(call AUTOTARGETS)) |