genode/base-linux/src/test/lx_hybrid_ctors/testlib.cc
Christian Prochaska c29b5f7da3 Fix lx_hybrid_ctors test for Ubuntu 11.10
On Ubuntu 11.10 the host library created for the 'lx_hybrid_ctors' test
doesn't get loaded, because the test object in the library is not being
used by the application. This commit fixes the problem by having the
application call a dummy function in the library.

Fixes #120.
2012-02-27 16:05:03 +01:00

29 lines
586 B
C++

/*
* \brief Test if global static constructors in host shared libs get called
* \author Christian Prochaska
* \date 2011-11-24
*/
/*
* Copyright (C) 2011-2012 Genode Labs GmbH
*
* This file is part of the Genode OS framework, which is distributed
* under the terms of the GNU General Public License version 2.
*/
#include <stdio.h>
#include "testlib.h"
Testlib_testclass::Testlib_testclass()
{
printf("[init -> test-lx_hybrid_ctors] Global static constructor of host library called.\n");
}
void Testlib_testclass::dummy() { }
Testlib_testclass testlib_testobject;