a-Shell-commands icon indicating copy to clipboard operation
a-Shell-commands copied to clipboard

pkg-config

Open macOneOone opened this issue 1 year ago • 1 comments

Hello @holzschu,

Hope you're doing fine.

I was trying to install mysqlclient and I found the error pkg-config not found.

Is it possible to add the pkg-config software or script?

macOneOone avatar Jun 29 '24 21:06 macOneOone

Hi, I tried (both pkg-config and pkgconf), and failed: pkg-config needs glib, and glib tries to compile sockets (that's the issue with being a generic library), pkgconf compiles, but crashes inexplicably when running.

You can also compile mysqlclient on your Mac, with the complete SDK here: https://github.com/holzschu/wasi-sdk/releases/tag/wasi-sdk-aShell-19 and setting the environment variable PKG_CONFIG. I use:

env CC=.../wasi-sdk/bin/clang \
AR=.../wasi-sdk/bin/ar \
LD=../wasi-sdk/bin/wasm-ld \
RANLIB=.../wasi-sdk/bin/ranlib \
CPPFLAGS="-isysroot .../wasi-sdk/share/wasi-sysroot/  -D_WASI_EMULATED_SIGNAL -D_WASI_EMULATED_PROCESS_CLOCKS -D_WASI_EMULATED_GETPID -mllvm -wasm-enable-sjlj -fwasm-exceptions " \
LDFLAGS="-lwasi-emulated-signal -lwasi-emulated-process-clocks -lwasi-emulated-getpid -L$PWD/lib -lpng16 -lfreetype -lunwind -lz -lsetjmp" \
PKG_CONFIG_PATH=$PWD/pkgconfig \
./configure --host wasm32  

holzschu avatar Jul 18 '24 15:07 holzschu