Tweak sysutils/healthd version 0.7.9_2
[dports.git] / Mk / bsd.mate.mk
1 #-*- tab-width: 4; -*-
2 # ex:ts=4
3 #
4 # $FreeBSD$
5 #       $NetBSD$
6 #     $MCom: ports-experimental/Mk/bsd.mate.mk,v 1.13 2012/09/03 17:02:31 mezz Exp $
7 #
8 # Please view me with 4 column tabs!
9
10 #######################################################
11 #
12 # *** WARNING: Disable MARCUSCOM before merge in FreeBSD!
13 #     Please also remove this section before merging into FreeBSD.
14 #
15 #MARCUSCOM_CVS=yes
16
17 # ======================= USERS =================================
18 #
19 # There are no significant user-definable settings in here.
20 # This file is a framework to make it easier to create MATE ports.
21 #
22 # ======================= /USERS ================================
23
24 .if !defined(_POSTMKINCLUDED) && !defined(Mate_Pre_Include)
25
26 # Please make sure all changes to this file are passed through the maintainer.
27 # Do not commit them yourself (unless of course you're the Port's Wraith ;).
28 Mate_Include_MAINTAINER=        gnome@FreeBSD.org
29 Mate_Pre_Include=                       bsd.mate.mk
30
31 # This section defines possible names of MATE components and all information
32 # necessary for ports to use those components.
33
34 # Ports can use this as follows:
35 #
36 # USE_MATE=     caja common desktop
37 #
38 # .include <bsd.port.mk>
39 #
40 # As a result proper LIB_DEPENDS/RUN_DEPENDS will be added and CONFIGURE_ENV
41 # and MAKE_ENV defined.
42 #
43
44 # non-version specific components. Do not use :build/:run on those.
45 _USE_MATE_ALL=  autogen intlhack intltool
46
47 # MATE components, you can use the :build or :run if need. Without the :build
48 # and :run, it will be added in both build and run dependency. It will check
49 # for the library dependency first. If not exists then do the build/run on
50 # the *.pc file instead.
51 _USE_MATE_ALL+= caja common controlcenter desktop dialogs docutils icontheme \
52                 libmatekbd libmateweather \
53                 marco menus mucharmap notificationdaemon panel polkit pluma \
54                 settingsdaemon
55
56 SCROLLKEEPER_DIR=       /var/db/rarian
57
58 caja_DETECT=            ${LOCALBASE}/libdata/pkgconfig/libcaja-extension.pc
59 caja_BUILD_DEPENDS=     ${caja_DETECT}:${PORTSDIR}/x11-fm/caja
60 caja_LIB_DEPENDS=       libcaja-extension.so:${PORTSDIR}/x11-fm/caja
61 caja_RUN_DEPENDS=       ${caja_DETECT}:${PORTSDIR}/x11-fm/caja
62
63 mucharmap_DETECT=               ${LOCALBASE}/libdata/pkgconfig/mucharmap-2.pc
64 mucharmap_BUILD_DEPENDS=${mucharmap_DETECT}:${PORTSDIR}/deskutils/mate-character-map
65 mucharmap_LIB_DEPENDS=  libmucharmap.so:${PORTSDIR}/deskutils/mate-character-map
66 mucharmap_RUN_DEPENDS=  ${mucharmap_DETECT}:${PORTSDIR}/deskutils/mate-character-map
67
68 common_DETECT=          ${LOCALBASE}/bin/mate-autogen
69 common_BUILD_DEPENDS=   ${common_DETECT}:${PORTSDIR}/devel/mate-common
70 common_RUN_DEPENDS=     ${common_DETECT}:${PORTSDIR}/devel/mate-common
71
72 controlcenter_DETECT=           ${LOCALBASE}/libdata/pkgconfig/mate-window-settings-2.0.pc
73 controlcenter_BUILD_DEPENDS=    ${controlcenter_DETECT}:${PORTSDIR}/sysutils/mate-control-center
74 controlcenter_LIB_DEPENDS=      libmate-window-settings.so:${PORTSDIR}/sysutils/mate-control-center
75 controlcenter_RUN_DEPENDS=      ${controlcenter_DETECT}:${PORTSDIR}/sysutils/mate-control-center
76
77 desktop_DETECT=         ${LOCALBASE}/libdata/pkgconfig/mate-desktop-2.0.pc
78 desktop_BUILD_DEPENDS=  ${desktop_DETECT}:${PORTSDIR}/x11/mate-desktop
79 desktop_LIB_DEPENDS=    libmate-desktop-2.so:${PORTSDIR}/x11/mate-desktop
80 desktop_RUN_DEPENDS=    ${desktop_DETECT}:${PORTSDIR}/x11/mate-desktop
81
82 dialogs_DETECT=         ${LOCALBASE}/bin/matedialog
83 dialogs_BUILD_DEPENDS=  ${dialogs_DETECT}:${PORTSDIR}/x11/mate-dialogs
84 dialogs_RUN_DEPENDS=    ${dialogs_DETECT}:${PORTSDIR}/x11/mate-dialogs
85
86 docutils_DETECT=        ${LOCALBASE}/libdata/pkgconfig/mate-doc-utils.pc
87 docutils_BUILD_DEPENDS= ${docutils_DETECT}:${PORTSDIR}/textproc/mate-doc-utils
88 docutils_RUN_DEPENDS=   ${docutils_DETECT}:${PORTSDIR}/textproc/mate-doc-utils
89
90 icontheme_DETECT=       ${LOCALBASE}/libdata/pkgconfig/mate-icon-theme.pc
91 icontheme_BUILD_DEPENDS=${icontheme_DETECT}:${PORTSDIR}/x11-themes/mate-icon-theme
92 icontheme_RUN_DEPENDS=  ${icontheme_DETECT}:${PORTSDIR}/x11-themes/mate-icon-theme
93
94 intltool_DETECT=        ${LOCALBASE}/bin/intltool-extract
95 intltool_BUILD_DEPENDS= ${intltool_DETECT}:${PORTSDIR}/textproc/intltool
96
97 intlhack_PRE_PATCH=             ${FIND} ${WRKSRC} -name "intltool-merge.in" | ${XARGS} ${REINPLACE_CMD} -e \
98                                 's|mkdir $$lang or|mkdir $$lang, 0777 or| ; \
99                                  s|^push @INC, "/.*|push @INC, "${LOCALBASE}/share/intltool";| ; \
100                                  s|/usr/bin/iconv|${LOCALBASE}/bin/iconv|g ; \
101                                  s|unpack *[(]'"'"'U\*'"'"'|unpack ('"'"'C*'"'"'|'
102 .if ${USE_MATE:Mintlhack}!=""
103 USE_MATE+=                              intltool
104 .endif
105
106 libmatekbd_DETECT=              ${LOCALBASE}/libdata/pkgconfig/libmatekbd.pc
107 libmatekbd_BUILD_DEPENDS=       ${libmatekbd_DETECT}:${PORTSDIR}/x11/libmatekbd
108 libmatekbd_LIB_DEPENDS=         libmatekbd.so:${PORTSDIR}/x11/libmatekbd
109 libmatekbd_RUN_DEPENDS=         ${libmatekbd_DETECT}:${PORTSDIR}/x11/libmatekbd
110
111 libmateweather_DETECT=          ${LOCALBASE}/libdata/pkgconfig/mateweather.pc
112 libmateweather_BUILD_DEPENDS=   ${libmateweather_DETECT}:${PORTSDIR}/net/libmateweather
113 libmateweather_LIB_DEPENDS=     libmateweather.so:${PORTSDIR}/net/libmateweather
114 libmateweather_RUN_DEPENDS=     ${libmateweather_DETECT}:${PORTSDIR}/net/libmateweather
115
116 marco_DETECT=           ${LOCALBASE}/libdata/pkgconfig/libmarco-private.pc
117 marco_BUILD_DEPENDS=    ${marco_DETECT}:${PORTSDIR}/x11-wm/marco
118 marco_LIB_DEPENDS=      libmarco-private.so:${PORTSDIR}/x11-wm/marco
119 marco_RUN_DEPENDS=      ${marco_DETECT}:${PORTSDIR}/x11-wm/marco
120
121 menus_DETECT=           ${LOCALBASE}/libdata/pkgconfig/libmate-menu.pc
122 menus_BUILD_DEPENDS=    ${menus_DETECT}:${PORTSDIR}/x11/mate-menus
123 menus_LIB_DEPENDS=      libmate-menu.so:${PORTSDIR}/x11/mate-menus
124 menus_RUN_DEPENDS=      ${menus_DETECT}:${PORTSDIR}/x11/mate-menus
125
126 notificationdaemon_DETECT=              ${LOCALBASE}/libexec/mate-notification-daemon
127 notificationdaemon_BUILD_DEPENDS=       ${notificationdaemon_DETECT}:${PORTSDIR}/deskutils/mate-notification-daemon
128 notificationdaemon_RUN_DEPENDS=         ${notificationdaemon_DETECT}:${PORTSDIR}/deskutils/mate-notification-daemon
129
130 panel_DETECT=           ${LOCALBASE}/libdata/pkgconfig/libmatepanelapplet-4.0.pc
131 panel_BUILD_DEPENDS=    ${panel_DETECT}:${PORTSDIR}/x11/mate-panel
132 panel_LIB_DEPENDS=      libmate-panel-applet-4.so:${PORTSDIR}/x11/mate-panel
133 panel_RUN_DEPENDS=      ${panel_DETECT}:${PORTSDIR}/x11/mate-panel
134
135 polkit_DETECT=          ${LOCALBASE}/libdata/pkgconfig/polkit-gtk-mate-1.pc
136 polkit_BUILD_DEPENDS=   ${polkit_DETECT}:${PORTSDIR}/sysutils/mate-polkit
137 polkit_LIB_DEPENDS=     libpolkit-gtk-mate-1.so:${PORTSDIR}/sysutils/mate-polkit
138 polkit_RUN_DEPENDS=     ${polkit_DETECT}:${PORTSDIR}/sysutils/mate-polkit
139
140 pluma_DETECT=           ${LOCALBASE}/libdata/pkgconfig/pluma.pc
141 pluma_BUILD_DEPENDS=    ${pluma_DETECT}:${PORTSDIR}/editors/pluma
142 pluma_RUN_DEPENDS=      ${pluma_DETECT}:${PORTSDIR}/editors/pluma
143
144 settingsdaemon_DETECT=          ${LOCALBASE}/libdata/pkgconfig/mate-settings-daemon.pc
145 settingsdaemon_BUILD_DEPENDS=   ${settingsdaemon_DETECT}:${PORTSDIR}/sysutils/mate-settings-daemon
146 settingsdaemon_RUN_DEPENDS=     ${settingsdaemon_DETECT}:${PORTSDIR}/sysutils/mate-settings-daemon
147
148 # End component definition section
149
150 .endif
151 # End of optional part.
152
153 .if defined(_POSTMKINCLUDED) && !defined(Mate_Post_Include)
154
155 Mate_Post_Include=              bsd.mate.mk
156
157 .if defined(USE_MATE)
158 # Comparing between USE_MATE and _USE_MATE_ALL to make sure the component
159 # exists in _USE_MATE_ALL. If it does not exist then give an error about it.
160 #. for component in ${USE_MATE:O:u:C/^([^:]+).*/\1/}
161 . for component in ${USE_MATE:C/^([^:]+).*/\1/}
162 #. for component in ${USE_GNOME:C/^([^:]+).*/\1/}
163 .  if ${_USE_MATE_ALL:M${component}}==""
164 .error cannot install: Unknown component USE_MATE=${component}
165 .  endif
166 . endfor
167
168 . for component in ${USE_MATE:O:u:C/^([^:]+).*/\1/}
169 .  if defined(${component}_PATCH_DEPENDS)
170 PATCH_DEPENDS+= ${${component}_PATCH_DEPENDS}
171 .  endif
172
173 .  if defined(${component}_DETECT)
174 .   if ${USE_MATE:M${component}\:build}!=""
175 BUILD_DEPENDS+= ${${component}_BUILD_DEPENDS}
176 .   elif ${USE_MATE:M${component}\:run}!=""
177 RUN_DEPENDS+=   ${${component}_RUN_DEPENDS}
178 .   else
179 .    if defined(${component}_LIB_DEPENDS)
180 LIB_DEPENDS+=   ${${component}_LIB_DEPENDS}
181 .    else
182 BUILD_DEPENDS+= ${${component}_BUILD_DEPENDS}
183 RUN_DEPENDS+=   ${${component}_RUN_DEPENDS}
184 .    endif
185 .   endif
186 .  endif
187
188 .  if defined(${component}_CONFIGURE_TARGET)
189 CONFIGURE_ARGS+=${${component}_CONFIGURE_ARGS}
190 .  endif
191
192 .  if defined(${component}_CONFIGURE_ENV)
193 CONFIGURE_ENV+= ${${component}_CONFIGURE_ENV}
194 .  endif
195
196 .  if defined(${component}_MAKE_ENV)
197 MAKE_ENV+=      ${${component}_MAKE_ENV}
198 .  endif
199
200 .  if !defined(CONFIGURE_TARGET) && defined(${component}_CONFIGURE_TARGET)
201 CONFIGURE_TARGET=       ${${component}_CONFIGURE_TARGET}
202 .  endif
203
204 .  if defined(${component}_PRE_PATCH)
205 MATE_PRE_PATCH+=        ; ${${component}_PRE_PATCH}
206 .  endif
207 . endfor
208 .endif # USE_MATE check
209
210 .if ${USE_MATE:Mautogen}!=""
211
212 CONFIGURE_ENV+= NOCONFIGURE=yes
213
214 pre-configure: mate-pre-configure
215
216 mate-pre-configure:
217         @(cd ${CONFIGURE_WRKSRC} ; ${SETENV} ${CONFIGURE_ENV} ./autogen.sh)
218 .endif
219
220 .if defined(MATE_PRE_PATCH)
221
222 pre-configure-script: mate-pre-configure-script
223
224 mate-pre-configure-script:
225         @${MATE_PRE_PATCH:C/^;//1}
226 .endif
227
228 .if ${MAINTAINER}=="gnome@FreeBSD.org"
229 CONFIGURE_FAIL_MESSAGE= "Please run the gnomelogalyzer, available from \"http://www.freebsd.org/gnome/gnomelogalyzer.sh\", which will diagnose the problem and suggest a solution. If - and only if - the gnomelogalyzer cannot solve the problem, report the build failure to the FreeBSD MATE team at ${MAINTAINER}, and attach (a) \"${CONFIGURE_WRKSRC}/${CONFIGURE_LOG}\", (b) the output of the failed make command, and (c) the gnomelogalyzer output. Also, it might be a good idea to provide an overview of all packages installed on your system (i.e. an \`ls ${PKG_DBDIR}\`). Put your attachment up on any website, copy-and-paste into http://freebsd-gnome.pastebin.com, or use send-pr(1) with the attachment. Try to avoid sending any attachments to the mailing list (${MAINTAINER}), because attachments sent to FreeBSD mailing lists are usually discarded by the mailing list software."
230 .endif
231
232 .endif
233 # End of use part.