Merge pull request 'clan-app: fix x86_64-darwin build' (#4395) from darwin-build into main
Reviewed-on: https://git.clan.lol/clan/clan-core/pulls/4395
This commit is contained in:
@@ -29,10 +29,7 @@ def _get_lib_names() -> list[str]:
|
|||||||
msg = f"Unsupported architecture: {machine}"
|
msg = f"Unsupported architecture: {machine}"
|
||||||
raise RuntimeError(msg)
|
raise RuntimeError(msg)
|
||||||
if system == "darwin":
|
if system == "darwin":
|
||||||
if machine == "arm64":
|
|
||||||
return ["libwebview.dylib"]
|
return ["libwebview.dylib"]
|
||||||
msg = "Not supported"
|
|
||||||
raise RuntimeError(msg)
|
|
||||||
# linux
|
# linux
|
||||||
return ["libwebview.so"]
|
return ["libwebview.so"]
|
||||||
|
|
||||||
|
|||||||
@@ -1,6 +1,18 @@
|
|||||||
{ pkgs, ... }:
|
{
|
||||||
|
gtk4,
|
||||||
|
webkitgtk_6_0,
|
||||||
|
lib,
|
||||||
|
clangStdenv,
|
||||||
|
fetchFromGitea,
|
||||||
|
gnumake,
|
||||||
|
cmake,
|
||||||
|
clang-tools,
|
||||||
|
pkg-config,
|
||||||
|
stdenv,
|
||||||
|
...
|
||||||
|
}:
|
||||||
|
|
||||||
pkgs.clangStdenv.mkDerivation {
|
clangStdenv.mkDerivation {
|
||||||
pname = "webview";
|
pname = "webview";
|
||||||
version = "nightly";
|
version = "nightly";
|
||||||
|
|
||||||
@@ -8,7 +20,7 @@ pkgs.clangStdenv.mkDerivation {
|
|||||||
# We disallow remote connections from the UI on Linux
|
# We disallow remote connections from the UI on Linux
|
||||||
# TODO: Disallow remote connections on MacOS
|
# TODO: Disallow remote connections on MacOS
|
||||||
|
|
||||||
src = pkgs.fetchFromGitea {
|
src = fetchFromGitea {
|
||||||
domain = "git.clan.lol";
|
domain = "git.clan.lol";
|
||||||
owner = "clan";
|
owner = "clan";
|
||||||
repo = "webview";
|
repo = "webview";
|
||||||
@@ -37,23 +49,19 @@ pkgs.clangStdenv.mkDerivation {
|
|||||||
];
|
];
|
||||||
|
|
||||||
# Dependencies used during the build process, if any
|
# Dependencies used during the build process, if any
|
||||||
nativeBuildInputs = with pkgs; [
|
nativeBuildInputs = [
|
||||||
gnumake
|
gnumake
|
||||||
cmake
|
cmake
|
||||||
clang-tools
|
clang-tools
|
||||||
pkg-config
|
pkg-config
|
||||||
];
|
];
|
||||||
|
|
||||||
buildInputs =
|
buildInputs = lib.optionals stdenv.isLinux [
|
||||||
with pkgs;
|
|
||||||
[
|
|
||||||
]
|
|
||||||
++ pkgs.lib.optionals stdenv.isLinux [
|
|
||||||
webkitgtk_6_0
|
webkitgtk_6_0
|
||||||
gtk4
|
gtk4
|
||||||
];
|
];
|
||||||
|
|
||||||
meta = with pkgs.lib; {
|
meta = with lib; {
|
||||||
description = "Tiny cross-platform webview library for C/C++. Uses WebKit (GTK/Cocoa) and Edge WebView2 (Windows)";
|
description = "Tiny cross-platform webview library for C/C++. Uses WebKit (GTK/Cocoa) and Edge WebView2 (Windows)";
|
||||||
homepage = "https://github.com/webview/webview";
|
homepage = "https://github.com/webview/webview";
|
||||||
license = licenses.mit;
|
license = licenses.mit;
|
||||||
|
|||||||
Reference in New Issue
Block a user