78 | | variant libgcrypt { |
79 | | configure.args-append --with-libgcrypt-prefix=${prefix} |
80 | | depends_lib-append port:libgcrypt |
| 76 | pre-destroot { |
| 77 | xinstall -d ${destroot}${prefix}/include/wireshark/epan/crypt/ |
| 78 | xinstall -d ${destroot}${prefix}/include/wireshark/epan/dfilter/ |
| 79 | xinstall -d ${destroot}${prefix}/include/wireshark/epan/dissectors/ |
| 80 | xinstall -d ${destroot}${prefix}/include/wireshark/epan/ftypes/ |
| 81 | xinstall -d ${destroot}${prefix}/include/wireshark/wiretap/ |
| 82 | xinstall -m 644 -W ${worksrcpath}/ color.h config.h register.h ${destroot}${prefix}/include/wireshark/ |
| 83 | xinstall -m 644 {*}[glob ${worksrcpath}/epan/*.h] ${destroot}${prefix}/include/wireshark/epan/ |
| 84 | xinstall -m 644 {*}[glob ${worksrcpath}/epan/crypt/*.h] ${destroot}${prefix}/include/wireshark/epan/crypt/ |
| 85 | xinstall -m 644 {*}[glob ${worksrcpath}/epan/dfilter/*.h] ${destroot}${prefix}/include/wireshark/epan/dfilter/ |
| 86 | xinstall -m 644 {*}[glob ${worksrcpath}/epan/dissectors/*.h] ${destroot}${prefix}/include/wireshark/epan/dissectors/ |
| 87 | xinstall -m 644 {*}[glob ${worksrcpath}/epan/ftypes/*.h] ${destroot}${prefix}/include/wireshark/epan/ftypes/ |
| 88 | xinstall -m 644 {*}[glob ${worksrcpath}/wiretap/*.h] ${destroot}${prefix}/include/wireshark/wiretap/ |
| 89 | } |
| 90 | |
| 91 | if {[string match *llvm-gcc-4.2* ${configure.compiler}]} { |
| 92 | # see #32386 |
| 93 | configure.cflags -fno-var-tracking |
117 | | depends_lib-append port:libsmi |
118 | | configure.args-append --with-libsmi |
119 | | } |
120 | | |
121 | | # TODO: Remove after 2016-01-04. |
122 | | variant python25 requires python27 description {Legacy variant} {} |
123 | | variant python26 requires python27 description {Legacy variant} {} |
124 | | |
125 | | variant python27 description {use python27 for the experimental python interface} { |
126 | | configure.python ${prefix}/bin/python2.7 |
127 | | depends_lib-append port:python27 |
128 | | } |
129 | | |
130 | | pre-configure { |
131 | | if {[variant_isset python27]} { |
132 | | configure.args-append --with-python |
133 | | configure.args-delete --without-python |
134 | | reinplace "s|python-config|python2.7-config|g" ${worksrcpath}/configure |
135 | | } |
136 | | } |
137 | | |
138 | | pre-destroot { |
139 | | if {[variant_isset python27]} { |
140 | | reinplace "s|libwireshark.dylib|${prefix}/lib/libwireshark.dylib|g" ${worksrcpath}/epan/wspython/wspy_libws.py |
141 | | } |
142 | | } |
143 | | |
144 | | post-destroot { |
145 | | xinstall -d ${destroot}${prefix}/include/wireshark/epan/crypt/ \ |
146 | | ${destroot}${prefix}/include/wireshark/epan/dfilter/ \ |
147 | | ${destroot}${prefix}/include/wireshark/epan/dissectors/ \ |
148 | | ${destroot}${prefix}/include/wireshark/epan/ftypes/ \ |
149 | | ${destroot}${prefix}/include/wireshark/wiretap/ |
150 | | xinstall -m 644 -W ${worksrcpath}/ color.h config.h register.h ${destroot}${prefix}/include/wireshark/ |
151 | | eval xinstall -m 644 [glob ${worksrcpath}/epan/*.h] ${destroot}${prefix}/include/wireshark/epan/ |
152 | | eval xinstall -m 644 [glob ${worksrcpath}/epan/crypt/*.h] ${destroot}${prefix}/include/wireshark/epan/crypt/ |
153 | | eval xinstall -m 644 [glob ${worksrcpath}/epan/dfilter/*.h] ${destroot}${prefix}/include/wireshark/epan/dfilter/ |
154 | | eval xinstall -m 644 [glob ${worksrcpath}/epan/dissectors/*.h] ${destroot}${prefix}/include/wireshark/epan/dissectors/ |
155 | | eval xinstall -m 644 [glob ${worksrcpath}/epan/ftypes/*.h] ${destroot}${prefix}/include/wireshark/epan/ftypes/ |
156 | | eval xinstall -m 644 [glob ${worksrcpath}/wiretap/*.h] ${destroot}${prefix}/include/wireshark/wiretap/ |
157 | | } |
| 135 | configure.args-delete --without-libsmi |
| 136 | configure.args-append --with-libsmi=${prefix} |
| 137 | depends_lib-append port:libsmi |
| 138 | } |
| 139 | |
| 140 | variant geoip { |
| 141 | configure.args-delete --without-geoip |
| 142 | configure.args-append --with-geoip=${prefix} |
| 143 | depends_lib-append port:libgeoip |
| 144 | } |
| 145 | |
| 146 | variant qt description {use qt4 for the GUI} conflicts x11 gtk3 qt5 { |
| 147 | depends_lib-append port:qt4-mac |
| 148 | configure.args-delete --disable-wireshark |
| 149 | configure.args-append --with-qt=4 |
| 150 | configure.args-append --with-gtk2=no |
| 151 | configure.args-append --with-gtk3=no |
| 152 | } |
| 153 | |
| 154 | variant qt5 description {use qt5 for the GUI} conflicts x11 gtk3 qt { |
| 155 | depends_lib-append port:qt5-mac |
| 156 | configure.args-delete --disable-wireshark |
| 157 | configure.args-append --with-qt=5 |
| 158 | configure.args-append --with-gtk2=no |
| 159 | configure.args-append --with-gtk3=no |
| 160 | |
| 161 | configure.pkg_config_path ${configure.pkg_config_path}:${prefix}/libexec/qt5-mac/lib/pkgconfig |
| 162 | configure.env-append PATH=$env(PATH):${prefix}/libexec/qt5-mac/bin |
| 163 | build.env-append PATH=$env(PATH):${prefix}/libexec/qt5-mac/bin |
| 164 | destroot.env-append PKG_CONFIG_PATH=${configure.pkg_config_path} |
| 165 | } |
| 166 | |
| 167 | variant rtp description {add rtp support} { |
| 168 | configure.args-delete --without-portaudio |
| 169 | configure.args-append --with-portaudio=${prefix} |
| 170 | depends_lib-append port:portaudio |
| 171 | } |
| 172 | |
| 173 | variant ssl { |
| 174 | configure.args-delete --without-ssl |
| 175 | configure.args-append --with-ssl=${prefix} |
| 176 | depends_lib-append path:lib/libssl.dylib:openssl |
| 177 | } |
| 178 | |
| 179 | variant x11 description {use X11 (gtk2) for GUI} conflicts qt qt5 gtk3 { |
| 180 | depends_lib-append port:gtk2 \ |
| 181 | port:atk \ |
| 182 | path:lib/pkgconfig/cairo.pc:cairo \ |
| 183 | port:fontconfig \ |
| 184 | port:freetype \ |
| 185 | port:gdk-pixbuf2 \ |
| 186 | path:lib/pkgconfig/pango.pc:pango \ |
| 187 | port:xorg-libX11 \ |
| 188 | port:xorg-libXcomposite \ |
| 189 | port:xorg-libXcursor \ |
| 190 | port:xorg-libXdamage \ |
| 191 | port:xorg-libXext \ |
| 192 | port:xorg-libXfixes \ |
| 193 | port:xorg-libXi \ |
| 194 | port:xorg-libXinerama \ |
| 195 | port:xorg-libXrandr \ |
| 196 | port:xrender |
| 197 | |
| 198 | configure.args-delete --disable-wireshark |
| 199 | configure.args-append --with-qt=no |
| 200 | configure.args-append --with-gtk2=yes |
| 201 | configure.args-append --with-gtk3=no |
| 202 | } |
| 203 | |
| 204 | variant gtk3 description {use X11 (gtk3) for GUI} conflicts qt qt5 x11 { |
| 205 | depends_lib-append port:gtk3 \ |
| 206 | port:adwaita-icon-theme |
| 207 | |
| 208 | configure.args-delete --disable-wireshark |
| 209 | configure.args-append --with-qt=no |
| 210 | configure.args-append --with-gtk2=no |
| 211 | configure.args-append --with-gtk3=yes |
| 212 | } |
| 213 | |
| 214 | platform macosx { |
| 215 | if { [variant_isset qt] || [variant_isset qt5] || [variant_isset x11] || [variant_isset gtk3] } { |
| 216 | patchfiles-append patch-osxapp.diff |
| 217 | destroot.target-append osx-install |
| 218 | destroot.env-append APPLICATIONS_DIR=${applications_dir} |
| 219 | } |
| 220 | } |
| 221 | |
| 222 | livecheck.type regex |
| 223 | livecheck.url ${homepage}download.html |
| 224 | livecheck.regex "Development Release \\((\\d+(?:\\.\\d+)*)" |