mingw

Objective-c mingw in windows

What tutorials cover how to use Objective-C in Windows? I heard about mingw, but I couldn't configure it. I would like to only create command-line programs because I heard that there is no iPhone/iPad simulator for Windows and I would like to learn Objective-C. ...

When main is defined without parameters, will argc and argv still be present on the stack?

Consider the very simple: int main(void) { return 0; } I compiled it (with mingw32-gcc) and executed it as main.exe foo bar. Now, I had expected some sort of crash or error caused by a main function explicitly declared as being bereft of life parameters. The lack of errors led to this question, which is really four questions. W...

MinGW WinSock struct definition missing

I have the source for a cross-platform library. It compiles fine under MSVC but I'd like to compile it under MinGW. The MinGW winsock2.h does not contain a definition for the defintion for struct ip_mreq, which is found in Windows' SDK WinSock.h file. What is an elegant way to go about fixing this (among other discrepancies yet to be d...

Qt C++, Eclipse (on Win 7) - project build failed with "unresolved reference to _Unwind_Resume" error

I've got Windows 7 64-bit and I just installed Qt (open-source, version 2010.04) and integrated it into Eclipse (CDT, version Helios). Everything seemed to went fine, I added paths to both Qt and mingw32 compiler and configured Qt by running configure.exe. The integration with Eclipse works fine too. However, I've problem with the first...

Qt3Support and mingw static linker error

I had a problem at first compiling Qt static on windows, QTBUG-11249 When configured with "-no-qt3support", the build completes fine. i did that and compiled successfully, but i get the same errors when i try to compile my application. e:\Qt\2010.04-static\qt\lib/libQtGui.a(qapplication.o):qapplication.cpp:(.text+0x8e0f): undef...

Boost thread_interrupted exception terminate()s with MinGW gcc 4.4.0, OK with 3.4.5

I've been "playing around with" boost threads today as a learning exercise, and I've got a working example I built quite a few months ago (before I was interrupted and had to drop multi-threading for a while) that's showing unusual behaviour. When I initially wrote it I was using MingW gcc 3.4.5, and it worked. Now I'm using 4.4.0 and i...

Embedding SpiderMonkey in a portable C app.

Hi folks, I'd like to embed Mozilla's SpiderMonkey in one of my C apps. On linux, I don't think it'll be a problem (I'm a linux user) but I must confess that I'm afraid that I have no clue on how to do it on windows using MINGW (I want the app to be portable) Is it possible to, say, just use the dll that comes with firefox? (I, honnest...

trying to extend ruby with win32 programming

I have some C++ Win32 code that I want to call from Ruby. But the code needs to be set up like this int WinMain(HINSTANCE hInstance, HINSTANCE hPrevInstance, LPSTR lpCmdLine, int nShowCmd) otherwise things don't work right when I try creating windows and stuff. I don't know how to do that with a Ruby extension. What can I do? Is the...

How to best deal with Windows' 16-bit wchar_t ugliness?

I'm writing a wrapper layer to be used with mingw which provides the application with a virtual UTF-8 environment. Functions which deal with filenames are wrappers which convert from UTF-8 and call the corresponding "_w" functions, and so on. The big problem I've run into is that Windows' wchar_t is 16-bit. For filesystem operations, it...

What is MINGWDIR?

Hello. While building Qt and Qt-based software on windows, it seems important to set MINGWDIR environment variable. But i'm not very pleased with doing something like 'voodoo magic', without knowing the reasons. Unfortunately, searching google reveals that it's a lot of tutorials and examples that sets MINGWDIR, but no documentation abo...

Create make with Qt4 and MySQL driver plugin

Installing QT plain is no problem, but when you've got to recompile QT with a MySQL driver plugin? Confusing. And when I do run configure, Qt registers my MySQL driver, but when I attempt to run mingw32-make, this abomination shows up on my command prompt: g++.exe: ....corelibcodecsqisciicodec.cpp: No such file or directory g++.exe: n...

eclipse + cdt + mingw + windows error "undefined reference to `WinMain@16'" on build

I installed eclipse, cdt and mingw on my windows XP machine. added C:\MinGW\bin to my PATH. Created a new c++ project, with one file in it, test.c. the code in it: int main(){ int i=1; } Trying to build, I get the error: /mingw/lib/libmingw32.a(main.o):main.c:(.text+0xd2): undefined reference to 'WinMain@16' Notice it's not compl...

Error compiling java code with MinGW gcj

Hey,firends,This is my first post. I'm just begin to using Gcc to compile java,and I have some trouble in doing this. My input and output: import java.io.*; import java.util.*; public class Program{ public static void main (String args[]) throws Exception { BufferedReader stdin =new BufferedReader(new InputStreamReader...

pip mingw compile

I configured mingw and distutils so now I can compile extensions using this command: setup.py install MinGW gcc complier will be used and package will be installed. For that I installed MinGW and created distutils.cfg file with following content: [build] compiler = mingw32 It's cool but now I'd like to use all pip benefits. So is t...

How can I see qDebug messages while debugging in QtCreator

I'm making the transition from Eclipse CDT (with Qt integration plugin) to QtCreator 2.0 but there is still one thing that bother me with QtCreator : When I debug in QtCreator, I don't see my qDebug messages inside the Application output tab until I stop the application I'm debugging... Then they are all displayed at once which is not v...

Win32 API stack walk with MinGW/MSYS?

Hi all, i've to develop a stack trace walk to our win32 API plattform support to catch any exception with a behaviour of a JAVA stacktrace. Actually we got a full functional implementation for Linux plattforms. First i've tried to implement a stackwalk using the win32 CaptureStackBackTrace API mechanism. But this method is not integrat...

Compiling GCC 4.x.x on MinGW / MSYS Fails

I've been attempting for the last week or so to compile any of the GCC 4 series of compilers to run in MinGW 5.1.6 / MSYS 1.0.11 (automated installers both from Sourceforge.org) which ships with GCC version 3.4.5. The end goal is to get GCC 4.5 to install, but I haven't been able to get any of the 4.x.x compilers to build. I've narrowe...

CDT GDB Debug under Windows

Hi all, I was trying to use CDT with MinGW under Windows 7. It could run the program without any mistakes; however, when I started debugging, it prompted the following messages. I've no idea where the problem was. Any comments are welcome. Thanks in advance. Failed to execute MI command:-gdb-set auto-solib-add on Error message from...

How to use CURL(pp) (wrapper)

How can I use Curlpp (or clean CURL)? Now, I'm trying to do few basic actions (for example use POST) and I can't compile my project (now, I am using Windows, mingw, code::blocks). I have added library, my IDE see this library. I heard about problems with curl+mingw+code::block. Solution is using definition #define STDC_HEADRES 1 in cu...

Imitate/emulate a big-endian behavior in C?

I was wondering if it's possible to emulate a big-endian behavior, for testing purpose? via either windows or linux , mingw or gcc. Here's a sample of code which I would like the emulation to return big endian: #include <stdio.h> #include <stdlib.h> #include <string.h> #include <limits.h> #if CHAR_BIT != 8 #error "Unsupported char si...