Note that there are some explanatory texts on larger screens.

plurals
  1. POMingw32 cross compiled console application doesn't do anything on Windows XP
    primarykey
    data
    text
    <p>I've compiled a small app in Linux (Ubuntu 11.04) with Mingw32 and it runs ok in Wine, but does nothing on Wuindows (although it runs).</p> <p>Configure:</p> <blockquote> <p>./configure --host=i586-mingw32msvc --target=i586-mingw32msvc --build=i686-linux</p> </blockquote> <p>(I've tried without <code>--target</code> and without <code>--build</code> with the same results.)</p> <p>Compile:</p> <blockquote> <p>i586-mingw32msvc-g++ -DHAVE_CONFIG_H -I. -I.. -DLOG_DOMAIN=\"tpv\" -I.. -DWINVER=0x0400 -D_<em>WINDOWS</em>_ -Wall -g -Wl,--subsystem,console -mconsole -mms-bitfields -g -O2 -MT tpv-excepciones.o -MD -MP -MF .deps/tpv-excepciones.Tpo -c -o tpv-excepciones.o</p> </blockquote> <p>Link:</p> <blockquote> <p>/bin/bash ../libtool --tag=CXX --mode=link i586-mingw32msvc-g++ -Wall -g -Wl,--subsystem,console -mconsole -mms-bitfields -g -O2 -lstdc++ -lgcc -lodbc32 -lwsock32 -lwinspool -lwinmm -lshell32 -lcomctl32 -lctl3d32 -lodbc32 -ladvapi32 -lodbc32 -lwsock32 -lopengl32 -lglu32 -lole32 -loleaut32 -luuid -lmingw32 -Wl,-subsystem,console -o tpv.exe tpv-excepciones.o tpv-conf.o tpv-main.o</p> </blockquote> <p>It generates an .exe file which is not a linux binary. It runs OK in wine, but does nothing in Windows XP.</p> <p>Reading the web I've added some flags in configure time: </p> <blockquote> <p>-Wl,--subsystem,console -mconsole -mms-bitfields</p> </blockquote> <p>This is the program:</p> <pre><code>#include &lt;windows.h&gt; #include "main.hh" int main (int argc, char ** argv) { MessageBox (0, "Joder!", "Ermmm...", MB_OK); //utils::conf c ("configuracion.3D"); //std::cout &lt;&lt; "Valor de 'no': '" &lt;&lt; c["TEXTO_ERROR"] &lt;&lt; "'" &lt;&lt; std::endl; //std::cout &lt;&lt; "..." &lt;&lt; std::endl; return 0; } </code></pre> <p>I've tried everything I've found on the web to no avail.</p> <p>Am I missing something?</p>
    singulars
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    plurals
    1. This table or related slice is empty.
    1. This table or related slice is empty.
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload