mirror of
https://github.com/reactos/reactos.git
synced 2024-09-28 21:44:31 +00:00
[0.4.13][SPEC2DEF] Mute "Exported symbol should be private"-warnings on GCC CORE-16380 temporarily
This is a temporary workaround to suppress the last remaining 4 compile-time-warnings for GCC4.7.2 dbg-cfg:
WARNING: /reactos/dll/win32/rsaenh/rsaenh.spec line 26: Exported symbol 'DllRegisterServer' should be PRIVATE
WARNING: /reactos/dll/win32/rsaenh/rsaenh.spec line 27: Exported symbol 'DllUnregisterServer' should be PRIVATE
WARNING: /reactos/dll/win32/msxml3/msxml3.spec line 10: Exported symbol 'DllGetClassObject' should be PRIVATE
WARNING: /reactos/dll/win32/ole32/ole32.spec line 137: Exported symbol 'DllGetClassObject' should be PRIVATE
The new checks were explicitly and intentionally enabled (actually by good intentions!) by:
0.4.13-dev-720-g 2becb000c8
So the muting is no proper fix. But since CORE-16380 is now unfixed for 3.5years (although there were various attempts),
I lost the hope that we will see a proper fix anytime soon.
It is more important to me to reach the "0 warnings at compile time" for the primary toolchain GCC4.7.2 dbg
for releases/0.4.13 and releases/0.4.14 than seeing these currently unaddressable warnings.
And with this commit I will reach that.
Afterwards all releases/0.4.7 to releases/0.4.14 do have 0 compile-time-warnings for their primary toolchain
GCC4.7.2 dbg-cfg RosBEWin2.1.6 and
GCC4.7.2 dbg-cfg RosBELin2.1.2 on Carrier-Releaser.
I intend to defend that state with *claws and teeth*! It took me long to get there!
When needed the checks can still be performed on all releases/0.4.7 till releases/0.4.14 on demand
by building with MSVC2010, which does these checks out-of-the-box without any additional code on our side
and it generates the same warnings for those very same modules then.
Once we will have a proper fix on master, I will reenable the check and port back the final thing.
Master-branch will not receive this workaround and will continue to warn even for GCC.
I verified my workaround to compile successfully with:
RosBEWin 2.1.6 GCC4.7.2 dbg-cfg (tested upfront)
RosBEWin 2.1.6 GCC4.7.2 rls-cfg (tested upfront)
RosBEWin 2.1.6 MSVC2010SP1 (16.0.40219.1) dbg-cfg (tested upfront)
RosBEWin 2.1.6 MSVC2010SP1 (16.0.40219.1) rls-cfg (tested upfront)
(RosBELin 2.1.2 GCC4.7.2 dbg-cfg carrier-releaser) (I will test that after the push in a few minutes)
I did not test Clang at all.
This commit is contained in:
parent
5687373014
commit
f50a9cc265
|
@ -63,7 +63,7 @@ enum _ARCH
|
||||||
typedef int (*PFNOUTLINE)(FILE *, EXPORT *);
|
typedef int (*PFNOUTLINE)(FILE *, EXPORT *);
|
||||||
int gbMSComp = 0;
|
int gbMSComp = 0;
|
||||||
int gbImportLib = 0;
|
int gbImportLib = 0;
|
||||||
int gbNotPrivateNoWarn = 0;
|
int gbNotPrivateNoWarn = 1; //FIXME: set to 0 when CORE-16380 got proper fix
|
||||||
int gbTracing = 0;
|
int gbTracing = 0;
|
||||||
int giArch = ARCH_X86;
|
int giArch = ARCH_X86;
|
||||||
char *pszArchString = "i386";
|
char *pszArchString = "i386";
|
||||||
|
@ -421,7 +421,7 @@ OutputLine_stub(FILE *file, EXPORT *pexp)
|
||||||
void
|
void
|
||||||
OutputHeader_asmstub(FILE *file, char *libname)
|
OutputHeader_asmstub(FILE *file, char *libname)
|
||||||
{
|
{
|
||||||
fprintf(file, "; File generated automatically, do not edit! \n\n");
|
fprintf(file, "; File generated automatically, do not edit!\n\n");
|
||||||
|
|
||||||
if (giArch == ARCH_X86)
|
if (giArch == ARCH_X86)
|
||||||
{
|
{
|
||||||
|
@ -1465,7 +1465,7 @@ int main(int argc, char *argv[])
|
||||||
pexports = ParseFile(pszSource, file, &cExports);
|
pexports = ParseFile(pszSource, file, &cExports);
|
||||||
if (pexports == NULL)
|
if (pexports == NULL)
|
||||||
{
|
{
|
||||||
fprintf(stderr, "Failed to allocate memory for export data!\n");
|
fprintf(stderr, "error: could not parse file!\n");
|
||||||
return -1;
|
return -1;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue