OpenBSD: support Boehm-GC, X11 and Sqlite (#10300)

pull/10305/head
Uwe Krüger 2021-06-01 21:28:30 +02:00 committed by GitHub
parent 14d09aa7c2
commit ce3e71cb8e
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
4 changed files with 31 additions and 15 deletions

View File

@ -8,18 +8,26 @@ $if static_boehm ? {
#flag $first_existing("/opt/homebrew/lib/libgc.a", "/usr/local/lib/libgc.a")
} $else $if linux {
#flag -l:libgc.a
} $else $if openbsd {
#flag -I/usr/local/include
#flag /usr/local/lib/libgc.a
#flag -lpthread
} $else {
#flag -lgc
}
} $else {
$if macos {
#pkgconfig bdw-gc
} $else $if openbsd || freebsd {
#flag -I/usr/local/include
#flag -L/usr/local/lib
}
$if windows {
#flag -I@VEXEROOT/thirdparty/libgc/include
#flag -L@VEXEROOT/thirdparty/libgc
} $else {
#flag -lgc
}
#flag -lgc
}
$if gcboehm_leak ? {

View File

@ -85,7 +85,7 @@ fn print_backtrace_skipping_top_frames_linux(skipframes int) bool {
$if no_backtrace ? {
return false
} $else {
$if !freestanding {
$if linux && !freestanding {
$if tinyc {
C.tcc_backtrace(c'Backtrace')
return false

View File

@ -6,9 +6,15 @@ import time
import sync
import math
$if freebsd {
#flag -I/usr/local/include
#flag -L/usr/local/lib
} $else $if openbsd {
#flag -I/usr/X11R6/include
#flag -L/usr/X11R6/lib
}
#flag -lX11
#flag freebsd -I/usr/local/include
#flag freebsd -L/usr/local/lib -lX11
#include <X11/Xlib.h> # Please install a package with the X11 development headers, for example: `apt-get install libx11-dev`
// X11
[typedef]

View File

@ -1,17 +1,19 @@
module sqlite
#flag darwin -lsqlite3
#flag linux -lsqlite3
#flag solaris -lsqlite3
#flag freebsd -I/usr/local/include
#flag freebsd -Wl -L/usr/local/lib -lsqlite3
#flag windows -I@VEXEROOT/thirdparty/sqlite
#flag windows -L@VEXEROOT/thirdparty/sqlite
#flag windows @VEXEROOT/thirdparty/sqlite/sqlite3.o
// #flag linux -I @VEXEROOT/thirdparty/sqlite
// #flag @VEXEROOT/thirdparty/sqlite/sqlite.c
$if freebsd || openbsd {
#flag -I/usr/local/include
#flag -L/usr/local/lib
}
$if windows {
#flag windows -I@VEXEROOT/thirdparty/sqlite
#flag windows -L@VEXEROOT/thirdparty/sqlite
#flag windows @VEXEROOT/thirdparty/sqlite/sqlite3.o
} $else {
#flag -lsqlite3
}
#include "sqlite3.h"
//
struct C.sqlite3 {
}