Makefile 4.1 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143
  1. # $OpenBSD: Makefile,v 1.153 2017/05/31 08:08:17 espie Exp $
  2. USE_WXNEEDED = Yes
  3. PORTROACH = limit:^2\.4
  4. COMMENT = open source web browser engine for Gtk+
  5. BROKEN-alpha = error: Compiler GCC >= 4.7 or Clang >= 3.3 is required for C compilation
  6. BROKEN-hppa = error: Compiler GCC >= 4.7 or Clang >= 3.3 is required for C compilation
  7. V = 2.4.11
  8. DISTNAME = webkitgtk-${V}
  9. PKGNAME = webkit-${V}
  10. EPOCH = 1
  11. CATEGORIES = www
  12. DPB_PROPERTIES =parallel
  13. EXTRACT_SUFX = .tar.xz
  14. REVISION = 1
  15. HOMEPAGE = http://webkitgtk.org/
  16. MASTER_SITES = ${HOMEPAGE}/releases/
  17. MAINTAINER = Landry Breuil <landry@openbsd.org> \
  18. Antoine Jacoutot <ajacoutot@openbsd.org>
  19. SHARED_LIBS += javascriptcoregtk-${WEBKIT_API_VERSION} 5.0 # 16.19
  20. SHARED_LIBS += webkitgtk-${WEBKIT_API_VERSION} 7.0 # 22.17
  21. # LGPLv2 and BSD
  22. PERMIT_PACKAGE_CDROM = Yes
  23. MODULES = lang/python \
  24. lang/ruby \
  25. x11/gnome
  26. COMPILER = gcc
  27. # cant use clang = needs <chrono> header in StdLib ?
  28. MAKE_FILE = GNUmakefile
  29. PORTHOME = ${WRKDIST}
  30. SUBST_VARS = WEBKIT_API_VERSION GTK_API_VERSION
  31. USE_GMAKE = Yes
  32. LIBTOOL_FLAGS = --tag=disable-static
  33. MODPY_RUNDEP = No
  34. MODRUBY_RUNDEP = No
  35. MODPY_ADJ_FILES = Tools/gtk/generate-feature-defines-files \
  36. Tools/gtk/generate-inspector-gresource-manifest.py
  37. MODGNOME_CPPFLAGS = -I${X11BASE}/include -DLOG_DISABLED=0
  38. MODGNOME_LDFLAGS = -L${X11BASE}/lib -lX11
  39. MODGNOME_TOOLS += gobject-introspection
  40. CONFIGURE_STYLE = gnu
  41. # AR_FLAGS: cf http://trac.webkit.org/changeset/163954
  42. CONFIGURE_ENV = AR_FLAGS="cru" \
  43. ac_cv_path_RUBY=${RUBY}
  44. CONFIGURE_ARGS= --disable-static \
  45. --disable-webkit2 \
  46. --enable-spellcheck \
  47. --with-gtk=${GTK_API_VERSION}
  48. # XXX: uncomment if you want to debug the javascript engine
  49. # this will only build the needed libs and the shell
  50. # ALL_TARGET=jsc
  51. .if ${MACHINE_ARCH} == "powerpc"
  52. # Turns on -O0 globally, makes jsc work ?
  53. CONFIGURE_ARGS += --enable-optimizations=no
  54. # XXX huge hack LDFLAGS is already added a bit before
  55. CONFIGURE_ENV += COVERAGE_LDFLAGS="-Wl,--relax"
  56. .endif
  57. WANTLIB += EGL GL ICE SM X11 X11-xcb Xcomposite Xcursor Xdamage
  58. WANTLIB += Xext Xfixes Xi Xinerama Xrandr Xrender Xt Xxf86vm atk-1.0
  59. WANTLIB += c cairo dbus-1 drm enchant expat ffi fontconfig freetype
  60. WANTLIB += gbm gcrypt gdk_pixbuf-2.0 gio-2.0 glapi glib-2.0 gmodule-2.0
  61. WANTLIB += gobject-2.0 gpg-error graphite2 gstapp-1.0 gstaudio-1.0
  62. WANTLIB += gstbase-1.0 gstfft-1.0 gstpbutils-1.0 gstreamer-1.0
  63. WANTLIB += gsttag-1.0 gstvideo-1.0 gthread-2.0 harfbuzz harfbuzz-icu
  64. WANTLIB += iconv icudata icui18n icuuc intl jpeg lzma m orc-0.4
  65. WANTLIB += pango-1.0 pangocairo-1.0 pangoft2-1.0 pcre pixman-1
  66. WANTLIB += png pthread pthread-stubs secret-1 soup-2.4 sqlite3
  67. WANTLIB += ${LIBCXX} webp xcb xcb-dri2 xcb-glx xcb-render xcb-shape
  68. WANTLIB += xcb-shm xcb-xfixes xml2 xslt z
  69. LIB_DEPENDS = multimedia/gstreamer1/plugins-base \
  70. devel/harfbuzz,-icu \
  71. textproc/libxslt \
  72. textproc/enchant \
  73. graphics/libwebp \
  74. devel/glib2 \
  75. devel/libsoup \
  76. x11/gnome/libsecret
  77. BUILD_DEPENDS = devel/bison \
  78. devel/gettext-tools \
  79. devel/gperf \
  80. geo/geoclue2
  81. RUN_DEPENDS = geo/geoclue2
  82. FLAVORS = gtk3
  83. FLAVOR ?=
  84. .if ${FLAVOR:Mgtk3}
  85. #XXX gross, but needed to have __sync_add_and_fetch_8 on 32-bits
  86. #what about ppc ? hppa ?
  87. .if ${MACHINE_ARCH} == "i386"
  88. CFLAGS += -march=i686
  89. CXXFLAGS += -march=i686
  90. .endif
  91. FULLPKGNAME = webkit-gtk3-${V}
  92. LIB_DEPENDS += x11/gtk+3,-main
  93. WANTLIB += cairo-gobject gdk-3 gtk-3 epoxy atk-bridge-2.0 atspi
  94. WEBKIT_API_VERSION = 3.0
  95. GTK_API_VERSION = 3.0
  96. .else
  97. WEBKIT_API_VERSION = 1.0
  98. GTK_API_VERSION = 2.0
  99. LIB_DEPENDS += x11/gtk+2,-main
  100. WANTLIB += gdk-x11-2.0 gtk-x11-2.0
  101. .endif
  102. pre-configure:
  103. ${SUBST_CMD} ${WRKSRC}/Source/WebCore/plugins/PluginDatabase.cpp ${WRKSRC}/configure
  104. # this ensures gtk-doc files are installed in a versionned directory so that we can
  105. # install both versions alongside, see DOC_MODULE_VERSION in GNUMakefile.in
  106. echo ${WEBKIT_API_VERSION} > ${WRKSRC}/Documentation/webkitdomgtk/version.xml
  107. echo ${WEBKIT_API_VERSION} > ${WRKSRC}/Documentation/webkitgtk/version.xml
  108. post-install:
  109. ${INSTALL_PROGRAM} ${WRKSRC}/Programs/.libs/GtkLauncher ${PREFIX}/bin/GtkLauncher
  110. .if ${FLAVOR:Mgtk3}
  111. mv ${PREFIX}/bin/GtkLauncher ${PREFIX}/bin/GtkLauncher-3
  112. .endif
  113. .include <bsd.port.mk>