Skip to content

Commit

Permalink
Fixed MinGW path related issues.
Browse files Browse the repository at this point in the history
  • Loading branch information
woollybah committed May 8, 2019
1 parent 4f9e09c commit 91b59db
Showing 1 changed file with 8 additions and 18 deletions.
26 changes: 8 additions & 18 deletions maxide.bmx
Original file line number Diff line number Diff line change
Expand Up @@ -590,10 +590,9 @@ Type TAboutRequester Extends TRequester
?Win32
strHeadings:+["{{about_label_mingwpath}}:"]
' check For Local mingw32 dir First
If FileType(BlitzMaxPath() + "/MinGW32") = FILETYPE_DIR Then
strValues:+[(BlitzMaxPath() + "/MinGW32").Replace("/","\")]
Else If getenv_("MINGW") Then
strValues:+[getenv_("MINGW")]
Local path:String = MinGWPath()
If path Then
strValues:+[path.Replace("/", "\")]
Else
strValues:+[LocalizeString("{{about_error_unavailable}}")]
EndIf
Expand Down Expand Up @@ -663,11 +662,8 @@ Type TAboutRequester Extends TRequester

Method GetGCC$()
?Win32
Local gccPath:String = BlitzMaxPath() + "/MinGW32"
If Not FileType(gccPath) Then
gccPath = getenv_("MinGW")
If Not gccPath Then Return LocalizeString("{{about_error_notapplicable}}")
End If
Local gccPath:String = MinGWPath()
If Not gccPath Then Return LocalizeString("{{about_error_notapplicable}}")
gccPath :+ "/bin/gcc"
gccPath = gccPath.Replace("/", "\")
? Not win32
Expand All @@ -678,11 +674,8 @@ Type TAboutRequester Extends TRequester

Method GetGpp$()
?Win32
Local gppPath:String = BlitzMaxPath() + "/MinGW32"
If Not FileType(gppPath) Then
gppPath = getenv_("MinGW")
If Not gppPath Then Return LocalizeString("{{about_error_notapplicable}}")
End If
Local gppPath:String = MinGWPath()
If Not gppPath Then Return LocalizeString("{{about_error_notapplicable}}")
gppPath:+ "/bin/g++"
gppPath = gppPath.Replace("/", "\")
? Not win32
Expand Down Expand Up @@ -7098,10 +7091,7 @@ Type TCodePlay
'UpdateArchitectureMenus()

?Win32
Local mingw$=BlitzMaxPath() + "/MinGW32"
If Not FileType(mingw) Then
mingw = getenv_("MINGW")
End If
Local mingw:String = MinGWPath()
If Not mingw
DisableMenu buildmods
DisableMenu buildallmods
Expand Down

2 comments on commit 91b59db

@GWRon
Copy link

@GWRon GWRon commented on 91b59db May 8, 2019

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Maybe BMK could use that new util-function too (clean code base).

@woollybah
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Not really. It's a bit different.

Please sign in to comment.