about summary refs log blame commit diff stats
path: root/openbsd/openbsd_builder.py
blob: a8720c178da914c2a81474315c14084cacf7b609 (plain) (tree)
1
2
3
4
5
6
7
8
9
10









                                                               
                                         








                                    
from cffi import FFI
ffibuilder = FFI()

ffibuilder.cdef('''
    int pledge(const char *promises, const char *execpromises);
    int unveil(const char *path, const char *permissions);
    char *strerror(int errnum);
''')

ffibuilder.set_source("openbsd._openbsd",
"""
    #include <unistd.h>
    #include <string.h>
""")

if __name__ == "__main__":
    ffibuilder.compile(verbose=True)