• Bug#1066249: libmediascan: FTBFS: api_test.c:80:3: error: implicit decl

    From gregor herrmann@21:1/5 to Lucas Nussbaum on Thu Mar 14 18:30:01 2024
    On Wed, 13 Mar 2024 12:41:10 +0100, Lucas Nussbaum wrote:

    api_test.c: In function ‘check_mimetypes’:
    api_test.c:80:3: error: implicit declaration of function ‘gettimeofday’ [-Werror=implicit-function-declaration]
    80 | gettimeofday(&now, NULL);

    api_test.c: In function ‘main’:
    api_test.c:198:3: error: implicit declaration of function ‘run_unit_tests’ [-Werror=implicit-function-declaration]
    198 | run_unit_tests();

    test_background.c: In function ‘test_background_api’: test_background.c:12:16: error: implicit declaration of function ‘mkdir’; did you mean ‘_mkdir’? [-Werror=implicit-function-declaration]
    12 | #define _mkdir mkdir

    test_background.c: In function ‘test_async_api’: test_background.c:822:3: error: implicit declaration of function ‘gettimeofday’ [-Werror=implicit-function-declaration]
    822 | gettimeofday(&now, NULL);

    test.c: In function ‘TouchFile’:
    test.c:512:3: error: implicit declaration of function ‘gettimeofday’ [-Werror=implicit-function-declaration]
    512 | gettimeofday(&now, NULL);

    test.c:513:3: error: implicit declaration of function ‘utimes’; did you mean ‘ctime’? [-Werror=implicit-function-declaration]
    513 | utimes(filename , &now);

    I've pushed a patch to git which make the package compile without
    errors.

    Not going to upload as-is, as I hardly speak any C and don't really
    know what I'm doing and this is more than adding a missing #include
    or prototype and I don't understand the code.


    Cheers,
    gregor

    --
    .''`. https://info.comodo.priv.at -- Debian Developer https://www.debian.org
    : :' : OpenPGP fingerprint D1E1 316E 93A7 60A8 104D 85FA BB3A 6801 8649 AA06
    `. `' Member VIBE!AT & SPI Inc. -- Supporter Free Software Foundation Europe
    `-

    -----BEGIN PGP SIGNATURE-----

    iQKTBAEBCgB9FiEE0eExbpOnYKgQTYX6uzpoAYZJqgYFAmXzMiBfFIAAAAAALgAo aXNzdWVyLWZwckBub3RhdGlvbnMub3BlbnBncC5maWZ0aGhvcnNlbWFuLm5ldEQx RTEzMTZFOTNBNzYwQTgxMDREODVGQUJCM0E2ODAxODY0OUFBMDYACgkQuzpoAYZJ qgbtbw/+PfvNKpLYWCW/hzZdf5jKuVV8eFANAEklptQiKCMGC/zvJpY3hJBHpvWr LQnGfS9uTdpD8JlraqTInWM3uL9Sv7X3FTinLJ0gN/u7yEiKGhMIK1QyHfdW6JKG WtvMmfrhtgdR+M3GiT6AAJqg8/TKNMtiYA6YzwVwgx1deLz9nsJCXL57R6PiEwD7 jRTmko3aBXZNm7ODbxl/5iCnGNkBFsXJ7dtDw57khHt3tIpvrLOhw2ipc0/I7A6P LA1cJdVz5FRWWz8IeuKnZXANpExKVb8ETDp4XMCUW19W7lEHAtGQ4Fm+x5wAbILG iXxJ42W88tMlgIWy0tzNqT7vUMpQIS32NPKu5D4s2R1gaH2jqjA9WBfcLvgaIi5P hTyy7tMUot0k+Yy1fT9ZFNAwujSESMB/0SFeTEvtLTqzioFki/Q+dkOdo6oFp0L0 zLlkJRqUESUsr0OMDloImE0tMSWTtCNTVIimbgwFU4rfvATA4iqlsYvaXyeKInyn
    GGmjjvdp