Skip to content

Commit

Permalink
Add prerequisites for building with GNU autotools
Browse files Browse the repository at this point in the history
  • Loading branch information
rockdaboot committed Mar 24, 2024
1 parent 15e7f40 commit 9293ccc
Showing 1 changed file with 19 additions and 22 deletions.
41 changes: 19 additions & 22 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -8,8 +8,7 @@ Solaris OpenCSW [![Build Status Solaris amd64](https://buildfarm.opencsw.org/bui
[![Build Status Solaris SparcV9](https://buildfarm.opencsw.org/buildbot/png?builder=libpsl-solaris10-sparcv9)](https://buildfarm.opencsw.org/buildbot/builders/libpsl-solaris10-sparcv9)


libpsl - C library to handle the Public Suffix List
===================================================
# libpsl - C library to handle the Public Suffix List

A *Public Suffix List* is a collection of Top Level Domains (TLDs) suffixes.
TLDs include *Global Top Level Domains* (gTLDs) like `.com` and `.net`;
Expand Down Expand Up @@ -44,14 +43,12 @@ Download the Public Suffix List [here](https://github.com/publicsuffix/list/blob
The original DAFSA code is from the [Chromium Project](https://code.google.com/p/chromium/).


API Documentation
-----------------
## API Documentation

You find the current API documentation [here](https://rockdaboot.github.io/libpsl).


Quick API example
-----------------
## Quick API example

#include <stdio.h>
#include <libpsl.h>
Expand All @@ -73,8 +70,7 @@ Quick API example
return 0;
}

Command Line Tool
-----------------
## Command Line Tool

Libpsl comes with a tool 'psl' that gives you access to most of the
library API via command line.
Expand All @@ -83,8 +79,7 @@ library API via command line.

prints the usage.

Convert PSL into DAFSA
----------------------
## Convert PSL into DAFSA

The [DAFSA](https://en.wikipedia.org/wiki/Deterministic_acyclic_finite_state_automaton) format is a compressed
representation of strings. Here we use it to reduce the whole PSL to about 32k in size.
Expand All @@ -97,17 +92,15 @@ Test the result (example)

$ tools/psl --load-psl-file psl.dafsa aeroclub.aero

License
-------
## License

Libpsl is made available under the terms of the MIT license.<br>
See the LICENSE file that accompanies this distribution for the full text of the license.

src/psl-make-dafsa and src/lookup_string_in_fixed_set.c are licensed under the term written in
src/LICENSE.chromium.

Building from tarball
---------------------
## Building from tarball

Choose a release from https://github.com/rockdaboot/libpsl/tags an download the tarball
named `libpsl-{version}.tar.*`. Unpack with `tar xf <filename>`, cd into the libsl* directory.
Expand All @@ -124,24 +117,29 @@ Install with
sudo make install
```

Building from git
-----------------

You should have python2.7+ installed.
## Building from git

Download project with

git clone --recursive https://github.com/rockdaboot/libpsl
cd libpsl

Build with GNU autotools
### Building with GNU autotools

Prerequisites:
- python2.7+ (for converting the PSL list)
- basic C development tools (compiler, linker)
- git, make, autoconf, autoconf-archive, autopoint, automake, autotools,
- libtool, gettext, m4, pkg-config
- for building docs: gtk-doc-tools (gtkdocize)
- for building tarballs: gzip, lzip

./autogen.sh
./configure
make
make check

Build with `meson`
### Building with `meson`

meson builddir
ninja -C builddir
Expand All @@ -151,8 +149,7 @@ There is also an unofficial MSVC nmake build configuration in `msvc/`. Please
see README.MSVC.md on building libpsl with Visual Studio via NMake or Meson.


Mailing List
------------
## Mailing List

[Mailing List Archive](https://groups.google.com/forum/#!forum/libpsl-bugs)

Expand Down

0 comments on commit 9293ccc

Please sign in to comment.