@echo off path=C:\Dev\SDK\mingw\bin;C:\Dev\SDK\mingw\msys\1.0\bin if not exist %~n0.exe ( gcc.exe -static -O2 -s -o %~n0.exe %~n0.c strip.exe -s %~n0.exe ) if exist %~n0.exe ( file %~n0.exe ldd %~n0.exe %~n0.exe ) pause