Page 1 of 2
Compile error
Posted: Mon Oct 26, 2015 11:23 am
by Enrico Maria Giordano
Compiling the following sample
Code: Select all
#pragma BEGINDUMP
#include "windows.h"
#pragma ENDDUMP
I get:
Code: Select all
e:\vce\include\winnt.h(2978) : error C2061: syntax error : identifier 'PCONTEXT'
e:\vce\include\winnt.h(2979) : error C2059: syntax error : '}'
e:\vce\include\winbase.h(1416) : error C2061: syntax error : identifier 'LPCONTEXT'
e:\vce\include\winbase.h(1416) : error C2059: syntax error : ';'
e:\vce\include\winbase.h(2119) : error C2146: syntax error : missing ')' before identifier 'lpContext'
e:\vce\include\winbase.h(2119) : error C2081: 'LPCONTEXT' : name in formal parameter list illegal
e:\vce\include\winbase.h(2119) : error C2061: syntax error : identifier 'lpContext'
e:\vce\include\winbase.h(2119) : error C2059: syntax error : ';'
e:\vce\include\winbase.h(2120) : error C2059: syntax error : ')'
e:\vce\include\winbase.h(2127) : error C2143: syntax error : missing ')' before '*'
e:\vce\include\winbase.h(2127) : error C2143: syntax error : missing '{' before '*'
e:\vce\include\winbase.h(2128) : error C2059: syntax error : ')'
What am I missing?
EMG
Re: Compile error
Posted: Mon Oct 26, 2015 11:27 am
by Antonio Linares
Enrico,
Are you using the most recent FWPPC ?
whatsnew.txt
March 2015
==========
* New: We are using most recent Harbour 3.4 from Vikthor.
* New: FWPPC is using Visual Studio 2013.
Re: Compile error
Posted: Mon Oct 26, 2015 12:34 pm
by Enrico Maria Giordano
Antonio,
I downloaded it from your website but whatsnew reports:
February 2010
EMG
Re: Compile error
Posted: Mon Oct 26, 2015 2:26 pm
by Antonio Linares
Enrico,
> Compiling the following sample
How are you compiling it ?
Re: Compile error
Posted: Mon Oct 26, 2015 2:34 pm
by Enrico Maria Giordano
Antonio,
with the provided buildce.bat.
EMG
Re: Compile error
Posted: Mon Oct 26, 2015 3:06 pm
by Antonio Linares
Enrico,
Please try it this way:
Code: Select all
#pragma BEGINDUMP
#define _ARM_
#include <windows.h>
#pragma ENDDUMP
Re: Compile error
Posted: Mon Oct 26, 2015 3:14 pm
by Enrico Maria Giordano
Antonio,
now I get:
Code: Select all
fivecec.lib(fwce.obj) : error LNK2005: __security_cookie already defined in corelibc.lib(seccook.obj)
fivecec.lib(fwce.obj) : error LNK2005: __security_check_cookie already defined in corelibc.lib(armsecgs.obj)
fivecec.lib(fwce.obj) : error LNK2005: InvertRect already defined in coredll.lib(COREDLL.dll)
EMG
Re: Compile error
Posted: Mon Oct 26, 2015 3:18 pm
by Enrico Maria Giordano
But compiling this:
Code: Select all
#include "Fwce.ch"
FUNCTION MAIN()
LOCAL oWnd
DEFINE WINDOW oWnd
@ 1, 1 BUTTON "Riproduci";
SIZE 60, 30;
ACTION ( SNDPLAYSOUND( CURDIR() + "\CONFERMA.WAV" ), SNDPLAYSOUND( CURDIR() + "\CONFERMA.WAV" ), SNDPLAYSOUND( CURDIR() + "\CONFERMA.WAV" ) )
ACTIVATE WINDOW oWnd
RETURN NIL
#pragma BEGINDUMP
#define _ARM_
#include "windows.h"
#include "mmsystem.h"
#include "hbapi.h"
LPWSTR AnsiToWide( LPSTR );
HB_FUNC( SNDPLAYSOUND )
{
LPWSTR pW = AnsiToWide( hb_parc( 1 ) );
hb_retnl( sndPlaySound( pW, hb_parni( 2 ) ) );
hb_xfree( pW );
}
#pragma ENDDUMP
I get:
Code: Select all
test.prg(33) : warning C4090: 'function' : different 'const' qualifiers
gtwvt.lib(gtwvt.obj) : warning LNK1166: cannot adjust code at offset=0x00001000, rva=0x000F9108
EMG
Re: Compile error
Posted: Mon Oct 26, 2015 3:20 pm
by Enrico Maria Giordano
And the EXE has been produced. I can't test it, sorry. I'm not using FWPCC anymore.
EMG
Re: Compile error
Posted: Mon Oct 26, 2015 3:32 pm
by Antonio Linares
Enrico,
> test.prg(33) : warning C4090: 'function' : different 'const' qualifiers
> gtwvt.lib(gtwvt.obj) : warning LNK1166: cannot adjust code at offset=0x00001000, rva=0x000F9108
This is fine. The app should work ok.
> And the EXE has been produced. I can't test it, sorry. I'm not using FWPCC anymore
Then why are you doing these tests ?

Re: Compile error
Posted: Mon Oct 26, 2015 3:48 pm
by Enrico Maria Giordano
I updated FWPPC and found that problem.
EMG
Re: Compile error
Posted: Mon Oct 26, 2015 4:24 pm
by Enrico Maria Giordano
I get the following unresolved external that I didn't get with the previous FWPCC version:
Code: Select all
error LNK2001: unresolved external symbol HB_FUN_GETLASTERROR
EMG
Re: Compile error
Posted: Mon Oct 26, 2015 6:11 pm
by Antonio Linares
Enrico,
What example are you building ?
Re: Compile error
Posted: Mon Oct 26, 2015 6:14 pm
by Enrico Maria Giordano
Antonio,
one of my old applications that use GetLastError(). It seems that it was defined in the previous FWPPC version. Now it's not anymore.
EMG
Re: Compile error
Posted: Mon Oct 26, 2015 6:18 pm
by Antonio Linares
Enrico,
Here you have it:
Code: Select all
HB_FUNC( GETLASTERROR ) // () --> nError
{
hb_retnl( GetLastError() );
}