View Issue Details [ Jump to Notes ] | [ Issue History ] [ Print ] | ||||||||||||
ID | Project | Category | View Status | Date Submitted | Last Update | ||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|---|
0002619 | Hubbub | [All Projects] General | public | 2018-09-24 22:47 | 2019-08-01 10:31 | ||||||||
Reporter | J. Peter Mugaas | ||||||||||||
Assigned To | kinnison | ||||||||||||
Priority | normal | Severity | major | Reproducibility | have not tried | ||||||||
Status | acknowledged | Resolution | open | ||||||||||
Platform | mingw-w64 | OS | Windows | OS Version | 10 (64-bit) | ||||||||
Product Version | 0.3.1 | ||||||||||||
Target Version | Fixed in Version | ||||||||||||
Summary | 0002619: 0.3.5 -tokenizer2 test fails to compile | ||||||||||||
Description | I was trying to compile the tokenizer.c in the test suit and I found a compile issue. I got an error saying: [ 91%] Building C object CMakeFiles/tokeniser2_shared.dir/test/tokeniser2.c.obj In file included from D:/msys64/home/jpmugaas/exp/mingw-w64-libhubbub/src/libhubbub-0.3.5/test/tokeniser2.c:15: D:/msys64/home/jpmugaas/exp/mingw-w64-libhubbub/src/libhubbub-0.3.5/test/tokeniser2.c: In function 'main': D:/msys64/home/jpmugaas/exp/mingw-w64-libhubbub/src/libhubbub-0.3.5/test/tokeniser2.c:51:10: warning: implicit declaration of function 'is_error'; did you mean 'mc_error'? [-Wimplicit-function-declaration] assert(!is_error(json)); ^~~~~~~~ D:/msys64/home/jpmugaas/exp/mingw-w64-libhubbub/src/libhubbub-0.3.5/test/testutils.h:31:13: note: in definition of macro 'assert' ((void) ((expr) || (__assert2 (#expr, __func__, __FILE__, __LINE__), 0))) ^~~~ [ 93%] Linking C executable csdetect_shared.exe [ 94%] Linking C executable entities_shared.exe [ 95%] Linking C executable parser_shared.exe [ 97%] Linking C executable tokeniser_shared.exe [ 98%] Linking C executable tree_shared.exe [100%] Linking C executable tokeniser2_shared.exe [100%] Built target entities_shared [100%] Built target csdetect_shared [100%] Built target parser_shared D:/msys64/mingw64/bin/../lib/gcc/x86_64-w64-mingw32/8.2.0/../../../../x86_64-w64-mingw32/bin/ld.exe: CMakeFiles/tokeniser2_shared.dir/objects.a(tokeniser2.c.obj):tokeniser2.c:(.text.startup+0x63): undefined reference to `is_error' collect2.exe: error: ld returned 1 exit status [100%] Built target tokeniser_shared This occured with json-c 0.13.1. The problem was that tokenizer2.c requires the bits.h header. Note that I am using cmake to build this library but I don't think that's the issue because I was able to fix the tokener.c file and I'm including a patch to do that. | ||||||||||||
Tags | No tags attached. | ||||||||||||
Fixed in CI build # | |||||||||||||
Reported in CI build # | |||||||||||||
Attached Files |
|
Notes | |
J. Peter Mugaas (reporter) 2018-09-25 00:29 |
It looks like this also effects the tokeniser3.c test series. I am including an updated patch to fix that as well. --- [ 84%] Building C object CMakeFiles/entities_shared.dir/test/entities.c.obj [ 82%] Building C object CMakeFiles/parser_shared.dir/test/parser.c.obj [ 85%] Building C object CMakeFiles/tree_shared.dir/test/tree.c.obj [ 86%] Building C object CMakeFiles/tokeniser_shared.dir/test/tokeniser.c.obj [ 88%] Building C object CMakeFiles/tokeniser3_shared.dir/test/tokeniser3.c.obj [ 89%] Building C object CMakeFiles/csdetect_shared.dir/test/csdetect.c.obj [ 90%] Building C object CMakeFiles/tokeniser2_shared.dir/test/tokeniser2.c.obj In file included from D:/msys64/home/jpmugaas/exp/mingw-w64-libhubbub/src/libhubbub-0.3.5/test/tokeniser3.c:15: D:/msys64/home/jpmugaas/exp/mingw-w64-libhubbub/src/libhubbub-0.3.5/test/tokeniser3.c: In function 'main': D:/msys64/home/jpmugaas/exp/mingw-w64-libhubbub/src/libhubbub-0.3.5/test/tokeniser3.c:49:10: warning: implicit declaration of function 'is_error'; did you mean 'mc_error'? [-Wimplicit-function-declaration] assert(!is_error(json)); ^~~~~~~~ D:/msys64/home/jpmugaas/exp/mingw-w64-libhubbub/src/libhubbub-0.3.5/test/testutils.h:31:13: note: in definition of macro 'assert' ((void) ((expr) || (__assert2 (#expr, __func__, __FILE__, __LINE__), 0))) ^~~~ [ 92%] Linking C executable entities_shared.exe [ 93%] Linking C executable parser_shared.exe [ 94%] Linking C executable tokeniser_shared.exe [ 96%] Linking C executable csdetect_shared.exe [ 97%] Linking C executable tree_shared.exe [ 98%] Linking C executable tokeniser2_shared.exe [100%] Linking C executable tokeniser3_shared.exe [100%] Built target entities_shared [100%] Built target parser_shared [100%] Built target tokeniser_shared D:/msys64/mingw64/bin/../lib/gcc/x86_64-w64-mingw32/8.2.0/../../../../x86_64-w64-mingw32/bin/ld.exe: CMakeFiles/tokeniser3_shared.dir/objects.a(tokeniser3.c.obj):tokeniser3.c:(.text.startup+0x63): undefined reference to `is_error' collect2.exe: error: ld returned 1 exit status make[2]: *** [CMakeFiles/tokeniser3_shared.dir/build.make:86: tokeniser3_shared.exe] Error 1 --- |
kinnison (administrator) 2019-08-01 10:31 |
This is very odd because `json.h` includes `bits.h` and thus should not need an additional include in order to make it work. Do you have a conflicting `json.h` on your search path? |
Issue History | |||
Date Modified | Username | Field | Change |
---|---|---|---|
2018-09-24 22:47 | J. Peter Mugaas | New Issue | |
2018-09-24 22:47 | J. Peter Mugaas | File Added: fix-test-tokenizer2.patch | |
2018-09-25 00:29 | J. Peter Mugaas | File Added: fix-test-tokenizer2-2.patch | |
2018-09-25 00:29 | J. Peter Mugaas | Note Added: 0001848 | |
2019-08-01 10:31 | kinnison | Note Added: 0002045 | |
2019-08-01 10:31 | kinnison | Assigned To | => kinnison |
2019-08-01 10:31 | kinnison | Status | new => assigned |
2019-08-01 10:31 | kinnison | Status | assigned => acknowledged |