Comments (3)
So looks like the bazel doesn't support pkg-config? Not sure what I can do here. You do have an option to not use pkg-config, or not use an external library at all?
from go-fitz.
gazelle seem working fine with cgo as it generates the following build:
load("@io_bazel_rules_go//go:def.bzl", "go_library", "go_test")
go_library(
name = "go-fitz",
srcs = [
"fitz.go",
"fitz_cgo.go",
],
cgo = True,
clinkopts = select({
"@io_bazel_rules_go//go/platform:android_386": [
"-Llibs -lmupdf_linux_386 -lmupdfthird_linux_386 -lm",
],
"@io_bazel_rules_go//go/platform:android_amd64": [
"-Llibs -lmupdf_linux_amd64 -lmupdfthird_linux_amd64 -lm",
],
"@io_bazel_rules_go//go/platform:android_arm": [
"-Llibs -lmupdf_android_arm -lmupdfthird_android_arm -lm -llog",
],
"@io_bazel_rules_go//go/platform:android_arm64": [
"-Llibs -lmupdf_android_arm64 -lmupdfthird_android_arm64 -lm -llog",
],
"@io_bazel_rules_go//go/platform:darwin_amd64": [
"-Llibs -lmupdf_darwin_amd64 -lmupdfthird_darwin_amd64 -lm",
],
"@io_bazel_rules_go//go/platform:ios_amd64": [
"-Llibs -lmupdf_darwin_amd64 -lmupdfthird_darwin_amd64 -lm",
],
"@io_bazel_rules_go//go/platform:linux_386": [
"-Llibs -lmupdf_linux_386 -lmupdfthird_linux_386 -lm",
],
"@io_bazel_rules_go//go/platform:linux_amd64": [
"-Llibs -lmupdf_linux_amd64 -lmupdfthird_linux_amd64 -lm",
],
"@io_bazel_rules_go//go/platform:linux_arm": [
"-Llibs -lmupdf_linux_arm -lmupdfthird_linux_arm -lm",
],
"@io_bazel_rules_go//go/platform:linux_arm64": [
"-Llibs -lmupdf_linux_arm64 -lmupdfthird_linux_arm64 -lm",
],
"@io_bazel_rules_go//go/platform:windows_386": [
"-Llibs -lmupdf_windows_386 -lmupdfthird_windows_386 -lm -lcomdlg32 -lgdi32 -lmsvcr90",
],
"@io_bazel_rules_go//go/platform:windows_amd64": [
"-Llibs -lmupdf_windows_amd64 -lmupdfthird_windows_amd64 -lm -lcomdlg32 -lgdi32",
],
"//conditions:default": [],
}),
copts = ["-Iinclude"],
importpath = "github.com/gen2brain/go-fitz",
visibility = ["//visibility:public"],
)
alias(
name = "go_default_library",
actual = ":go-fitz",
visibility = ["//visibility:public"],
)
go_test(
name = "go-fitz_test",
srcs = [
"example_test.go",
"fitz_test.go",
],
data = glob(["testdata/**"]),
embed = [":go-fitz"],
)
Maybe avoiding usage of pkg-config could do the trick.
from go-fitz.
By default, the library is built with included static libraries. With -tags extlib
enabled it links to an external library, and only with both -tags 'extlib pkgconfig'
it will use pkg-config, so it is already avoided and must be explicitly enabled.
from go-fitz.
Related Issues (20)
- getting crash for some pdf format HOT 1
- start program HOT 2
- undefined: fitz.New HOT 3
- fitz is not importing correctly HOT 2
- centos alpine build faild HOT 5
- Linux platform, when PDF is invalid
- Error when convert PDF to Image HOT 3
- Out of Memory issues with frequent requests HOT 6
- build for linux HOT 2
- Creating new PDF file with loaded pages HOT 1
- Vendoring the include files HOT 2
- feat: support windows/arm64 HOT 2
- Getting error when building HOT 6
- linux compilation error HOT 3
- linux ubuntu build fail HOT 5
- Makes discord/lilliput segfault HOT 2
- fitz is empty HOT 2
- How to build docker with this package?
- GCC 12.2 Support HOT 10
- Is it possible to add PDF splitting and merging functions? HOT 1
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from go-fitz.