Menu

#100 Compatibility patches

cppcms-v1.0.x
closed
nobody
None
1
2014-10-30
2013-07-10
Anonymous
No

Various patches for compatibility with NetBSD, libc++ and C++11

1 Attachments

Discussion

  • Artyom Beilis

    Artyom Beilis - 2014-08-02

    Several notes:

    (a) some of the patches are incorrect a

    For example

    • return is_;
    • return is_.good() || is_.eof();

    Is just incorrect. It should be something like !is_.fail() don't recall correctly.

    setpshared handing incorrect it should be checked at cmake level if pthread_mutexattr_setpshared exists and if not add conditional build. This approach is very problematic if one day NetBSD will support pshared

    I suggest just disable prefork cache: by adding -DDISABLE_PREFORK_CACHE=ON in any case with flock it is generally sub-optimal.

    About cppcms_run... ok Does NetBSD has bash :-(... (fine I see the point)

    NetBSD requires some more working. But some cleanup of the patches is needed.

     
  • Jörg Sonnenberger

    Cleaner replacement patch.

     
  • Jörg Sonnenberger

    One more.

     
  • Jörg Sonnenberger

    The explicit bool conversion was correct, but just requesting the cast directly is simpler.

    NetBSD doesn't have bash in the base system and given that no real bash feature is needed, I don't see the point in requiring it.

    I don't believe I or anyone else will add pshared mutexes in the near future. If it should happen, the build would fail, so no real functional difference. That said, disabling the cache alone is not enough to finish the build as posix_util.h line 56 uses the functions.

     
  • Artyom Beilis

    Artyom Beilis - 2014-10-14

    Ok besides cppcms_run (that requires some testing from my side that /bin/sh works) the rest should work. Also the workaround for the posix util is different.

    Can you please verify that everything works. Also check if tc_test fails maybe -rdynamic should be added for NetBSD as well (see CMakeLists.txt/Clang/FreeBSD clause).

    It would remain to handle /bin/sh

     
  • Artyom Beilis

    Artyom Beilis - 2014-10-29

    Already fixed

     
  • Artyom Beilis

    Artyom Beilis - 2014-10-29
    • status: open --> closed
     

Anonymous
Anonymous

Add attachments
Cancel