#12434: Building unittests fails
------------------------+------------------------------
Reporter: simonsouth | Owner: nobody
Type: bug | Status: new
Priority: normal | Milestone: Unscheduled
Component: - General | Version: R1/Development
Keywords: | Blocked By:
Blocking: | Has a Patch: 0
Platform: All |
------------------------+------------------------------
This morning `jam -q -j2 unittests` fails with
{{{
src/tests/servers/launch/UtilityTest.cpp: In static member function
'static void UtilityTest::AddTests(BTestSuite&)':
src/tests/servers/launch/UtilityTest.cpp:53:38: error: 'TestEmpty' is not
a member of 'UtilityTest'
"UtilityTest::TestTranslatePath", &UtilityTest::TestEmpty));
}}}
This looks like a copy-and-paste error in [http://cgit.haiku-
os.org/haiku/commit/?id=d9bb9513c5e9b36cd4761fffb6f59e141c8aa692
d9bb9513c5e9b36cd4761fffb6f59e141c8aa692]; the line ought to read
{{{
"UtilityTest::TestTranslatePath", &UtilityTest::TestTranslatePath));
}}}
Continuing, the build fails again with
{{{
/(...)/generated/objects/haiku/x86_64/release/tests/servers/launch/Conditions.o:
In function `NetworkAvailableCondition::Test(ConditionContext&) const':
Conditions.cpp:(.text+0x488): undefined reference to
`NetworkWatcher::NetworkAvailable(bool)'
collect2: error: ld returned 1 exit status
}}}
Here the `Jamfile` changes in [http://cgit.haiku-
os.org/haiku/commit/?id=5f2abaf7df37f5e2e6cab5dffeed209e89759e07
5f2abaf7df37f5e2e6cab5dffeed209e89759e07] need to be applied to the unit
tests as well.
With these two changes the build completes for me. I'm attaching a patch
with the fixes.
--
Ticket URL: <https://dev.haiku-os.org/ticket/12434>
Haiku <https://dev.haiku-os.org>
Haiku - the operating system.