3 include $(TOPDIR
)/rules.mk
8 PKG_MD5SUM
:=1ccbbc46d2aedf0c864b94c58ea220e6
10 PKG_SOURCE_URL
:=http
://www.freedesktop.org
/~lennart
/
11 PKG_SOURCE
:=$(PKG_NAME
)-$(PKG_VERSION
).
tar.gz
14 PKG_BUILD_DIR
:=$(BUILD_DIR
)/$(PKG_NAME
)-$(PKG_VERSION
)
15 PKG_INSTALL_DIR
:=$(PKG_BUILD_DIR
)/ipkg-install
17 include $(TOPDIR
)/package
/rules.mk
19 $(eval
$(call PKG_template
,AVAHI_DAEMON
,avahi-daemon
,$(PKG_VERSION
)-$(PKG_RELEASE
),$(ARCH
)))
20 $(eval
$(call PKG_template
,AVAHI_DNSCONFD
,avahi-dnsconfd
,$(PKG_VERSION
)-$(PKG_RELEASE
),$(ARCH
)))
21 $(eval
$(call PKG_template
,LIBAVAHI
,libavahi
,$(PKG_VERSION
)-$(PKG_RELEASE
),$(ARCH
)))
23 $(PKG_BUILD_DIR
)/.configured
:
24 (cd
$(PKG_BUILD_DIR
); rm -rf config.
{cache
,status
} ; \
25 $(TARGET_CONFIGURE_OPTS
) \
26 CFLAGS
="$(TARGET_CFLAGS) -DNDEBUG" \
27 CPPFLAGS
="-I$(STAGING_DIR)/usr/include" \
28 LDFLAGS
="-L$(STAGING_DIR)/lib -L$(STAGING_DIR)/usr/lib" \
29 PKG_CONFIG_PATH
="$(STAGING_DIR)/usr/lib/pkgconfig" \
30 ac_cv_func_malloc_0_nonnull
=yes \
31 ac_cv_func_realloc_0_nonnull
=yes \
33 --target
=$(GNU_TARGET_NAME
) \
34 --host
=$(GNU_TARGET_NAME
) \
35 --build
=$(GNU_HOST_NAME
) \
41 --datadir=/usr
/share \
42 --includedir=/usr
/include \
43 --infodir=/usr
/share
/info \
45 --libexecdir
=/usr
/lib \
46 --localstatedir
=/var \
47 --mandir=/usr
/share
/man \
50 $(DISABLE_LARGEFILE
) \
62 --disable-doxygen-doc \
63 --disable-doxygen-dot \
64 --disable-doxygen-html \
65 --disable-doxygen-ps \
66 --disable-doxygen-pdf \
68 --with-distro
=openwrt \
69 --with-avahi-user
=nobody \
70 --with-avahi-group
=nogroup \
74 $(PKG_BUILD_DIR
)/.built
:
75 rm -rf
$(PKG_INSTALL_DIR
)
76 mkdir
-p
$(PKG_INSTALL_DIR
)
77 $(MAKE
) -C
$(PKG_BUILD_DIR
) \
78 DESTDIR
="$(PKG_INSTALL_DIR)" \
83 install -d
-m0755
$(IDIR_AVAHI_DAEMON
)/etc
/avahi
84 install -m0644 .
/files
/avahi-daemon.conf
$(IDIR_AVAHI_DAEMON
)/etc
/avahi
/
85 install -d
-m0755
$(IDIR_AVAHI_DAEMON
)/etc
/avahi
/services
86 install -m0644 .
/files
/service-http
$(IDIR_AVAHI_DAEMON
)/etc
/avahi
/services
/http.service
87 install -m0644 .
/files
/service-ssh
$(IDIR_AVAHI_DAEMON
)/etc
/avahi
/services
/ssh.service
88 install -d
-m0755
$(IDIR_AVAHI_DAEMON
)/etc
/init.d
89 install -m0755 .
/files
/avahi-daemon.init
$(IDIR_AVAHI_DAEMON
)/etc
/init.d
/avahi-daemon
90 install -d
-m0755
$(IDIR_AVAHI_DAEMON
)/usr
/sbin
91 cp
-fpR
$(PKG_INSTALL_DIR
)/usr
/sbin
/avahi-daemon
$(IDIR_AVAHI_DAEMON
)/usr
/sbin
/
92 $(RSTRIP
) $(IDIR_AVAHI_DAEMON
)
93 $(IPKG_BUILD
) $(IDIR_AVAHI_DAEMON
) $(PACKAGE_DIR
)
95 $(IPKG_AVAHI_DNSCONFD
):
96 install -d
-m0755
$(IDIR_AVAHI_DNSCONFD
)/etc
/avahi
97 cp
-fpR
$(PKG_INSTALL_DIR
)/etc
/avahi
/avahi-dnsconfd.action
$(IDIR_AVAHI_DNSCONFD
)/etc
/avahi
/
98 install -d
-m0755
$(IDIR_AVAHI_DNSCONFD
)/usr
/sbin
99 cp
-fpR
$(PKG_INSTALL_DIR
)/usr
/sbin
/avahi-dnsconfd
$(IDIR_AVAHI_DNSCONFD
)/usr
/sbin
/
100 $(RSTRIP
) $(IDIR_AVAHI_DNSCONFD
)
101 $(IPKG_BUILD
) $(IDIR_AVAHI_DNSCONFD
) $(PACKAGE_DIR
)
104 install -d
-m0755
$(IDIR_LIBAVAHI
)/usr
/lib
105 cp
-fpR
$(PKG_INSTALL_DIR
)/usr
/lib
/libavahi-common.so.
* $(IDIR_LIBAVAHI
)/usr
/lib
/
106 cp
-fpR
$(PKG_INSTALL_DIR
)/usr
/lib
/libavahi-core.so.
* $(IDIR_LIBAVAHI
)/usr
/lib
/
107 $(RSTRIP
) $(IDIR_LIBAVAHI
)
108 $(IPKG_BUILD
) $(IDIR_LIBAVAHI
) $(PACKAGE_DIR
)
110 $(STAGING_DIR
)/usr
/lib
/avahi.so
: $(PKG_BUILD_DIR
)/.built
111 mkdir
-p
$(STAGING_DIR
)/usr
/include
112 cp
-fpR
$(PKG_INSTALL_DIR
)/usr
/include/avahi-common
$(STAGING_DIR
)/usr
/include/
113 cp
-fpR
$(PKG_INSTALL_DIR
)/usr
/include/avahi-core
$(STAGING_DIR
)/usr
/include/
114 mkdir
-p
$(STAGING_DIR
)/usr
/lib
115 cp
-fpR
$(PKG_INSTALL_DIR
)/usr
/lib
/libavahi-common.a
$(STAGING_DIR
)/usr
/lib
/
116 cp
-fpR
$(PKG_INSTALL_DIR
)/usr
/lib
/libavahi-common.so
* $(STAGING_DIR
)/usr
/lib
/
117 cp
-fpR
$(PKG_INSTALL_DIR
)/usr
/lib
/libavahi-core.a
$(STAGING_DIR
)/usr
/lib
/
118 cp
-fpR
$(PKG_INSTALL_DIR
)/usr
/lib
/libavahi-core.so
* $(STAGING_DIR
)/usr
/lib
/
119 mkdir
-p
$(STAGING_DIR
)/usr
/lib
/pkgconfig
120 cp
-fpR
$(PKG_INSTALL_DIR
)/usr
/lib
/pkgconfig
/avahi-core.
pc $(STAGING_DIR
)/usr
/lib
/pkgconfig
/
121 $(SED
) 's,-I$${includedir},,g' $(STAGING_DIR
)/usr
/lib
/pkgconfig
/avahi-core.
pc
122 $(SED
) 's,-L$${libdir},,g' $(STAGING_DIR
)/usr
/lib
/pkgconfig
/avahi-core.
pc
125 install-dev
: $(STAGING_DIR
)/usr
/lib
/avahi.so
129 $(STAGING_DIR
)/usr
/include/avahi-common \
130 $(STAGING_DIR
)/usr
/include/avahi-core \
131 $(STAGING_DIR
)/usr
/lib
/libavahi-common.a \
132 $(STAGING_DIR
)/usr
/lib
/libavahi-common.so
* \
133 $(STAGING_DIR
)/usr
/lib
/libavahi-core.a \
134 $(STAGING_DIR
)/usr
/lib
/libavahi-core.so
* \
135 $(STAGING_DIR
)/usr
/lib
/pkgconfig
/avahi-core.
pc \
141 -$(MAKE
) -C
$(PKG_BUILD_DIR
) clean
142 rm -f
$(PKG_BUILD_DIR
)/.built