An alternative runtime for C11/C23 (mirror)
Go to file
bumbread 38da83bfe0 nearbyint rewrite 2022-08-06 16:31:44 +11:00
doc Update assert.h 2022-07-30 13:07:34 +11:00
inc remove win32 declspec thread 2022-08-06 10:41:45 +11:00
src nearbyint rewrite 2022-08-06 16:31:44 +11:00
test nearbyint rewrite 2022-08-06 16:31:44 +11:00
.gitignore I have no idea but something for linux 2022-06-28 23:57:14 +11:00
bake.cmd Remove submodule dependencies 2022-08-05 15:21:07 +11:00
readme Remove submodule dependencies 2022-08-05 15:21:07 +11:00
test.cmd remove win32 declspec thread 2022-08-06 10:41:45 +11:00
todo Fix some printf bugs and document other 2022-08-06 11:06:03 +11:00
utf8.rc Remove submodule dependencies 2022-08-05 15:21:07 +11:00
utf8.xml Remove submodule dependencies 2022-08-05 15:21:07 +11:00

readme

ABOUT
  Ciabatta  -  An implementation of CRT for x86-64 windows and linux platforms.
The  goal  is  to  provide  a  platform-independent  CRT  with  the  purpose of
explicitly  defining  some  of platform-defined behaviours in order to simplify
the development and providing additional functionality to aid the developers in
writing cross-platform applications.

Note that Undefined Behaviour is impossible to define on a CRT level, since the
semantics  of the language can only be changed at the compiler level. Sometimes
the  compilers will replace CRT function calls with builtin functions, which is
meant  as  an optimization, e.g. replacing some forms of prinf() with puts() or
replacing  strlen with an x86 rep movsb instruction. Even if ciabatta does have
a  specific  behaviour  under  given  UB  conditions,  that  behaviour  is  not
guaranteed.

The goals:
  - Providing  API  for sockets, unicode processing (not just encodings), maybe
    the  support  for  common  image  and  data  file  formats and other useful
    non-standard functionality.
  - Making  it  easy  to  port  the library to a new platform, e.g. a custom OS
    kernel or a different processor architecture.
  - Defining  implementation-defined  behaviours  of  some of the functions and
    explicitly documenting them.
  - Make it reasonably fast compared to MSVCRT and GLIBC.

PLATFORM SUPPORT
  OS/Kernel:
  - Windows (64-bit)
  - TODO: Linux
  Processor Architecture
  - x86-64

USAGE
  Note that the library can only be used with clang
  Once MSVC compiler finally decides to support C11 atomic types I'll consider
  supporting MSVC, until then clang is your only option
  1. Run bake.cmd
  2. Make sure you've got the following in some folder:
  - The inc folder
  - The ciabatta.lib archive file
  - The utf8.obj object file
  3. Add the following flags to your compilation command:
    -I <path/to/ciabatta/inc> utf8.obj -nostdlib -mfma
  4. Don't forget to link to the following libraries:
    -lciabatta.lib

CONTRIBUTING
  Pull requests are always welcome.


LICENCE

TBD, but probably i'll make it MIT or WTFPL :kekw: