Compiling BlitzMax NG

BlitzMax Forums/BlitzMax Programming/Compiling BlitzMax NG

Yue(Posted 2016) [#1]
Hello, I have a concern, why it takes so long a compilation BlitzMax NG ?




[ 48%] Processing:d3d7max2d.bmx
[ 48%] Processing:data.bmx
[ 48%] Processing:font.bmx
[ 48%] Processing:hook.bmx
[ 49%] Processing:keycodes.bmx
[ 49%] Processing:linkedlist.bmx
[ 49%] Processing:intmap.bmx
[ 49%] Processing:objectmap.bmx
[ 49%] Processing:ptrmap.bmx
[ 50%] Processing:stringmap.bmx
[ 50%] Processing:math.bmx
[ 50%] Processing:pixel.bmx
[ 50%] Processing:random.bmx
[ 50%] Processing:driver.bmx
[ 51%] Processing:threads.bmx
[ 51%] Processing:d3d.bmx
[ 51%] Processing:freeaudio.bmx
[ 51%] Processing:glew.bmx
[ 51%] Processing:joystick.bmx
[ 51%] Processing:libjpeg.bmx
[ 52%] Processing:lua.bmx
[ 52%] Processing:macos.bmx
[ 52%] Processing:oggvorbis.bmx
[ 52%] Processing:openal.bmx
[ 52%] Processing:glu.bmx
[ 53%] Processing:opengles.bmx
[ 53%] Processing:stdc.bmx
[ 53%] Processing:com.bmx
[ 53%] Processing:commdlg.bmx
[ 53%] Processing:gdi32.bmx
[ 53%] Processing:kernel32.bmx
[ 54%] Processing:shell32.bmx




Henri(Posted 2016) [#2]
Hi,

could be Windows 10 thing, but could be also realtime antivirus software. Try disabling realtime shield if you have those.

-Henri


Yue(Posted 2016) [#3]
I disabled the antivirus , and much delay compiling a simple " Print ( " Hello " ) , i am using BlitzMax NG version .


GW(Posted 2016) [#4]
I think NG scans every source file in the mods dir before compiling. You have to use the '-quick' or 'quick scan' flag to get behavior similar to regular blitzmax


xlsior(Posted 2016) [#5]
By default, NG will recompile 'everything' called by your program. If you use the MaxIDE NG as well, you can change a setting to assume that all the modules are already compiled properly which will be a lot faster to compile programs.


Brucey(Posted 2016) [#6]
It looks like your MinGW is not set up properly.


Derron(Posted 2016) [#7]
By default, NG will recompile 'everything' called by your program


No, it should do what GW wrote: it checks all used ("import") modules whether they need to get (re-)compiled.
This is the "auto-compile-what-is-needed"-feature of BMK-NG.

With "-quick" you disable the scans and tell BMK to assume "all modules up-to-date. Source-files of your project are _not_ affected by this (they get properly recompiled).

This is an additional feature to the normal "Quick Build"-feature BMK already offered (aka "not recompiling everything of your source files").

bye
Ron


Brucey(Posted 2016) [#8]
Regardless, I think -quick is the least of his worries at the moment...


Yue(Posted 2016) [#9]
@Brucey



Hello, I do not speak English , as I set correctly?

I downloader NG the latest version and put it on the Windows desktop , what else I have to do to set correctly?


Derron(Posted 2016) [#10]
I assume you downloaded either from bmx-ng.com or from the "releases" in github.com/bmx-ng/bmx-ng.

They are not the latest versions. To have the latest version on your computer, you need to

Download
https://github.com/bmx-ng/bcc
and compile as "non-threaded, release" with your original BlitzMax

Download
https://github.com/bmx-ng/bmk
and compile as "threaded, release" with your original BlitzMax


Then override the existing "yourBlitzMaxNG\bin\bcc.exe" with the newly compiled one

Then override the existing "yourBlitzMaxNG\bin\bmk.exe" with the newly compiled one (which is called bmk.mt.exe - so rename it)

Then override the existing "yourBlitzMaxNG\bin\core.bmk" and "...\make.bmk" with the ones in the folder which contained "bmk.mt.exe" (the downloaded one)




Modules:
rename/move "yourBlitzMaxNG\mod\brl.mod" and "...\pub.mod"

Download
https://github.com/bmx-ng/brl.mod
and copy the content to "yourBlitzMaxNG\mod"

Download
https://github.com/bmx-ng/pub.mod
and copy the content to "yourBlitzMaxNG\mod"


This should be enough to be "up to date".


BUT
As Brucey states (and he is very often right with what he writes): make sure your MinGW is installed properly/working properly.

With BlitzMaxNG (or better: the new BMK NG) you are enabled to store your MinGW in "c:\PATH\TO\BlitzMaxNG\MinGW32" (we had this discussed before - in another thread).


bye
Ron


Yue(Posted 2016) [#11]
Ok, Derron, Here Ok?

 Print "Hello"



_Unoffical_0_77 (1)/mod/brl.mod/standardio.mod" -I"C:/Users/John/Desktop/BlitzMaxNG_win32_Unoffical_0_77 (1)/mod/brl.mod/stream.mod" -I"C:/Users/John/Desktop/BlitzMaxNG_win32_Unoffical_0_77 (1)/mod/brl.mod/system.mod" -I"C:/Users/John/Desktop/BlitzMaxNG_win32_Unoffical_0_77 (1)/mod/brl.mod/systemdefault.mod" -I"C:/Users/John/Desktop/BlitzMaxNG_win32_Unoffical_0_77 (1)/mod/brl.mod/textstream.mod" -I"C:/Users/John/Desktop/BlitzMaxNG_win32_Unoffical_0_77 (1)/mod/brl.mod/tgaloader.mod" -I"C:/Users/John/Desktop/BlitzMaxNG_win32_Unoffical_0_77 (1)/mod/brl.mod/threads.mod" -I"C:/Users/John/Desktop/BlitzMaxNG_win32_Unoffical_0_77 (1)/mod/brl.mod/timer.mod" -I"C:/Users/John/Desktop/BlitzMaxNG_win32_Unoffical_0_77 (1)/mod/brl.mod/wavloader.mod" -I"C:/Users/John/Desktop/BlitzMaxNG_win32_Unoffical_0_77 (1)/mod/pub.mod/directx.mod" -I"C:/Users/John/Desktop/BlitzMaxNG_win32_Unoffical_0_77 (1)/mod/pub.mod/enet.mod" -I"C:/Users/John/Desktop/BlitzMaxNG_win32_Unoffical_0_77 (1)/mod/pub.mod/freeaudio.mod" -I"C:/Users/John/Desktop/BlitzMaxNG_win32_Unoffical_0_77 (1)/mod/pub.mod/freejoy.mod" -I"C:/Users/John/Desktop/BlitzMaxNG_win32_Unoffical_0_77 (1)/mod/pub.mod/freeprocess.mod" -I"C:/Users/John/Desktop/BlitzMaxNG_win32_Unoffical_0_77 (1)/mod/pub.mod/freetype.mod" -I"C:/Users/John/Desktop/BlitzMaxNG_win32_Unoffical_0_77 (1)/mod/pub.mod/glew.mod" -I"C:/Users/John/Desktop/BlitzMaxNG_win32_Unoffical_0_77 (1)/mod/pub.mod/joystick.mod" -I"C:/Users/John/Desktop/BlitzMaxNG_win32_Unoffical_0_77 (1)/mod/pub.mod/libjpeg.mod" -I"C:/Users/John/Desktop/BlitzMaxNG_win32_Unoffical_0_77 (1)/mod/pub.mod/libpng.mod" -I"C:/Users/John/Desktop/BlitzMaxNG_win32_Unoffical_0_77 (1)/mod/pub.mod/lua.mod" -I"C:/Users/John/Desktop/BlitzMaxNG_win32_Unoffical_0_77 (1)/mod/pub.mod/macos.mod" -I"C:/Users/John/Desktop/BlitzMaxNG_win32_Unoffical_0_77 (1)/mod/pub.mod/oggvorbis.mod" -I"C:/Users/John/Desktop/BlitzMaxNG_win32_Unoffical_0_77 (1)/mod/pub.mod/openal.mod" -I"C:/Users/John/Desktop/BlitzMaxNG_win32_Unoffical_0_77 (1)/mod/pub.mod/opengl.mod" -I"C:/Users/John/Desktop/BlitzMaxNG_win32_Unoffical_0_77 (1)/mod/pub.mod/opengles.mod" -I"C:/Users/John/Desktop/BlitzMaxNG_win32_Unoffical_0_77 (1)/mod/pub.mod/stdc.mod" -I"C:/Users/John/Desktop/BlitzMaxNG_win32_Unoffical_0_77 (1)/mod/pub.mod/win32.mod" -I"C:/Users/John/Desktop/BlitzMaxNG_win32_Unoffical_0_77 (1)/mod/pub.mod/zlib.mod"  -DNDEBUG  -w -DBMX_NG -m32 -ffast-math -fno-exceptions -c -O2 -s  -o "C:/Users/John/Documents/.bmx/NG.bmx.console.release.mt.win32.x86.o" "C:/Users/John/Documents/.bmx/NG.bmx.console.release.mt.win32.x86.c"
[100%] Linking:NG.mt.exe
"C:/Users/John/Desktop/BlitzMaxNG_win32_Unoffical_0_77 (1)/MinGW32/bin/ld.exe" -stack 4194304 -s  -o "C:/Users/John/Documents/NG.mt.exe"  -L"C:/Users/John/Desktop/BlitzMaxNG_win32_Unoffical_0_77 (1)/MinGW32/lib/gcc/x86_64-w64-mingw32/5.1.0/32" -L"C:/Users/John/Desktop/BlitzMaxNG_win32_Unoffical_0_77 (1)/MinGW32/x86_64-w64-mingw32/lib32" -mi386pe "C:/Users/John/Desktop/BlitzMaxNG_win32_Unoffical_0_77 (1)/tmp/ld.tmp"
LoadBMK : C:/Users/John/Documents/post.bmk
Executing:NG.mt.exe
"C:/Users/John/Documents/NG.mt.exe"
Hello

Process complete



It takes much less time.


Derron(Posted 2016) [#12]
You might disable the "verbose" option in MaxIDE ... "verbose" means "talking about everything" (which is why you get these long lines full of commands".


@ Long compilation times
I have these too - if I do not use "-quick". Not very long, but long enough to be annoying ;-)

Brucey already improved times a lot in the latest releases (especially with huge main-source-files which "include" many things rather than importing)

bye
Ron


Yue(Posted 2016) [#13]
Ok Derron: :)


Type TN



 Function num()

         Print "null"
 End Function 


 Function num(n:Int)
         Print n
 End Function 

End Type 


TN.num()



Building Inicio
[ 99%] Processing:Inicio.bmx
[ 99%] Compiling:Inicio.bmx.console.release.mt.win32.x86.c
[100%] Linking:Inicio.mt.exe
Executing:Inicio.mt.exe
null

Process complete



It is possible to adapt the module to work with Xors3D BlitzMax NG?

When I return I try to compile errors.


Derron(Posted 2016) [#14]
I do not know about Xors3D so I do not know what has to get adapted and what not.

@ print "null".
What do you want to show with this? Overloading methods/functions seems to work.


bye
Ron


Yue(Posted 2016) [#15]
Yes, I was testing the overhead of methods in version 1.50 it is not supported , but in versió BlitzMax NG if it works.


And all apparently working properly, and is one of the reasons that I would like the module Xors3D fucionara with BlitzMax NG .