summaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/qca-test.pro4
-rw-r--r--src/qca.mk11
2 files changed, 8 insertions, 7 deletions
diff --git a/src/qca-test.pro b/src/qca-test.pro
index 0d4fb25..fb2cf81 100644
--- a/src/qca-test.pro
+++ b/src/qca-test.pro
@@ -1,8 +1,8 @@
# This file is part of MXE. See LICENSE.md for licensing information.
TEMPLATE = app
-greaterThan(QT_MAJOR_VERSION, 4): TARGET = test-qca5
-else: TARGET = test-qca
+greaterThan(QT_MAJOR_VERSION, 4): TARGET = test-qca5-qmake
+else: TARGET = test-qca-qmake
SOURCES += qca-test.cpp
CONFIG += crypto console
QMAKE_CXXFLAGS += -Wall -Werror
diff --git a/src/qca.mk b/src/qca.mk
index 0b7b550..cdde014 100644
--- a/src/qca.mk
+++ b/src/qca.mk
@@ -20,17 +20,18 @@ define $(PKG)_BUILD
$(MAKE) -C '$(BUILD_DIR)' -j $(JOBS)
$(MAKE) -C '$(BUILD_DIR)' -j 1 install
+ # build test as qmake project
$(if $(BUILD_SHARED), \
mkdir '$(BUILD_DIR)/test-qca'
cd '$(BUILD_DIR)/test-qca' && '$(PREFIX)/$(TARGET)/qt5/bin/qmake' '$(PWD)/src/qca-test.pro'
$(MAKE) -C '$(BUILD_DIR)/test-qca' -j $(JOBS) $(BUILD_TYPE)
- $(INSTALL) -m755 '$(BUILD_DIR)/test-qca/$(BUILD_TYPE)/test-qca5.exe' '$(PREFIX)/$(TARGET)/bin/')
+ $(INSTALL) -m755 '$(BUILD_DIR)/test-qca/$(BUILD_TYPE)/test-qca5-qmake.exe' '$(PREFIX)/$(TARGET)/bin/')
- # compile test
+ # build test manually
'$(TARGET)-g++' \
- -W -Wall -Werror \
- '$(SOURCE_DIR)/examples/base64test/base64test.cpp' \
- -o '$(PREFIX)/$(TARGET)/bin/test-$(PKG).exe' \
+ -W -Wall -Werror -std=gnu++11 \
+ '$(PWD)/src/qca-test.cpp' \
+ -o '$(PREFIX)/$(TARGET)/bin/test-$(PKG)-pkgconfig.exe' \
`'$(TARGET)-pkg-config' qca2-qt5 --cflags --libs`
endef