Update readme

This commit is contained in:
flysand7 2023-07-23 01:46:04 +11:00
parent 31dbc0abd1
commit b5e4824060
1 changed files with 15 additions and 16 deletions

View File

@ -29,7 +29,7 @@ time is discouraged.
Operating System: Operating System:
- Windows - Windows
- Linux (planned) - Linux
Processor Architecture: Processor Architecture:
- x86-64 - x86-64
@ -40,14 +40,13 @@ functionality.
## Building ciabatta ## Building ciabatta
Building ciabatta with MSVC is not supported. The only compiler that the Before proceeding please note that ciabatta can only be compiled and used
library have been compiled and tested with is clang. with `clang`. It may be able to work with `gcc` with some minor adjustments
but I didn't test.
Note that the library can only be used with clang
### Building on windows ### Building on windows
Run ./build.ps1 to compile ciabatta Run `./build.ps1` to compile ciabatta
- (Optionally) Run `./test crt` to make sure there are no errors - (Optionally) Run `./test crt` to make sure there are no errors
### Building and using on linux ### Building and using on linux
@ -55,8 +54,8 @@ Run ./build.ps1 to compile ciabatta
There are two options: Use ciabatta as a shared library or as a static There are two options: Use ciabatta as a shared library or as a static
library. library.
Run ./build.sh to compile ciabatta Run `./build.sh` to compile ciabatta
- If you wish to use shared library instead add -shared option to the build script - If you wish to use shared library instead add `-shared` option to the build script
## Usage ## Usage
@ -71,24 +70,24 @@ In order to compile your project with ciabatta see the following sections
### Compiling with ciabatta on windows ### Compiling with ciabatta on windows
1. Add the following flags to your compilation command: 1. Add the following flags to your compilation command:
`-nostdlib -I ./include utf8.obj -mfma` `-nostdlib -I ./include utf8.obj -mfma`
2. Link to the following libraries: 2. Link to the following libraries:
`-l ./lib/ciabatta.lib` `-l ./lib/ciabatta.lib`
**Note:** The `include` folder refers to the folder you copied from ciabatta. Set the path to it accordingly. **Note:** The `include` folder refers to the folder you copied from ciabatta. Set the path to it accordingly.
### Compiling with ciabatta on linux ### Compiling with ciabatta on linux
1. In case of static linking: - In case of static linking:
1. Add the following flags to your compilation command: 1. Add the following flags to your compilation command:
`-nostdlib -static -I ./include` - `-nostdlib -static -I ./include`
2. Link to the following libraries 2. Link to the following libraries
`./lib/ciabatta.a` - `./lib/ciabatta.a`
2. In case of dynamic linking: - In case of dynamic linking:
1. Add the following flags to your compilation command: 1. Add the following flags to your compilation command:
`-nostdlib -no-pie -I ./include` - `-nostdlib -no-pie -I ./include`
2. Link to the following libraries: 2. Link to the following libraries:
`./lib/ciabatta.so ./lib.ctors.o ./lib.entry.o` - `./lib/ciabatta.so ./lib.ctors.o ./lib.entry.o`
## Contributing ## Contributing