PKG_NAME:=boost
PKG_VERSION:=1.62.0
PKG_SOURCE_VERSION:=1_62_0
-PKG_RELEASE:=1
+PKG_RELEASE:=6
PKG_SOURCE:=$(PKG_NAME)_$(PKG_SOURCE_VERSION).tar.bz2
PKG_SOURCE_URL:=https://sourceforge.net/projects/boost/files/boost/$(PKG_VERSION)
PKG_LICENSE:=Boost Software License <http://www.boost.org/users/license.html>
PKG_MAINTAINER:=Carlos M. Ferreira <carlosmf.pt@gmail.com>
-PKG_BUILD_DEPENDS += boost/host
PKG_BUILD_PARALLEL:=0
PKG_USE_MIPS16:=0
See more at http://www.boost.org/doc/libs/1_62_0/
endef
+PKG_BUILD_DEPENDS:=boost/host PACKAGE_python:python PACKAGE_python3:python3
+
BOOST_LIBS =
define Package/boost-libs
true
endef
-
define Package/boost
$(call Package/boost/Default)
TITLE+= packages
- DEPENDS:=+ALL:boost-libs +ALL:boost-test
endef
define Package/boost/config
config boost-libs-all
bool "Include all Boost libraries."
+ default m if ALL
select PACKAGE_boost-libs
select boost-test-pkg
select boost-coroutine2
config boost-test-pkg
bool "Boost test package."
+ default m if ALL
select PACKAGE_boost-test
config boost-coroutine2
$(foreach lib,$(BOOST_LIBS), \
config PACKAGE_boost-$(lib)
prompt "Boost $(lib) library."
- $(if $(findstring locale,$(lib)),depends on @BUILD_NLS,)
- $(if $(findstring fiber,$(lib)),depends on BROKEN,)
+ default m if ALL
+ $(if $(findstring locale,$(lib)),depends on BUILD_NLS,)\
+ $(if $(findstring python,$(lib)),depends on PACKAGE_$(lib),)
+
)
endmenu
# 1: short name
# 2: dependencies on other boost libraries (short name)
# 3: dependencies on other packages
+# 4: conditional/inward dependencies
define DefineBoostLibrary
- BOOST_DEPENDS+= +boost-$(1)
- BOOST_LIBS+= $(1)
-
+ BOOST_DEPENDS+= +$(if $(4),$(4):boost-$(1),boost-$(1))
PKG_CONFIG_DEPENDS+= CONFIG_PACKAGE_boost-$(1)
+ BOOST_LIBS+= $(1)
+
define Package/boost-$(1)
$(call Package/boost/Default)
TITLE+= ($(1))
- DEPENDS+= $$(foreach lib,$(2),+boost-$$(lib)) $(3)
+ DEPENDS+= $$(foreach lib,$(2),+boost-$$(lib)) $(3) $(if $(4),@$(4),)
HIDDEN:=1
endef
endef
endef
-
$(eval $(call DefineBoostLibrary,atomic,system,))
$(eval $(call DefineBoostLibrary,chrono,system,))
$(eval $(call DefineBoostLibrary,container,,))
$(eval $(call DefineBoostLibrary,coroutine,system chrono context thread,))
$(eval $(call DefineBoostLibrary,date_time,,))
#$(eval $(call DefineBoostLibrary,exception,,))
-$(eval $(call DefineBoostLibrary,fiber,coroutine,))
+$(eval $(call DefineBoostLibrary,fiber,coroutine,,))
$(eval $(call DefineBoostLibrary,filesystem,system,))
$(eval $(call DefineBoostLibrary,graph,regex,))
-$(eval $(call DefineBoostLibrary,iostreams,,+PACKAGE_boost-iostreams:zlib))
-$(eval $(call DefineBoostLibrary,locale,system,$(ICONV_DEPENDS)))
+$(eval $(call DefineBoostLibrary,iostreams,,+zlib))
+$(eval $(call DefineBoostLibrary,locale,system,$(ICONV_DEPENDS),BUILD_NLS))
$(eval $(call DefineBoostLibrary,log,system chrono date_time thread filesystem regex,))
$(eval $(call DefineBoostLibrary,math,,))
#$(eval $(call DefineBoostLibrary,mpi,,)) # OpenMPI does no exist in OpenWRT at this time.
$(eval $(call DefineBoostLibrary,program_options,,))
-$(eval $(call DefineBoostLibrary,python,,+PACKAGE_boost-python:python))
-$(eval $(call DefineBoostLibrary,python3,,+PACKAGE_boost-python3:python3))
+$(eval $(call DefineBoostLibrary,python,,,PACKAGE_python))
+$(eval $(call DefineBoostLibrary,python3,,,PACKAGE_python3))
$(eval $(call DefineBoostLibrary,random,system,))
$(eval $(call DefineBoostLibrary,regex,,))
$(eval $(call DefineBoostLibrary,serialization,,))
$(if $(CONFIG_PACKAGE_boost-python3), -I$(STAGING_DIR)/usr/include/python3.5/) \
$(if $(CONFIG_SOFT_FLOAT),-DBOOST_NO_FENV_H) -fPIC
+EXTRA_CXXFLAGS += $(if $(CONFIG_GCC_VERSION_4_8),-std=gnu++11,-std=gnu++14)
+
ifneq ($(findstring mips,$(ARCH)),)
BOOST_ABI = o32
ifneq ($(findstring 64,$(ARCH)),)
define Build/Compile
$(info Selected Boost API $(BOOST_ABI) for architecture $(ARCH) and cpu $(CPU_TYPE) $(CPU_SUBTYPE))
( cd $(PKG_BUILD_DIR) ; \
- echo "using gcc : $(ARCH) : $(GNU_TARGET_NAME)-gcc : <compileflags>\"$(TARGET_CFLAGS)\" <cxxflags>\"$(TARGET_CXXFLAGS) $(if $(CONFIG_boost-coroutine2),-std=c++14,)\" <linkflags>\"$(TARGET_LDFLAGS)\" ;" > tools/build/src/user-config.jam ; \
+ echo "using gcc : $(ARCH) : $(GNU_TARGET_NAME)-gcc : <compileflags>\"$(TARGET_CFLAGS)\" <cxxflags>\"$(TARGET_CXXFLAGS) $(EXTRA_CXXFLAGS)\" <linkflags>\"$(TARGET_LDFLAGS)\" ;" > tools/build/src/user-config.jam ; \
$(if $(CONFIG_PACKAGE_boost-python3), \
echo "using python : 3.5 : $(STAGING_DIR_ROOT)/usr/bin/python3 : $(STAGING_DIR)/usr/include/python3.5/ ;" >> \
tools/build/src/user-config.jam; \
$(1)/usr/lib
$(FIND) \
- $(PKG_INSTALL_DIR)/lib/ -name 'libboost_$(2)*.so*' -exec $(CP) {} $(1)/usr/lib/ \;
+ $(PKG_INSTALL_DIR)/lib/ -name 'libboost_$(2).so*' -exec $(CP) {} $(1)/usr/lib/ \;
+ $(FIND) \
+ $(PKG_INSTALL_DIR)/lib/ -name 'libboost_$(2)_*.so*' -exec $(CP) {} $(1)/usr/lib/ \;
endef
define Package/boost-test/install