Makefile 4.6 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144
  1. # This file is part of the OpenADK project. OpenADK is copyrighted
  2. # material, please see the LICENCE file in the top-level directory.
  3. include $(ADK_TOPDIR)/rules.mk
  4. PKG_NAME:= firefox
  5. PKG_VERSION:= 49.0.2
  6. PKG_RELEASE:= 1
  7. PKG_HASH:= 67abe9202958c36bf60454c91065953aa8f6ede83ea1c0e9cdb870c3fc3d56d0
  8. PKG_DESCR:= graphical webbrowser
  9. PKG_SECTION:= x11/apps
  10. PKG_DEPENDS:= alsa-lib glib libgtk2 libgtk3 libpng libtiff libxcursor libffi
  11. PKG_DEPENDS+= nspr nss libjpeg-turbo libatk pango cairo libxt libx11 hicolor-icon-theme
  12. PKG_DEPENDS+= libxdamage libxfixes libidl libsqlite libxcomposite gdk-pixbuf libdbus
  13. PKG_DEPENDS+= harfbuzz mesa libvpx libbz2 ca-certificates libevent at-spi2-atk at-spi2-core
  14. PKG_BUILDDEP:= alsa-lib glib libgtk2 libgtk3 libIDL libX11 mesa libtiff gdk-pixbuf
  15. PKG_BUILDDEP+= nspr nss libjpeg-turbo libXt fontconfig sqlite atk libpng hicolor-icon-theme
  16. PKG_BUILDDEP+= libvpx pango gettext-tiny bzip2 libevent bzip2-host python2-host yasm-host
  17. PKG_BUILDDEP+= zip-host autoconf-old-host
  18. PKG_NEEDS:= threads c++
  19. PKG_URL:= http://www.mozilla.org/
  20. PKG_SITES:= http://releases.mozilla.org/pub/mozilla.org/firefox/releases/$(PKG_VERSION)/source/
  21. PKG_CFLINE_FIREFOX:= select ADK_PACKAGE_CAIRO_WITH_TEE@
  22. PKG_CFLINE_FIREFOX+= select ADK_PACKAGE_CAIRO_WITH_XRENDER
  23. PKG_ARCH_DEPENDS:= arm mips mips64 x86 x86_64
  24. PKG_SYSTEM_DEPENDS:= solidrun-imx6 ibm-x40 lemote-yeelong qemu-i686 qemu-x86_64 raspberry-pi raspberry-pi2 raspberry-pi3
  25. DISTFILES:= $(PKG_NAME)-$(PKG_VERSION).source.tar.xz
  26. WRKBUILD= $(WRKDIR)/$(PKG_NAME)-obj
  27. include $(ADK_TOPDIR)/mk/package.mk
  28. include $(ADK_TOPDIR)/mk/python.mk
  29. $(eval $(call PKG_template,FIREFOX,firefox,$(PKG_VERSION)-$(PKG_RELEASE),$(PKG_DEPENDS),$(PKG_DESCR),$(PKG_SECTION)))
  30. CONFIG_STYLE:= minimal
  31. ifeq ($(ADK_DEBUG),y)
  32. CONFIGURE_ARGS+= --enable-debug
  33. else
  34. CONFIGURE_ARGS+= --disable-debug
  35. endif
  36. CONFIGURE_ENV+= CROSS_COMPILE=1 \
  37. OS_ARCH=Linux \
  38. OS_TARGET=Linux \
  39. OS_TEST="$(ADK_TARGET_ARCH)" \
  40. OS_CXXFLAGS="$(TARGET_CXXFLAGS)" \
  41. PYTHON="$(PYTHON)" \
  42. HOST_CC="$(HOST_CC)" \
  43. HOST_CPPFLAGS="$(HOST_CPPFLAGS)" \
  44. HOST_CFLAGS="$(HOST_CFLAGS)" \
  45. HOST_LDFLAGS="$(HOST_LDLAGS)" \
  46. HOST_CXX="$(HOST_CXX)" \
  47. HOST_CXXFLAGS="$(HOST_CXXFLAGS)" \
  48. HOST_RANLIB="ranlib" \
  49. HOST_AR="ar" \
  50. ac_cv_sqlite_secure_delete=yes \
  51. ac_cv_sqlite_threadsafe=yes \
  52. ac_cv_sqlite_enable_fts3=yes \
  53. ac_cv_sqlite_enable_unlock_notify=yes \
  54. ac_cv_sqlite_dbstat_vtab=yes
  55. CONFIGURE_ARGS+= --prefix=/usr \
  56. --target=$(GNU_TARGET_NAME) \
  57. --enable-application=browser \
  58. --enable-official-branding \
  59. --with-system-zlib \
  60. --with-system-bz2 \
  61. --with-system-png \
  62. --with-system-cairo \
  63. --with-system-pixman \
  64. --with-system-jpeg \
  65. --with-system-nss \
  66. --with-system-nspr \
  67. --with-system-libvpx \
  68. --with-system-libevent=$(STAGING_TARGET_DIR)/usr \
  69. --disable-tree-freetype \
  70. --enable-system-ffi \
  71. --enable-system-sqlite \
  72. --enable-chrome-format=jar \
  73. --enable-necko-protocols=all \
  74. --enable-alsa \
  75. --disable-profiling \
  76. --disable-jprof \
  77. --disable-systrace \
  78. --disable-pulseaudio \
  79. --disable-gio \
  80. --disable-gold \
  81. --disable-gconf \
  82. --disable-accessibility \
  83. --disable-dbus \
  84. --disable-gamepad \
  85. --disable-strip \
  86. --disable-install-strip \
  87. --disable-tests \
  88. --disable-gnomeui \
  89. --disable-optimize \
  90. --disable-necko-wifi \
  91. --disable-jemalloc \
  92. --disable-crashreporter \
  93. --disable-printing \
  94. --disable-pie \
  95. --disable-updater \
  96. --disable-url-classifier \
  97. --disable-safe-browsing \
  98. --disable-elf-hack
  99. ifeq ($(ADK_TARGET_SYSTEM_LEMOTE_YEELONG),y)
  100. CONFIGURE_ARGS+= --disable-ion \
  101. --disable-webrtc
  102. TARGET_CFLAGS:= $(subst Os,g3,$(TARGET_CFLAGS))
  103. else
  104. CONFIGURE_ARGS+= --enable-webrtc
  105. endif
  106. XAKE_FLAGS+= CROSS_COMPILE=1 OS_ARCH="Linux" OS_TEST="$(ADK_TARGET_ARCH)" OS_RELEASE="2.6"
  107. XAKE_FLAGS+= HOST_CC=$(HOST_CC) HOST_LDFLAGS=$(HOST_LDFLAGS)
  108. XAKE_FLAGS+= ARCHFLAG="$(TARGET_CFLAGS) $(TARGET_CPPFLAGS) $(TARGET_LDFLAGS) -lnss3 -lnssutil3 -lsmime3 -lssl3 -fPIC"
  109. post-extract:
  110. rm $(WRKSRC)/image/ClippedImage.cpp.rej
  111. pre-configure:
  112. $(SED) '/^freetype\/ftcache.h/a freetype\/ftfntfmt.h' $(WRKSRC)/config/system-headers
  113. post-configure:
  114. touch $(WRKSRC)/configure
  115. touch $(WRKBUILD)/config.status
  116. firefox-install:
  117. $(INSTALL_DIR) $(IDIR_FIREFOX)/usr/bin
  118. $(INSTALL_DIR) $(IDIR_FIREFOX)/usr/lib
  119. $(CP) $(WRKINST)/usr/lib/firefox-$(PKG_VERSION) \
  120. $(IDIR_FIREFOX)/usr/lib
  121. $(INSTALL_BIN) ./files/firefox \
  122. $(IDIR_FIREFOX)/usr/bin
  123. ifeq ($(ADK_APPLIANCE_FIREFOX),y)
  124. $(INSTALL_DIR) $(IDIR_FIREFOX)/etc
  125. $(CP) ./files/xinitrc \
  126. $(IDIR_FIREFOX)/etc
  127. endif
  128. include $(ADK_TOPDIR)/mk/pkg-bottom.mk