t5.sample 8.1 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274
  1. # no RCS Id here, please
  2. ONLY_FOR_ARCHS-mono= ${MONO_ARCHS}
  3. COMMENT-main= framework for Multicast DNS Service Discovery
  4. COMMENT-gtk= gtk+2 avahi-ui libraries
  5. COMMENT-gtk3= gtk+3 avahi-ui libraries
  6. COMMENT-gui= GUI client utilities for avahi
  7. COMMENT-mono= mono (.NET) bindings for avahi
  8. COMMENT-qt3= qt3 bindings for avahi
  9. COMMENT-qt4= qt4 bindings for avahi
  10. COMMENT-ui= common avahi-ui header for gtk+2 and gtk+3
  11. V= 0.6.31
  12. DISTNAME= avahi-${V}
  13. CATEGORIES= net devel portcheck
  14. PKGNAME-main= avahi-${V}
  15. PKGNAME-gtk= avahi-gtk-${V}
  16. PKGNAME-gtk3= avahi-gtk3-${V}
  17. PKGNAME-gui= avahi-gui-${V}
  18. PKGNAME-mono= mono-avahi-${V}
  19. PKGNAME-qt3= avahi-qt3-${V}
  20. PKGNAME-qt4= avahi-qt4-${V}
  21. PKGNAME-ui= avahi-ui-${V}
  22. REVISION-main= 10
  23. REVISION-gtk= 5
  24. REVISION-mono= 2
  25. REVISION-qt3= 2
  26. REVISION-qt4= 3
  27. REVISION-ui= 3
  28. MAINTAINER= Antoine Jacoutot <ajacoutot@openbsd.org>
  29. SHARED_LIBS += avahi-common 0.0 # .8.0
  30. SHARED_LIBS += avahi-core 0.0 # .5.5
  31. SHARED_LIBS += avahi-client 5.0 # .5.4
  32. SHARED_LIBS += avahi-glib 0.3 # .1.1
  33. SHARED_LIBS += avahi-gobject 0.0 # .0.1
  34. SHARED_LIBS += howl 9.9 \
  35. dns_sd 0.0 # .1.0
  36. HOMEPAGE= http://www.avahi.org/
  37. # LGPLv2.1
  38. PERMIT_PACKAGE_CDROM= Yes
  39. WANTLIB= ${MODGETTEXT_WANTLIB}
  40. WANTLIB+= qwe
  41. WANTLIB-main= c daemon dbus-1 expat ffi gdbm glib-2.0 gobject-2.0 pcre
  42. WANTLIB-main+= pthread qwe
  43. WANTLIB-gtk= X11 Xcomposite Xcursor Xdamage Xext Xfixes Xi Xinerama
  44. WANTLIB-gtk+= Xrandr Xrender atk-1.0 avahi-client avahi-common
  45. WANTLIB-gtk+= avahi-glib cairo dbus-1 expat ffi fontconfig freetype gdbm
  46. WANTLIB-gtk+= gdk-x11-2.0 gdk_pixbuf-2.0 gio-2.0 glib-2.0 gmodule-2.0
  47. WANTLIB-gtk+= gobject-2.0 graphite2 gthread-2.0 gtk-x11-2.0 harfbuzz m
  48. WANTLIB-gtk+= pango-1.0 pangocairo-1.0 pangoft2-1.0 pcre pixman-1 png
  49. WANTLIB-gtk+= pthread pthread-stubs qwe xcb xcb-render xcb-shm z
  50. WANTLIB-gtk3 = ICE SM X11 Xcomposite Xcursor Xdamage Xext Xfixes Xi
  51. WANTLIB-gtk3 += Xinerama Xrandr Xrender atk-1.0 atk-bridge-2.0 atspi
  52. WANTLIB-gtk3 += avahi-client avahi-common avahi-glib cairo cairo-gobject
  53. WANTLIB-gtk3 += dbus-1 expat ffi fontconfig freetype gdbm gdk-3
  54. WANTLIB-gtk3 += gdk_pixbuf-2.0 gio-2.0 glib-2.0 gmodule-2.0 gobject-2.0
  55. WANTLIB-gtk3 += graphite2 gthread-2.0 gtk-3 harfbuzz m pango-1.0
  56. WANTLIB-gtk3 += pangocairo-1.0 pangoft2-1.0 pcre pixman-1 png pthread
  57. WANTLIB-gtk3 += pthread-stubs qwe xcb xcb-render xcb-shm z
  58. WANTLIB-gui = ICE SM X11 Xcomposite Xcursor Xdamage Xext Xfixes Xi
  59. WANTLIB-gui += Xinerama Xrandr Xrender atk-1.0 atk-bridge-2.0 atspi
  60. WANTLIB-gui += avahi-client avahi-common avahi-core avahi-glib
  61. WANTLIB-gui += avahi-ui-gtk3 c cairo cairo-gobject dbus-1 expat ffi
  62. WANTLIB-gui += fontconfig freetype gdbm gdk-3 gdk_pixbuf-2.0 gio-2.0
  63. WANTLIB-gui += glib-2.0 gmodule-2.0 gobject-2.0 graphite2 gthread-2.0
  64. WANTLIB-gui += gtk-3 harfbuzz m pango-1.0 pangocairo-1.0 pangoft2-1.0
  65. WANTLIB-gui += pcre pixman-1 png pthread pthread-stubs qwe xcb
  66. WANTLIB-gui += xcb-render xcb-shm z
  67. WANTLIB-mono= qwe
  68. WANTLIB-qt3= ${MODQT3_WANTLIB}
  69. WANTLIB-qt3+= GL ICE SM X11 Xcursor Xdamage Xext Xfixes Xft Xi Xinerama
  70. WANTLIB-qt3+= Xmu Xrandr Xrender Xt Xxf86vm avahi-common drm expat
  71. WANTLIB-qt3+= fontconfig freetype jpeg lcms m mng png pthread
  72. WANTLIB-qt3+= pthread-stubs qwe stdc++ xcb z
  73. WANTLIB-qt4= ${MODQT4_WANTLIB}
  74. WANTLIB-qt4+= avahi-common m pthread qwe stdc++
  75. WANTLIB-ui= qwe
  76. MASTER_SITES= ${HOMEPAGE}/download/
  77. PSEUDO_FLAVORS= no_gui no_mono no_qt3 no_qt4 bootstrap
  78. FLAVOR?= no_gui no_mono no_qt3 no_qt4 bootstrap
  79. MULTI_PACKAGES= -main -mono -qt3 -qt4 -gui -gtk -gtk3 -ui
  80. MODULES= devel/gettext \
  81. textproc/intltool
  82. BUILD_DEPENDS= converters/xmltoman \
  83. devel/gobject-introspection \
  84. LIB_DEPENDS-main= ${MODGETTEXT_LIB_DEPENDS} \
  85. devel/glib2 \
  86. databases/gdbm \
  87. devel/libdaemon>=0.14 \
  88. x11/dbus
  89. .include <bsd.port.arch.mk>
  90. .if !${BUILD_PACKAGES:M-gui}
  91. # all these vanish together
  92. BUILD_PACKAGES := ${BUILD_PACKAGES:N-mono:N-gtk:N-gtk3:N-ui}
  93. .endif
  94. .if ${BUILD_PACKAGES:M-mono}
  95. MODULES+= lang/mono
  96. BUILD_DEPENDS+= ${MODMONO_BUILD_DEPENDS} \
  97. x11/mono-gtk2
  98. RUN_DEPENDS-mono= ${MODMONO_RUN_DEPENDS} \
  99. ${BUILD_PKGPATH},-gtk \
  100. x11/mono-gtk2
  101. LIB_DEPENDS-mono= # empty
  102. .else
  103. CONFIGURE_ARGS+= --disable-mono \
  104. --disable-monodoc
  105. .endif
  106. .if ${BUILD_PACKAGES:M-gui}
  107. ### common
  108. MODULES+= lang/python
  109. BUILD_DEPENDS+= lang/python/${MODPY_VERSION},-gdbm \
  110. x11/py-gtk2 \
  111. x11/dbus-python
  112. ### -gtk
  113. SHARED_LIBS += avahi-ui 0.0 # .1.0
  114. LIB_DEPENDS-gtk= ${MODGETTEXT_LIB_DEPENDS} \
  115. x11/gtk+2 \
  116. ${BUILD_PKGPATH}
  117. RUN_DEPENDS-gtk= ${MODGETTEXT_RUN_DEPENDS} \
  118. ${BUILD_PKGPATH},-ui
  119. ### -gtk3
  120. SHARED_LIBS += avahi-ui-gtk3 0.0 # 1.4
  121. LIB_DEPENDS-gtk3= ${MODGETTEXT_LIB_DEPENDS} \
  122. x11/gtk+3 \
  123. ${BUILD_PKGPATH}
  124. RUN_DEPENDS-gtk3= ${MODGETTEXT_RUN_DEPENDS} \
  125. ${BUILD_PKGPATH},-ui
  126. ### -gui
  127. LIB_DEPENDS-gui= ${MODGETTEXT_LIB_DEPENDS} \
  128. ${BUILD_PKGPATH},-gtk3
  129. RUN_DEPENDS-gui= ${MODGETTEXT_RUN_DEPENDS} \
  130. ${MODPY_RUN_DEPENDS} \
  131. lang/python/${MODPY_VERSION},-gdbm \
  132. x11/py-gtk2 \
  133. x11/dbus-python \
  134. devel/py-twisted/web \
  135. devel/desktop-file-utils
  136. ### -ui
  137. LIB_DEPENDS-ui= # empty
  138. RUN_DEPENDS-ui= ${BUILD_PKGPATH}
  139. .else
  140. CONFIGURE_ARGS+= --disable-gtk \
  141. --disable-gtk3 \
  142. --disable-python \
  143. --disable-pygtk \
  144. --disable-python-dbus
  145. .endif
  146. .if ${BUILD_PACKAGES:M-qt3}
  147. SHARED_LIBS += avahi-qt3 0.0 # .1.2
  148. MODULES+= x11/qt3
  149. LIB_DEPENDS-qt3= ${MODGETTEXT_LIB_DEPENDS} \
  150. ${MODQT3_LIB_DEPENDS} \
  151. ${BUILD_PKGPATH}
  152. .else
  153. CONFIGURE_ARGS+= --disable-qt3
  154. .endif
  155. .if ${BUILD_PACKAGES:M-qt4}
  156. SHARED_LIBS += avahi-qt4 0.0 # .1.2
  157. MODULES+= x11/qt4
  158. LIB_DEPENDS-qt4= ${MODGETTEXT_LIB_DEPENDS} \
  159. x11/qt4 \
  160. ${BUILD_PKGPATH}
  161. .else
  162. CONFIGURE_ARGS+= --disable-qt4
  163. .endif
  164. USE_GMAKE= Yes
  165. MODPY_RUNDEP= No
  166. MODMONO_DEPS= No
  167. CFLAGS+= -D_BSD_SOURCE
  168. CONFIGURE_STYLE=gnu
  169. CONFIGURE_ENV= CPPFLAGS="-I${LOCALBASE}/include -I${X11BASE}/include" \
  170. LDFLAGS="-L${LOCALBASE}/lib -L${X11BASE}/lib" \
  171. PTHREAD_CFLAGS="-pthread" \
  172. PTHREAD_LIBS="-pthread" \
  173. PYTHON="${MODPY_BIN}"
  174. CONFIGURE_ARGS+=${CONFIGURE_SHARED} \
  175. --with-dbus-sys="${SYSCONFDIR}/dbus-1/" \
  176. --with-avahi-user=_avahi \
  177. --with-avahi-group=_avahi \
  178. --with-avahi-priv-access-group=wheel \
  179. --with-xml=expat \
  180. --with-distro=none \
  181. --enable-compat-howl \
  182. --enable-compat-libdns_sd \
  183. --enable-core-docs \
  184. --enable-tests \
  185. --enable-introspection \
  186. --disable-autoipd \
  187. --disable-doxygen-doc \
  188. --disable-doxygen-dot \
  189. --disable-doxygen-xml \
  190. --disable-doxygen-html
  191. # don't link with libssp from the gcc4 port
  192. # __guard and __stack_smash_handler are part of libc
  193. CONFIGURE_ARGS+=--disable-stack-protector
  194. FAKE_FLAGS= SYSCONFDIR=${SYSCONFDIR}
  195. PC_FILES= avahi-ui.pc avahi-client.pc avahi-compat-howl.pc \
  196. avahi-compat-libdns_sd.pc avahi-core.pc avahi-glib.pc \
  197. avahi-gobject.pc avahi-qt3.pc avahi-qt4.pc
  198. pre-configure:
  199. find ${WRKSRC} -name Makefile.in -exec \
  200. perl -pi -e 's,LIBINTL,INTLLIBS,g;' \
  201. -e 's,LIBICONV,LTLIBICONV,g' {} \;
  202. find ${WRKSRC}/man -name '*.[1-9]*' | xargs \
  203. perl -pi -e 's,/etc/avahi,${SYSCONFDIR}/avahi,g'
  204. perl -pi -e 's,dbus_connection_disconnect,dbus_connection_close,g' \
  205. ${WRKSRC}/avahi-client/client.c \
  206. ${WRKSRC}/avahi-daemon/dbus-protocol.c
  207. perl -pi -e 's,-ldl,,g' ${WRKSRC}/configure \
  208. ${WRKSRC}/avahi-client/Makefile.in \
  209. ${WRKSRC}/avahi-daemon/Makefile.in
  210. for i in ${PC_FILES}; do \
  211. perl -pi -e 's,Libs:,Libs: -pthread,;' \
  212. -e 's,Cflags:,Cflags: -pthread,' ${WRKSRC}/$${i}.in; done
  213. post-install:
  214. ${INSTALL_DATA_DIR} ${PREFIX}/share/examples
  215. mv ${WRKINST}${SYSCONFDIR}/dbus-1 ${PREFIX}/share/examples/
  216. mv ${WRKINST}${SYSCONFDIR}/avahi ${PREFIX}/share/examples/
  217. # Install the dbus system-service, some applications needs it to
  218. # know that avahi-daemon is running.
  219. ${INSTALL_DATA_DIR} ${PREFIX}/share/dbus-1/system-services
  220. ${INSTALL_DATA} ${WRKBUILD}/avahi-daemon/org.freedesktop.Avahi.service \
  221. ${PREFIX}/share/dbus-1/system-services
  222. # XXX DLLMAP_FILES won't work here since the files are generated during the build process
  223. find ${PREFIX} -name avahi-sharp.dll.config -or -name avahi-ui-sharp.dll.config | \
  224. xargs perl -pi -e 's,\.so(\.[0-9])+,\.so,g'
  225. .include <bsd.port.mk>