Added a bit of stuff referenced by inline functions in private kernel

headers. GCC 2 has the unpleasant habit of actually linking the unused inline
functions in. That doesn't suffice to build the userlandfs server with debug
info (it would be the wrong file anyway), but allows to build checksumfs.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@37405 a95241bf-73f2-0310-859d-f6bbb57e9c96
This commit is contained in:
Ingo Weinhold 2010-07-05 16:48:44 +00:00
parent 7b2003907a
commit e66231742e
1 changed files with 23 additions and 1 deletions

View File

@ -1,5 +1,5 @@
/* /*
* Copyright 2009, Ingo Weinhold, ingo_weinhold@gmx.de. * Copyright 2009-2010, Ingo Weinhold, ingo_weinhold@gmx.de.
* Distributed under the terms of the MIT License. * Distributed under the terms of the MIT License.
*/ */
@ -29,6 +29,28 @@
#include "vfs.h" #include "vfs.h"
// When GCC 2 compiles inline functions in debug mode, it doesn't throw away
// the generated non-inlined functions, if they aren't used. So we have to
// provide the dependencies referenced by inline functions in private kernel
// headers.
#if __GNUC__ == 2
#include <cpu.h>
#include <smp.h>
cpu_ent gCPU[1];
int32
smp_get_current_cpu(void)
{
return 0;
}
#endif // __GNUC__ == 2
// #pragma mark - Notifications // #pragma mark - Notifications