mxe/src/itpp.mk

34 lines
1.2 KiB
Makefile
Raw Permalink Normal View History

2017-04-03 13:15:08 +01:00
# This file is part of MXE. See LICENSE.md for licensing information.
PKG := itpp
2018-07-14 00:02:08 +01:00
$(PKG)_WEBSITE := https://itpp.sourceforge.io/
2017-04-03 13:15:08 +01:00
$(PKG)_IGNORE :=
$(PKG)_VERSION := 4.3.1
$(PKG)_CHECKSUM := 50717621c5dfb5ed22f8492f8af32b17776e6e06641dfe3a3a8f82c8d353b877
$(PKG)_SUBDIR := $(PKG)-$($(PKG)_VERSION)
$(PKG)_FILE := $(PKG)-$($(PKG)_VERSION).tar.bz2
$(PKG)_URL := https://$(SOURCEFORGE_MIRROR)/project/$(PKG)/$(PKG)/$($(PKG)_VERSION)/$($(PKG)_FILE)
$(PKG)_DEPS := cc fftw openblas
2017-04-03 13:15:08 +01:00
define $(PKG)_UPDATE
$(WGET) -q -O- 'https://sourceforge.net/projects/itpp/files/itpp/' | \
$(SED) -n 's,.*/\([0-9][0-9.]*\)/".*,\1,p' | \
2017-04-03 13:15:08 +01:00
head -1
endef
define $(PKG)_BUILD
cd '$(BUILD_DIR)' && '$(TARGET)-cmake' '$(SOURCE_DIR)' \
-DITPP_SHARED_LIB=$(CMAKE_SHARED_BOOL) \
-DHTML_DOCS=OFF \
2017-11-20 16:07:55 +00:00
-DBLAS_LIBRARIES="`'$(TARGET)-pkg-config' --libs openblas`" \
-DLAPACK_LIBRARIES="`'$(TARGET)-pkg-config' --libs openblas`"
2017-04-03 13:15:08 +01:00
$(MAKE) -C '$(BUILD_DIR)' -j $(JOBS)
$(MAKE) -C '$(BUILD_DIR)' -j 1 install
# compile test
'$(TARGET)-g++' \
-W -Wall -pedantic \
'$(SOURCE_DIR)/tests/array_test.cpp' -o '$(PREFIX)/$(TARGET)/bin/test-$(PKG).exe' \
`'$(TARGET)-pkg-config' $(PKG) --cflags --libs`
2017-04-03 13:15:08 +01:00
endef