PB compilation problems with MSE

Everything else that doesn't fall into one of the other PB categories.
SFSxOI
Addict
Addict
Posts: 2970
Joined: Sat Dec 31, 2005 5:24 pm
Location: Where ya would never look.....

Re: PB compilation problems with MSE

Post by SFSxOI »

Tenaja wrote:
Danilo wrote:'Excluded files and locations' did not fix it here, i had to add all of PureBasic's .EXE to the 'Excluded Processes':

Run with PB 32bit and 64bit and [Copy] the debug output to MSE Settings -> 'Excluded Processes' (CTRL+V to Paste it) and press [Add] there in MSE.

Code: Select all

pbDir$ = #PB_Compiler_Home

Debug pbDir$+"PureBasic.exe;"
Debug pbDir$+"Visual Designer.exe;"
Debug pbDir$+"Compilers\"+"pbcompiler.exe;"
Debug pbDir$+"Compilers\"+"PBDebugger.exe;"
Debug pbDir$+"Compilers\"+"PBDebuggerUnicode.exe;"
Debug pbDir$+"Compilers\"+"FAsm.exe;"
Debug pbDir$+"Compilers\"+"porc.exe;"
Debug pbDir$+"Compilers\"+"polib.exe;"
Debug pbDir$+"Compilers\"+"polink.exe;"
Compilation time is very fast again. :)

Executable startup still takes half a second. To speed it up, exclude the following files too, if you want:

Code: Select all

tmp$ = GetEnvironmentVariable("TEMP")

For i = 0 To 9
    Debug tmp$+"\PureBasic_Compilation"+Str(i)+".exe;"
Next
Seems to be important to MSE that Paths and File names are case sensitive, so
it has to be "Compilers\", not "compilers\".
I had already manually entered almost all of these, with no luck, so I tried pasting in the output. Unfortunately, it did not help either. I am running w7-32 with msse. I guess it is time to find a new av. Between my laptop being a couple years old, and my code being long, the av now adds over 20 seconds to the startup time, and that severely slows down debugging. (I can create a LOT of bugs in 20 seconds! :mrgreen: )

How odd, since it works fine here on 23 different Windows 7 x86 machines when i tested it out. You are putting them in the 'Excluded Processes' and not the file and folder exclusions right?

Do you have full permissions to the purebasic install folder?
The advantage of a 64 bit operating system over a 32 bit operating system comes down to only being twice the headache.
User avatar
Tenaja
Addict
Addict
Posts: 1959
Joined: Tue Nov 09, 2010 10:15 pm

Re: PB compilation problems with MSE

Post by Tenaja »

SFSxOI wrote:You are putting them in the 'Excluded Processes' and not the file and folder exclusions right?
DOH!

Of course I am! And it suddenly started working, too! How convenient.
:oops:
USCode
Addict
Addict
Posts: 923
Joined: Wed Mar 24, 2004 11:04 pm
Location: Seattle

Re: PB compilation problems with MSE

Post by USCode »

Does this problem occur with other development environments???

MSE isn't identifying PB or it's generated executables as a virus/malware but maybe Fred should submit this form anyways?
http://www.microsoft.com/security/porta ... itive.aspx
User avatar
Danilo
Addict
Addict
Posts: 3036
Joined: Sat Apr 26, 2003 8:26 am
Location: Planet Earth

Re: PB compilation problems with MSE

Post by Danilo »

Tenaja wrote:And it suddenly started working, too! How convenient.
:oops:
After IDE restart?
SFSxOI
Addict
Addict
Posts: 2970
Joined: Sat Dec 31, 2005 5:24 pm
Location: Where ya would never look.....

Re: PB compilation problems with MSE

Post by SFSxOI »

Tenaja wrote:
SFSxOI wrote:You are putting them in the 'Excluded Processes' and not the file and folder exclusions right?
DOH!

Of course I am! And it suddenly started working, too! How convenient.
:oops:
Glad it worked out for you :)
The advantage of a 64 bit operating system over a 32 bit operating system comes down to only being twice the headache.
SFSxOI
Addict
Addict
Posts: 2970
Joined: Sat Dec 31, 2005 5:24 pm
Location: Where ya would never look.....

Re: PB compilation problems with MSE

Post by SFSxOI »

USCode wrote:Does this problem occur with other development environments???

MSE isn't identifying PB or it's generated executables as a virus/malware but maybe Fred should submit this form anyways?
http://www.microsoft.com/security/porta ... itive.aspx
Its not a false positive or anything else. Its normal activity from a correctly implemented real time protection, so MSE is working as intended and PureBasic is working as intended - MSE just needs the addition of the exclusions in MSE which is why there is a place to put the exclusions - to exclude those things from the real time protection scan. There is nothing to submit, and even if it was submitted MS is just going to come back and say that its working as intended and to add the exclusions so Fred would be wasting his time trying to submit for something thats working as intended, we went over this in the beta for other things as well so its just not PB.
Last edited by SFSxOI on Wed May 02, 2012 7:29 pm, edited 1 time in total.
The advantage of a 64 bit operating system over a 32 bit operating system comes down to only being twice the headache.
User avatar
Danilo
Addict
Addict
Posts: 3036
Joined: Sat Apr 26, 2003 8:26 am
Location: Planet Earth

Re: PB compilation problems with MSE

Post by Danilo »

Just noticed the following:
I removed all PureBasic_CompilationXXX.exe from the exclude list, so i exclude just the .exe from PureBasic.

Everything compiles very fast, but everything that requires TEMP is starting slow (starting unsaved sources
and all other saved sources without the compiler option "Create temporary executable in the source directory")

All sources with enabled "Create temporary executable in the source directory" start instantly.
Maybe MSE scans the whole TEMP folder every time or runs more checks for TEMP.

I enabled "Create temporary executable in the source directory" as default compiler option now,
so all new created files startup fast after saving the source.

Excluding the whole TEMP folder is too risky in my opinion.
SFSxOI
Addict
Addict
Posts: 2970
Joined: Sat Dec 31, 2005 5:24 pm
Location: Where ya would never look.....

Re: PB compilation problems with MSE

Post by SFSxOI »

You are correct, it is very risky to exclude the whole temp folder, never do that.

Yes, unless the compilation .exe in the temp folder is excluded then its going to start slow because the temp folder is a major use vector for viruses/trojans/malware so its by default included as a whole in the real time protection scan and monitored, and the temp compilation .exe, unless excluded, the real time protection sees it as "suspect activity" until proven otherwise because of the uniqueness of the temp folder in the user path as a system folder and that is exactly what real time protection for a monitored location is supposed to do. So because it sees it as "suspect activity" (because things are not expected to "initiate" in the temp folder suddenly that never existed before in that location like the compilation .exe does) it has to scan the whole compilation as its compiled and run and thus the time it takes. (OK, "suspect activity" is a little strongly worded, we know its not real suspect activity for the compilation)

In a weird way, the compilation .exe does mimic some malware activity in that each run its a new compilation .exe and that new compilation never existed before as it was at the moment of compilation even if the same file name is being used. Some malware does this also, suddenly create or change something in the temp and then execute it from there.

I think I said this right.
Last edited by SFSxOI on Wed May 02, 2012 9:34 pm, edited 5 times in total.
The advantage of a 64 bit operating system over a 32 bit operating system comes down to only being twice the headache.
User avatar
Tenaja
Addict
Addict
Posts: 1959
Joined: Tue Nov 09, 2010 10:15 pm

Re: PB compilation problems with MSE

Post by Tenaja »

Danilo wrote:
Tenaja wrote:And it suddenly started working, too! How convenient.
:oops:
After IDE restart?
No, after I moved it from "files and locations" to processes... I had tried this before reading about it, and thought I had it in the right place but typos or something. I just missed the part about processes.
SFSxOI
Addict
Addict
Posts: 2970
Joined: Sat Dec 31, 2005 5:24 pm
Location: Where ya would never look.....

Re: PB compilation problems with MSE

Post by SFSxOI »

Tenaja wrote:
Danilo wrote:
Tenaja wrote:And it suddenly started working, too! How convenient.
:oops:
After IDE restart?
No, after I moved it from "files and locations" to processes... I had tried this before reading about it, and thought I had it in the right place but typos or something. I just missed the part about processes.
never hurts to check, which is why I mentioned it.
The advantage of a 64 bit operating system over a 32 bit operating system comes down to only being twice the headache.
User avatar
Tenaja
Addict
Addict
Posts: 1959
Joined: Tue Nov 09, 2010 10:15 pm

Re: PB compilation problems with MSE

Post by Tenaja »

I appreciate the persistence with helping!

I was hoping the "DOH" and embarrassed smiley would have made the sarcasm clear that I had it in the wrong place until that post. Sometimes the keyboard just isn't very clear at communicating, so I have to clean it with windex. After that, my coding always goes faster, too. :shock:
Post Reply