Allegro.cc - Online Community

Allegro.cc Forums » Installation, Setup & Configuration » Aother Problems building Allegro with MinGW

This thread is locked; no one can reply to it. rss feed Print
 1   2 
Aother Problems building Allegro with MinGW
Simondererste
Member #10,071
August 2008

I think this is a newb failure but i don't know how i could build allegro.
This Error comes if i run make:

C:\Programme\MeineProgramme\allegro>make
process_begin: CreateProcess(NULL, gcc -dumpversion, ...) failed.
process_begin: CreateProcess(NULL, gcc -dumpversion, ...) failed.
Der Befehl "C:\DOKUME~1\SIMON" ist entweder falsch geschrieben oder
konnte nicht gefunden werden.
make: *** [badming] Error 1

Hope you can help me.

Trent Gamblin
Member #261
April 2000
avatar

Use mingw32-make not make.

Simondererste
Member #10,071
August 2008

Don't work and by the way make works(only a copy of mingw23-make so it should) but i have tried both. Hope i get help soon.

Edgar Reynaldo
Major Reynaldo
May 2007
avatar

Trent Gamblin
Member #261
April 2000
avatar

make isn't a copy of mingw32-make unless you copied it, which you shouldn't. Regular 'make' doesn't work under DOS command prompt, only in MSYS or Cygwin or another bash shell. mingw32-make is for the DOS prompt, and it doesn't work under bash.

Evert
Member #794
November 2000
avatar

Quote:

make isn't a copy of mingw32-make unless you copied it, which you shouldn't. Regular 'make' doesn't work under DOS command prompt, only in MSYS or Cygwin or another bash shell.

Huh?

Quote:

C:\Programme\MeineProgramme\allegro>make
process_begin: CreateProcess(NULL, gcc -dumpversion, ...) failed.
process_begin: CreateProcess(NULL, gcc -dumpversion, ...) failed.
Der Befehl "C:\DOKUME~1\SIMON" ist entweder falsch geschrieben oder
konnte nicht gefunden werden.
make: *** [badming] Error 1

This used to be caused by having an incompatible version of sh.exe somewhere in the path. So check if you have an sh.exe somewhere in the path and try moving it out of the way and try again. I don't know if this still causes problems, but it's easily checked.
Also, try running gcc -v to verify that gcc can indeed be found and run properly. If not, check your path (as Edgar Reynaldo pointed out).

Simondererste
Member #10,071
August 2008

@Trent Gamblin: I copied it but i used the mingw23-make too. But thanks for explanation.
@Edgar Reynaldo: Yes i have.
@Evert: I ran gcc -v and it worked so like i said i have the <mingw>/bin directory in the path. So i have to look if there is a sh.exe in it. Hope it will work.

Thanks for helping me.

-> deleted the whole Path and included only <mingw>/bin. Now this failure:process_begin: CreateProcess(NULL, gcc -dumpversion, ...) failed. is gone but i have still this problem: Der Befehl "C:\DOKUME~1\SIMON" ist entweder falsch geschrieben oder
konnte nicht gefunden werden.
mingw32-make: *** [badming] Error 1

In English: The command "C:\DOKUME~1\SIMON" is either wrong spelled or couldn't be found.
(by the way I hope my English is not too bad:-/)

Edgar Reynaldo
Major Reynaldo
May 2007
avatar

Quote:

-> deleted the whole Path and included only <mingw>/bin.

Hopefully you only did that through a command console so the changes aren't permanent. Deleting your path means many files won't be found by your system when needed.

You only want to add <mingw>/bin to your path, not replace everything with it. The directories are listed in search order - first in the list is the first directory searched.

set PATH=c:\mingw\bin;%PATH%

The semi-colon separates each directory from the next.

As to your remaining error, I don't know. It's strange that running make would look for anything in the Documents and Settings folder unless you are trying to compile Allegro from there.

Simondererste
Member #10,071
August 2008

I have made a copy. It's basic to make backup if you work with a computer.
And i don't want to add <mingw>/bin because i have done it already but i want to eliminate the thing with the sh.exe. I want to install allegro because i have a book about programming computer games. In the book is an instruction that i have followed but there is still this one failure.

Edgar Reynaldo
Major Reynaldo
May 2007
avatar

Quote:

In the book is an instruction that i have followed but there is still this one failure.

Why don't you do yourself a favor and read the instructions to compile Allegro that come with the source code instead. It's the file allegro\docs\build\mingw32.txt that is in the source code zip file.

Unzip alleg42.zip to your <mingw> directory and unzip dx70_mgw.zip there as well. Then set the path properly by adding the <mingw>/bin directory to your path, not by replacing your path string with <mingw>/bin only. You also need to set the MINGDIR variable to your MinGW directory.

set MINGDIR=c:\mingw

Quote:

And i don't want to add <mingw>/bin because i have done it already but i want to eliminate the thing with the sh.exe.

sh.exe doesn't even come with MinGW, at least not version 3.4.5 anyway. Isn't that just for Unix variants?

Simondererste
Member #10,071
August 2008

I have done most of that. I used dx80 and don't set MINGDIR.

Jonatan Hedborg
Member #4,886
July 2004
avatar

Soo... how about doing what it says instead?

Simondererste
Member #10,071
August 2008

K i will try it again from the beginning hope i won't make a failure.
Could I have done something wrong with MinGW?

Edgar Reynaldo
Major Reynaldo
May 2007
avatar

Quote:

I used dx80 and don't set MINGDIR.

dx80_mgw may work but I can't verify that it will. Regardless, the instructions for MinGW specify the use of dx70_mgw.zip instead.

Not setting the MINGDIR will result in failure of the makefile as it is used for determining the locations of files during compilation.

Using grep to ascertain references to MINGDIR in the makefile.mgw yields :

1 
2c:\mingw\allegro>grep -r -F -I -n MINGDIR makefile.mgw
3103:ifdef MINGDIR
4104: MINGDIR_U = $(subst \,/,$(MINGDIR))
5105: MINGDIR_D = $(subst /,\,$(MINGDIR))
6108: @echo Your MINGDIR environment variable is not set!
7115:ifneq ($(findstring $(SPACE),$(MINGDIR)),)
8117: @echo There are spaces in your MINGDIR environment variable:
9243:INSTALLDIR = $(MINGDIR_U)
10250:$(MINGDIR_U)/lib/$(IMPLIB_BASENAME): $(IMPLIB_NAME) $(MINGDIR_U)/lib
11251: cp lib/mingw32/$(IMPLIB_BASENAME) $(MINGDIR_U)/lib
12258:$(MINGDIR_U)/lib/$(IMPLIB_BASENAME): $(IMPLIB_NAME) $(MINGDIR_U)/lib
13259: copy lib\mingw32\$(IMPLIB_BASENAME) $(MINGDIR_D)\lib
14267:HEADERS = $(MINGDIR_U)/include/winalleg.h \
15268: $(MINGDIR_U)/include/allegro/platform/aintwin.h \
16269: $(MINGDIR_U)/include/allegro/platform/al386gcc.h \
17270: $(MINGDIR_U)/include/allegro/platform/almngw32.h \
18271: $(MINGDIR_U)/include/allegro/platform/alplatf.h \
19272: $(MINGDIR_U)/include/allegro/platform/astdint.h \
20273: $(MINGDIR_U)/include/allegro/platform/alwin.h
21275:INSTALL_FILES = $(MINGDIR_U)/lib/$(IMPLIB_BASENAME)
22288:UNINSTALL_FILES = $(MINGDIR_U)/lib/liballeg.a \
23289: $(MINGDIR_U)/lib/liballd.a \
24290: $(MINGDIR_U)/lib/liballp.a \
25291: $(MINGDIR_U)/lib/liballeg_s.a \
26292: $(MINGDIR_U)/lib/liballd_s.a \
27293: $(MINGDIR_U)/lib/liballp_s.a \
28 
29c:\mingw\allegro>

However, you haven't gotten the error regarding line 108 of makefile.mgw :

    @echo Your MINGDIR environment variable is not set!

This leads me to believe that you haven't run this command before using mingw32-make :

fix.bat mingw32

Simondererste
Member #10,071
August 2008

I ran fix.bat mingw32.
Now i have set MINGDIR and made a new allegro folder but it still don't work.

If run fix.bat 32mingw again that comes up. Do i have to do something with it?

C:\Programme\MeineProgramme\allegro>fix.bat 32mingw

Usage: fix platform [--crlf] [--nomsvcpaths]

Where platform is one of:
bcc32, djgpp, mingw, dmc, msvc6, msvc7, msvc8, icl, or watcom.

The --crlf parameter is used to turn on LF to CR/LF conversion.
The --nomsvcpaths parameter is used to turn off special MS Visual C++
path handling.

Edgar Reynaldo
Major Reynaldo
May 2007
avatar

Lines 90-95 of makefile.all contain the only reference to gcc --dumpversion out of all the makefiles involved in building allegro on MinGW that I can find and it only calls that process if the suffix of MAKEFILE_INC is not one of (.be .dj .mgw .osx .qnx). Fix.bat mingw32 mingw would have set MAKEFILE_INC to makefile.mgw so I don't believe you should be getting that same error message anymore.


# -------- include platform-specific definitions --------

ifneq (,$(findstring $(suffix $(MAKEFILE_INC)),.be .dj .mgw .osx .qnx))
   ifndef GCC_MTUNE
      gcc_version = $(subst ., ,$(shell gcc -dumpversion))

Post a transcript of your console session including the result of the following commands and all the output that mingw32-make returned.

set PATH
echo %MINGDIR%
type makefile

Don't worry about the 'set PATH' command as it will only change the setting if you use an equals sign after the variable name. Without an equals sign it simply outputs its value.

Edit
Sorry, I misspoke. It should be "fix.bat mingw" not what I said before. I apologize for giving you inaccurate information.

Simondererste
Member #10,071
August 2008

C:\Programme\MeineProgramme\allegro>echo %MINGDIR%
C:\Programme\MeineProgramme\MinGW

C:\Programme\MeineProgramme\allegro>type makefile

  1. generated by fix.bat

MAKEFILE_INC = makefile.mgw
include makefile.all

C:\Programme\MeineProgramme\allegro>mingw32-make
Der Befehl "C:\DOKUME~1\SIMON" ist entweder falsch
konnte nicht gefunden werden.
mingw32-make: *** [msg] Error 1

C:\Programme\MeineProgramme\allegro>

Edgar Reynaldo
Major Reynaldo
May 2007
avatar

Quote:

C:\Programme\MeineProgramme\MinGW

C:\Programme\MeineProgramme\allegro>type makefile

The problem is that the allegro directory should be a sub directory of c:\Programme\MeineProgramme\MinGW. So move the allegro directory into \MinGW.

C:\Programme\MeineProgramme\MinGW\allegro\mingw32-make

Simondererste
Member #10,071
August 2008

C:\Programme\MeineProgramme\MinGW\allegro>fix.bat mingw
Configuring Allegro for Windows/MinGW...
Done!
C:\Programme\MeineProgramme\MinGW\allegro>mingw32-make
Der Befehl "C:\DOKUME~1\SIMON" ist entweder falsch geschrieben oder
konnte nicht gefunden werden.
mingw32-make: *** [msg] Error 1

Same error.

Edgar Reynaldo
Major Reynaldo
May 2007
avatar

Quote:

Der Befehl "C:\DOKUME~1\SIMON" ist entweder falsch geschrieben oder
konnte nicht gefunden werden.

I just don't understand why it would need to look for anything in your Documents and Settings folder.

Please post the results of the 'set' command by itself from a console window.

set

Simondererste
Member #10,071
August 2008

It's a temp folder but not a normal folder can't find a direction C:\DOKUME~1\SIMON. It could be that it is hidden. The dir is found in the Temp/Tmp variable.
And i know my path variable is strange some dir are more then once in it. Don't know why but i will correct this.

C:\Dokumente und Einstellungen\Simon(noadmin)>set
ALLUSERSPROFILE=C:\Dokumente und Einstellungen\All Users
APPDATA=C:\Dokumente und Einstellungen\Simon(noadmin)\Anwendungsdaten
CLASSPATH=.;C:\Programme\Java\jre1.6.0_02\lib\ext\QTJava.zip
CLIENTNAME=Console
CommonProgramFiles=C:\Programme\Gemeinsame Dateien
COMPUTERNAME=SIMON
ComSpec=C:\WINDOWS\system32\cmd.exe
FP_NO_HOST_CHECK=NO
HOMEDRIVE=C:
HOMEPATH=\Dokumente und Einstellungen\Simon(noadmin)
LOGONSERVER=\\SIMON
MINGDIR=C:\Programme\MeineProgramme\MinGW
NUMBER_OF_PROCESSORS=2
OS=Windows_NT
Path=C:\WINDOWS\system32;C:\WINDOWS;C:\WINDOWS\System32\Wbem;C:\Programme\MeineP
rogramme\Video&Bild\QuickTime\QTSystem\;C:\Programme\MeineProgramme\Video&Bild\I
mageConverter Plus;C:\Programme\Java\jdk1.6.0_07\bin;C:\Programme\MeineProgramme
\Spiele\I_Games\pserver\Ragnarok\tools\Mapping\MapProjekt\P1;C:\Programme\MeineP
rogramme\TortoiseSVN\bin;C:\Programme\MeineProgramme\MinGW\mingw32\bin;C:\Progra
mme\MeineProgramme\Video&Bild\QuickTime\QTSystem\;C:\Programme\MeineProgramme\Vi
deo&Bild\ImageConverter Plus;C:\Programme\Java\jdk1.6.0_07\bin;C:\Programme\Mein
eProgramme\Spiele\I_Games\pserver\Ragnarok\tools\Mapping\MapProjekt\P1;C:\Progra
mme\MeineProgramme\TortoiseSVN\bin;C:\Programme\MeineProgramme\MinGW\mingw32\bin
;C:\Programme\MeineProgramme\Video&Bild\QuickTime\QTSystem\;C:\Programme\MeinePr
ogramme\Video&Bild\ImageConverter Plus;C:\Programme\Java\jdk1.6.0_07\bin;C:\Prog
ramme\MeineProgramme\Spiele\I_Games\pserver\Ragnarok\tools\Mapping\MapProjekt\P1
;C:\Programme\MeineProgramme\TortoiseSVN\bin;C:\Programme\MeineProgramme\Video&B
ild\QuickTime\QTSystem\;C:\Programme\MeineProgramme\Video&Bild\ImageConverter Pl
us;C:\Programme\Java\jdk1.6.0_07\bin;C:\Programme\MeineProgramme\Spiele\I_Games\
pserver\Ragnarok\tools\Mapping\MapProjekt\P1;C:\Programme\MeineProgramme\Tortois
eSVN\bin;C:\Programme\MeineProgramme\MinGW\mingw32\bin;C:\Programme\MeineProgram
me\Video&Bild\QuickTime\QTSystem\;C:\Programme\MeineProgramme\Video&Bild\ImageCo
nverter Plus;C:\Programme\Java\jdk1.6.0_07\bin;C:\Programme\MeineProgramme\Spiel
e\I_Games\pserver\Ragnarok\tools\Mapping\MapProjekt\P1;C:\Programme\MeineProgram
me\TortoiseSVN\bin;C:\Programme\MeineProgramme\MinGW\bin;;C:\PROGRA~1\GEMEIN~1\M
UVEET~1\030625
PATHEXT=.COM;.EXE;.BAT;.CMD;.VBS;.VBE;.JS;.JSE;.WSF;.WSH
PROCESSOR_ARCHITECTURE=x86
PROCESSOR_IDENTIFIER=x86 Family 6 Model 15 Stepping 6, GenuineIntel
PROCESSOR_LEVEL=6
PROCESSOR_REVISION=0f06
ProgramFiles=C:\Programme
PROMPT=$P$G
QTJAVA=C:\Programme\Java\jre1.6.0_02\lib\ext\QTJava.zip
SESSIONNAME=Console
SystemDrive=C:
SystemRoot=C:\WINDOWS
TEMP=C:\DOKUME~1\SIMON(~1\LOKALE~1\Temp
TMP=C:\DOKUME~1\SIMON(~1\LOKALE~1\Temp
USERDOMAIN=SIMON
USERNAME=Simon(noadmin)
USERPROFILE=C:\Dokumente und Einstellungen\Simon(noadmin)
windir=C:\WINDOWS

Edgar Reynaldo
Major Reynaldo
May 2007
avatar

The quickest way to fix it is to exit your command shell and open a new one. That way, any temporary changes you've made to your PATH will be removed and you can verify this by using the set command again. If the entries are still there then you may need to take a look at your global system environment variables.

The way I create my compiler setup is through a batch program run upon the start of the command console through a customized shortcut to cmd.exe -
http://www.allegro.cc/files/attachment/596135

The full text of the shortcut target is :

%SystemRoot%\system32\cmd.exe /k "c:\mingw\setupMinGW.bat"

And this is what that batch file contains :

@echo on

@rem This command starts pathMinGW.bat which sets MINGDIR=C:\mingw and
@rem sets PATH=c:\mingw\bin;%PATH% to use the MinGW compiler
call c:\mingw\PathMinGW.bat

@rem The second command runs my macros from the file MinGWmacros.bat

call c:\mingw\MinGWmacros.bat
cd /d c:\ctwoplus\progcode\allegro

@rem call c:\scriptlearning\pathscript.bat 
cls

@echo off

So now whenever I need my compiling environment for MinGW setup, I just use the shortcut. The batch file specified with /k calls the other setup batch programs. One fixes the environment to use with MinGW and the other installs my macro shortcuts using doskey. Presto chango, ready to go.

So in this fashion, you can customize and automate your environment setup and allow for more than one setup by using multiple shortcuts or calling setup batch scripts from a plain command console.

Quote:

It's a temp folder but not a normal folder can't find a direction C:\DOKUME~1\SIMON. It could be that it is hidden. The dir is found in the Temp/Tmp variable.

Verify the directory exists, if it does then it may be a permissions problem with mingw32-make being denied access to create files there. Run the command console as an administrator and see if it changes anything. You'll have to run it as an administrator for 'mingw32-make install' to work properly as it needs to copy the dll files to your system32 folder.

Simondererste
Member #10,071
August 2008

I am admin on my pc the name is only a misunderstood from me as i installed it. Don't realy understood what you mean and what that should help me but i will have a look on it tomorrow it is a bit late.

Edgar Reynaldo
Major Reynaldo
May 2007
avatar

Which version of Windows are you using? If you're on Vista and you have UAC (User Account Control) enabled, then even if you're logged in as an administrator, the command console will not be run as a process with administrative priveleges. You would have to right click on the shortcut to it and select 'Run As Administrator'.

Quote:

Don't realy understood what you mean and what that should help me but i will have a look on it tomorrow it is a bit late.

These were the important parts -

Quote:

The quickest way to fix it (the abnormal PATH) is to exit your command shell and open a new one. That way, any temporary changes you've made to your PATH will be removed and you can verify this by using the set command again. If the extra entries are still there then you may need to take a look at your global system environment variables.

Verify the directory exists, if it does then it may be a permissions problem with mingw32-make being denied access to create files there. Run the command console as an administrator and see if it changes anything. You'll have to run it as an administrator for 'mingw32-make install' to work properly as it needs to copy the dll files to your system32 folder.

The rest of what I said was just to make setting up your MinGW environment more convenient for you, but that can be dealt with later.

Until tomorrow then. ;)

Trent Gamblin
Member #261
April 2000
avatar

Evert said:

Huh?

Just what I said. mingw32-make and the make you get with, for example, unxutils or cygwin are not compatible.

 1   2 


Go to: