Skip to content

Commit

Permalink
qtserialport_qt4: enable static build and copy test program
Browse files Browse the repository at this point in the history
closes #1175
  • Loading branch information
Daniel Burr authored and tonytheodore committed Feb 1, 2016
1 parent f089be0 commit a7c2578
Show file tree
Hide file tree
Showing 2 changed files with 13 additions and 1 deletion.
10 changes: 10 additions & 0 deletions src/qtserialport_qt4-1-static.patch
@@ -0,0 +1,10 @@
diff --git a/src/serialport/qt4support/serialport.prf b/src/serialport/qt4support/serialport.prf
index b1d65e1..d20d47a 100644
--- a/src/serialport/qt4support/serialport.prf
+++ b/src/serialport/qt4support/serialport.prf
@@ -25,3 +25,5 @@ mac {
LIBS += -lQtSerialPort$${QT_LIBINFIX}
}
}
+
+static:DEFINES += QT_STATIC
4 changes: 3 additions & 1 deletion src/qtserialport_qt4.mk
Expand Up @@ -15,8 +15,10 @@ $(PKG)_DEPS := gcc qt

$(PKG)_UPDATE := $(call MXE_GET_GITHUB_SHA, $($(PKG)_GH_USER)/$($(PKG)_GH_REPO), $($(PKG)_GH_TREE))

define $(PKG)_BUILD_SHARED
define $(PKG)_BUILD
cd '$(1)' && '$(PREFIX)/$(TARGET)/qt/bin/qmake'
$(MAKE) -C '$(1)' -j '$(JOBS)'
$(MAKE) -C '$(1)' -j 1 install
# install one of the test programs
cp -f '$(1)/examples/serialport/cenumerator/release/cenumerator.exe' '$(PREFIX)/$(TARGET)/bin/test-qtserialport_qt4.exe'
endef

0 comments on commit a7c2578

Please sign in to comment.