|
2 months ago | |
---|---|---|
data/bref | 2 months ago | |
include/heb12 | 2 months ago | |
src | 2 months ago | |
tests | 2 months ago | |
.clang-format | 2 months ago | |
.gitignore | 2 months ago | |
LICENSE | 2 months ago | |
Makefile | 2 months ago | |
README.md | 2 months ago | |
TODO.md | 2 months ago | |
run_test.sh | 2 months ago |
The combination of the Heb12 backend written in C.
To build, simply run make
. It builds a static library to dist/libheb12.a
.
A shared library can also be built by running make shared
. make install
installs it to prefix
, which is /usr/local
by default.
These options can be changed in the Makefile.
bref is a simple Bible reference parser. It splits apart references like John 3:16-17
, but not more complex (see fbrp). It reads the data directory provided by heb12_data_dir
and reads a file with a list of ways to shorten Bible books (usually /usr/local/share/heb12/bref/books_all.csv
).
The configuration library providing functions for finding and loading configuration for Heb12.
Configuration files are normally saved to ~/.config/heb12
and shared data (such as book names and Bibles) are normally saved to /usr/local/share/heb12
. This can be configured during the build by defining (or undefining, to use ~/.local/share/heb12
) HEB12_DATA_DIR
.
Shared data is stored in /usr/local/share/heb12
because certain files need to be installed to it and are not generated by the program itself (except for the Bibles, which are downloaded by the program).
A parser for the haplous Bible format.
#include <stdio.h>
#include <heb12/haplous.h>
int main()
{
int err = 0;
struct haplous_work work = haplous_work_init("web.txt", &err);
if (err != HAPLOUS_OK) {
fprintf(stderr, "Failed to open web.txt\n");
return 1;
}
}
See more examples in the tests.
Copyright (C) 2020, Josias Allestad and other Heb12 contributors. Licensed under the BSD-3-Clause license. See the license file for more information.