Pattern for VC

General questions regarding the usage of CodeLite
frank_frl
CodeLite Expert
Posts: 176
Joined: Sun Aug 17, 2008 2:45 pm
Contact:

Pattern for VC

Post by frank_frl »

Hi,

I have to work on a Visual Studio project, which I can not import because it will occasionally be changed by an other program. Since I don't wanna use Visual Studio as editor, I managed to build with CL by doing a custom build calling 'devenv /nologo xxx.sln /build Release'. That works like a charm.
The only problem I have is that CL is not marking the errors in the output window. My knowledge about regex is very little, so I don't know how to change the error patterns to work correct. :(
An error output looks like this:

Code: Select all

1>..\..\Source\CMainComponent.cpp(63) : error C2146: syntax error : missing ';' before identifier 'setSize'
The current pattern like this:

Code: Select all

(^[a-zA-Z\\\.0-9 _/\:\+\-]+ *)(\()([0-9]+)(\))( \: )(error)
File name index 1
Line number index 3
Any suggestions?

Frank
User avatar
eranif
CodeLite Plugin
Posts: 6373
Joined: Wed Feb 06, 2008 9:29 pm
Genuine User: Yes
IDE Question: C++
Contact:

Re: Pattern for VC

Post by eranif »

Hi Frank,

I use VC on daily basis at work. The only different is that you are using devenv to perform the build, while I use 'NMAKE' (I am using qmake to generate the NMAKE files)
The pattern defined in codelite is set toward capturing the VC compile output, but you have an extra characters in the output that fails to regex.

this prefix:

Code: Select all

1>
Is the cause of the problem (and it is produced by Visual Studio)

Change the regex to:

Code: Select all

([0-9]+\>)?([a-zA-Z\\\.0-9 _/\:\+\-]+ *)(\()([0-9]+)(\))( \: )(error)
File 2
Line 4

It should capture it.

Eran
Make sure you have read the HOW TO POST thread
frank_frl
CodeLite Expert
Posts: 176
Joined: Sun Aug 17, 2008 2:45 pm
Contact:

Re: Pattern for VC

Post by frank_frl »

eranif wrote:
Change the regex to:

Code: Select all

([0-9]+\>)?([a-zA-Z\\\.0-9 _/\:\+\-]+ *)(\()([0-9]+)(\))( \: )(error)
File 2
Line 4
Hi Eran,

thanks a lot, that fixed it. :D

The problem is that I have to work with JUCE on PC and MAC and we are working with 3 people on one project, where one guy prefers to work with VC, the other with xCode and I with CL. ;) In JUCE the whole project settings and changes are done with the Introjucer, which generates VC and xCode project files. So it is easier for me to use devenv and xcodebuild with the original project files from within CodeLite.

Best regards

Frank
Post Reply