qmake

What is the correct way to include zLib in a Qt project?

十年热恋 提交于 2019-12-11 07:17:57
问题 I'm trying to get this Qt project building, but I'm running into these Undefined symbol error having to do with zLib: Undefined symbols for architecture x86_64: "_z_crc32", referenced from: ZipPrivate::createEntry(QFileInfo const&, QString const&, Zip::CompressionLevel) in zip.o UnzipPrivate::extractFile(QString const&, ZipEntryP const&, QIODevice*, QFlags<UnZip::ExtractionOption>) in unzip.o "_z_deflate", referenced from: ZipPrivate::createEntry(QFileInfo const&, QString const&, Zip:

Issues building PyQt5 for Python3.4 in Ubuntu 14.04 caused by qprinter.h not found then pyuic5 error

江枫思渺然 提交于 2019-12-11 07:05:45
问题 After installing the latest SIP, and the latest Qt5, I tried to build the latest PyQt5 for python 3.4. I launched pyqt5 configure like this: python3 configure.py --qmake=/opt/Qt/5.3/gcc_64/bin/qmake Then make and sudo make install. During sudo make install I obtain this error: cd QtWebKitWidgets/ && ( test -e Makefile || /opt/Qt/5.3/gcc_64/bin/qmake /home/me/Downloads/PyQt-gpl-5.3.2/QtWebKitWidgets/QtWebKitWidgets.pro -o Makefile ) && make -f Makefile install make[1]: Entering directory `

Building Qt 5.8 from source - configure: Unknown command line option '-c++11'

左心房为你撑大大i 提交于 2019-12-11 06:19:03
问题 I followed the instructions from MinGW-64-bit, using Option A: build Qt in MSYS2-shell & MinGW-w64 Win64 Shell. gcc -v says: Using built-in specs. COLLECT_GCC=gcc COLLECT_LTO_WRAPPER=C:/msys64/mingw64/bin/../lib/gcc/x86_64-w64-mingw32/6.3.0/lto-wrapper.exe Target: x86_64-w64-mingw32 Configured with: ../gcc-6.3.0/configure --build=x86_64-w64-mingw32 --disable-isl-version-check --disable-libstdcxx-debug --disable-libstdcxx-pch --disable-multilib --disable-nls --disable-rpath --disable-symvers -

QMake - pass variable to child projects

放肆的年华 提交于 2019-12-11 05:31:47
问题 I have a qmake project with these project files: . parent1.pro . parent2.pro . child_common.pro parent1 and parent2 are both subdirs project and have child_common as a subdir. Is there a way for me to define a variable usable by child_common that have a different value based on which parent the child is used by? For instance: if I'm compiling parent1, child_common should have a variable MY_VAR=A. If I'm compiling parent2 it should have MY_VAR=B 回答1: Well, in fact it's not how the things are

Unable to configure Qt for static building

Deadly 提交于 2019-12-11 05:26:46
问题 Essentially this is a repost of this question which was never answered. I am trying to set up Qt for static linking following these instructions. So far, all I've done is go to where my Qt version is, and run configure -static I get some output, ending in: Sources are in..............C:\QtSDK\Desktop\Qt\4.8.0\msvc2010 Build is done in............C:\QtSDK\Desktop\Qt\4.8.0\msvc2010 Install prefix..............C:\QtSDK\Desktop\Qt\4.8.0\msvc2010 Headers installed to........C:/QtSDK/Desktop/Qt/4.8

Setting up Qt Creator for linking and compiling assembly code

夙愿已清 提交于 2019-12-11 05:23:22
问题 I've been studying C++ and x64 Assembly the last weeks and would like to get into GUI programming with the Qt IDE. The problem is that I can't find a way to link and compile a file containing assembly code. I've been browsing the internet and this site without finding anything helpful. Here is what I have tried so far: .pro QMAKE_CXXFLAGS += -save-temps QT += core gui greaterThan(QT_MAJOR_VERSION, 4): QT += widgets TARGET = test--- TEMPLATE = app DEFINES += QT_DEPRECATED_WARNINGS QMAKE_EXTRA

Dispatching SIMD instructions + SIMDPP + qmake

生来就可爱ヽ(ⅴ<●) 提交于 2019-12-11 05:18:01
问题 I'm developing a QT widget that makes use of SIMD instruction sets. I've compiled 3 versions: SSE3, AVX, and AVX2(simdpp allows to switch between them by a single #define). Now, what I want is for my widget to switch automatically between these implementations, according to best supported instruction set. Guide that is provided with simdpp makes use of some makefile magic: CXXFLAGS="" test: main.o test_sse2.o test_sse3.o test_sse4_1.o test_null.o g++ $^ -o test main.o: main.cc g++ main.cc $

Linker errors when building DLL dependent on static lib Crypto++

旧城冷巷雨未停 提交于 2019-12-11 04:34:23
问题 Here is a preface - I have a C++ + Qt application, it consists of several projects and we are using MSVC 2012 to build it. Now, I'm implementing build scripts to start deploying build server. So, I started creating Qt .pro files for each and every project we have. Now the problem - we use Crypto++ library(http://www.cryptopp.com/) which we build from source code and the output is static lib, and we have DLL which depends on cryptlib.lib. I wrote .pro file for Cryptlib and I'm able to build it

Fail to link Pylon(Basler) SDK with Qt on Mac

点点圈 提交于 2019-12-11 03:44:16
问题 I am trying to link Qt with the Pylon camera SDK in a Qt Creator project. I install the pylon Camera Software Suite app from this pylon for OS X and the pylon framework is install at /Library/Frameworks/pylon.framework . I first follow the pylon Programmer's Guide which is installed with the app to link the pylon with Xcode. It works perfectly. Then I try to link with my Qt Project. I add this in the .pro file: mac: LIBS += -F/Library/Frameworks/ -framework pylon # add GenICam because pylon

qmake: using defines as conditionals

一个人想着一个人 提交于 2019-12-11 00:58:15
问题 How can I define variables to be used in the qmake .pro file? For instance: DEFINES += MYCONDITION # also used in C++ code MYCONDITION { # do something here } Regards, 回答1: you can use CONFIG CONFIG += qt console newstuff newstuff { SOURCES += new.cpp HEADERS += new.h } 回答2: You should use CONFIG += MYCONDITION if you want to create a conditional in the project file and DEFINES to create a conditional for header and cpp files(USING #ifdef etc) 来源: https://stackoverflow.com/questions/34670326