How to update GCC in MinGW on Windows?

Update using terminal: Run the command prompt/terminal (cmd or sh). Update the package list: mingw-get update After updating the package list, run: mingw-get upgrade When the command finishes running, all of your packages will be upgraded. Update using the GUI version: If you aren’t used to the terminal, there is also a GUI version of … Read more

How do I configure Qt for cross-compilation from Linux to Windows target?

Just use M cross environment (MXE). It takes the pain out of the whole process: Get it: $ git clone https://github.com/mxe/mxe.git Install build dependencies Build Qt for Windows, its dependencies, and the cross-build tools; this will take about an hour on a fast machine with decent internet access; the download is about 500MB: $ cd … Read more

CMAKE_MAKE_PROGRAM not found

I have two suggestions: Do you have make in your %PATH% environment variable? On my system, I need to add %MINGW_DIR%\bin to %PATH%. Do you have make installed? Depending on your mingw installation, it can be a separate package. Last resort: Can you pass the full path to make on the commandline? cmake -D”CMAKE_MAKE_PROGRAM:PATH=C:/MinGW-32/bin/make.exe” ..\Source

How to stop MinGW and MSYS from mangling path names given at the command line

There is a way to suppress the path translation by setting MSYS_NO_PATHCONV=1 in Windows Git MSys or MSYS2_ARG_CONV_EXCL=”*” in MSYS2. Alternatively, you can set the variable only temporarily just for that command by putting the assignment just before the command itself: MSYS_NO_PATHCONV=1 arm-none-linux-gnueabi-gcc.exe -Wall -g \ -Wl,–dynamic-linker=/usr/lib/myrpath/ld-linux.so.3 \ -Wl,-rpath=/usr/lib/myrpath \ -I../targetsysroot/usr/include \ myprogram.c -o myprogram

How to redirect qDebug, qWarning, qCritical etc output?

You’ve to install a message handler using qInstallMessageHandler function, and then, you can use QTextStream to write the debug message to a file. Here is a sample example: #include <QtGlobal> #include <stdio.h> #include <stdlib.h> void myMessageOutput(QtMsgType type, const QMessageLogContext &context, const QString &msg) { QByteArray localMsg = msg.toLocal8Bit(); switch (type) { case QtDebugMsg: fprintf(stderr, “Debug: … Read more

Unable to copy/paste in MinGW shell

Right-click on the title bar of the command window and select ‘Properties’, then on the ‘Options’ tab tick the box for the ‘QuickEdit mode’, then click ‘Ok’. After that you can paste text from the clipboard using the right mouse-button, highlight text while holding down the left mouse-button and copy selected text using the ENTER … Read more

How can I install MinGW-w64 and MSYS2?

Unfortunately, the MinGW-w64 installer you used sometimes has this issue. I myself am not sure about why this happens (I think it has something to do with Sourceforge URL redirection or whatever that the installer currently can’t handle properly enough). Anyways, if you’re already planning on using MSYS2, there’s no need for that installer. Download … Read more

502 Bad Gateway

502 Bad Gateway


cloudflare