[QBS] set windres name
Philip A Reimer
antreimer at gmail.com
Fri Sep 5 04:29:54 CEST 2014
On Thu, Sep 4, 2014 at 4:16 PM, Jake Petroules <jake.petroules at petroules.com
> wrote:
> On 2014-09-04, at 01:51 PM, Philip A Reimer <antreimer at gmail.com> wrote:
>
> > Where can I do the equivalent to
> >
> > QMAKE_RC = $${CROSS_COMPILE}windres
> >
> > found in qmake.conf for qbs?
> >
> > I currently have /usr/bin/i686-w64-mingw32-windres and
> /usr/bin/x86_64-w64-mingw32-windres
> >
> > Also my libqtmain.a is named libqt5main.a (This is to avoid a conflict
> with qt4)
> >
> > I am currrently just creating symlinks to fix the issues but was
> wondering if there was a way to do this in qbs.
> >
> > -ant32
> >
> > _______________________________________________
> > QBS mailing list
> > QBS at qt-project.org
> > http://lists.qt-project.org/mailman/listinfo/qbs
>
>
> You can use the cpp.windresPath property -- however, don't do this. Qbs
> already internally prepends the toolchain prefix to the windres binary
> name. What you *should* do is set the toolchain prefix, like so:
>
> qbs-config profiles.myprofile32.cpp.toolchainPrefix: "i686-w32-mingw32"
> qbs-config profiles.myprofile64.cpp.toolchainPrefix: "x86_64-w64-mingw32"
>
> qbs-setup-toolchains SHOULD already do all this automatically for you (in
> fact I specifically implemented it to work with the MinGW cross compilers
> out of the box), so I'm curious why it hasn't. Can you please provide us
> with your profile setup (qbs-config --list) and what version of Qbs you are
> using so we can fix the issue if there is indeed one?
> --
> Jake Petroules - jake.petroules at petroules.com
> Chief Technology Officer - Petroules Corporation
Ok I deleted my qbs.conf and regenerated and now it works, thank you. I may
have found the problem if I hadn't tried to modify
.config/QtProject/qbs.conf instead of .config/QtProject/qtcreator/qbs.conf
This is the patch used to rename qtmain to qt5main
https://aur.archlinux.org/packages/mingw-w64-qt5-base
http://pkgs.fedoraproject.org/cgit/mingw-qt5-qtbase.git/tree/
--- qtbase-opensource-src-5.2.1/src/winmain/winmain.pro.orig 2014-04-29
18:51:05.206296152 +0200
+++ qtbase-opensource-src-5.2.1/src/winmain/winmain.pro 2014-04-29
18:51:18.737512221 +0200
@@ -2,7 +2,7 @@
!win32:error("$$_FILE_ is intended only for Windows!")
TEMPLATE = lib
-TARGET = qtmain
+TARGET = qt5main
DESTDIR = $$QT.core.libs
CONFIG += static
--- qtbase-opensource-src-5.2.1/mkspecs/features/create_cmake.prf.orig
2014-04-29 18:53:49.511932034 +0200
+++ qtbase-opensource-src-5.2.1/mkspecs/features/create_cmake.prf
2014-04-29 18:54:44.515819011 +0200
@@ -203,8 +203,8 @@
CMAKE_LIB_FILE_LOCATION_RELEASE = $${CMAKE_QT_STEM}.dll
mingw {
- CMAKE_WINMAIN_FILE_LOCATION_DEBUG = libqtmain$${QT_LIBINFIX}d.a
- CMAKE_WINMAIN_FILE_LOCATION_RELEASE = libqtmain$${QT_LIBINFIX}.a
+ CMAKE_WINMAIN_FILE_LOCATION_DEBUG = libqt5main$${QT_LIBINFIX}.a
+ CMAKE_WINMAIN_FILE_LOCATION_RELEASE = libqt5main$${QT_LIBINFIX}.a
!isEmpty(CMAKE_STATIC_TYPE) {
CMAKE_STATIC_WINDOWS_BUILD = "true"
---
qtbase-opensource-src-5.3.1/mkspecs/features/win32/windows.prf.qtmain
2014-07-05 14:18:23.211155781 +0200
+++ qtbase-opensource-src-5.3.1/mkspecs/features/win32/windows.prf
2014-07-05 14:18:46.045390147 +0200
@@ -6,7 +6,7 @@
mingw:DEFINES += QT_NEEDS_QMAIN
qt:for(entryLib, $$list($$unique(QMAKE_LIBS_QT_ENTRY))) {
- isEqual(entryLib, -lqtmain): {
+ isEqual(entryLib, -lqt5main): {
!contains(QMAKE_DEFAULT_LIBDIRS, $$QT.core.libs): \
QMAKE_LIBS += -L$$QT.core.libs
CONFIG(debug, debug|release): QMAKE_LIBS +=
$${entryLib}$${QT_LIBINFIX}d
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.qt-project.org/pipermail/qbs/attachments/20140904/c5e5ed09/attachment.html>
More information about the Qbs
mailing list