nlib
Information About the Libraries for Cafe
Required Software
Requires the Cafe SDK (2.10.00 or later) and a C++ compiler. The following software programs are also required for the sample to be built.
Directory Structure
The Cafe package has the following directory structure.
├── system
│   ├── include                      # Header files.
│   └── lib
│       └── ghs
│            └── cafe
│                └── DEBUG           # Library files for Debug build
│                └── NDEBUG          # Library files for Release build
└── samples
     ├── cafe/Makefile                # Makefile for the samples.
     └── cmake/cmake_cafe_ninja.ps1   # A PowerShell script for creating build.ninja for the sample programs.
Cmake_cafe_ninja.ps1 creates a build script for building with cmake and ninja (https://ninja-build.org/) for Windows.
Other Platform-Specific Information
  • Do not directly use OSSetThreadCleanupCallback(). Use a destructor that can be specified with nlib_tls_alloc().
  • Do not directly use OSGetThreadSpecific() and OSSetThreadSpecific(). Use nlib_tls_alloc().
  • Use one TLS when using a thread.
  • For the exi library for Cafe, use one TLS with nlib_tls_alloc().
  • For nmalloc, use one TLS with nlib_tls_alloc().
  • Because it is possible to build out of the source tree, independent commondefs are used. In addition, kanji=utf-8 is specified.