even better so far
This commit is contained in:
parent
24416c338c
commit
400c317dd2
20
flake.nix
20
flake.nix
|
@ -18,13 +18,18 @@
|
|||
system: let
|
||||
pkgs = import nixpkgs {inherit system;};
|
||||
|
||||
llvmPackages = with pkgs;
|
||||
if hostPlatform.isLinux
|
||||
then llvmPackages_20
|
||||
else llvmPackages_19;
|
||||
|
||||
stdenv = with pkgs;
|
||||
(
|
||||
if hostPlatform.isLinux
|
||||
then stdenvAdapters.useMoldLinker
|
||||
else lib.id
|
||||
)
|
||||
llvmPackages_20.stdenv;
|
||||
llvmPackages.stdenv;
|
||||
|
||||
sources = import ./_sources/generated.nix {
|
||||
inherit (pkgs) fetchFromGitHub fetchgit fetchurl dockerTools;
|
||||
|
@ -82,8 +87,7 @@
|
|||
sqlitecpp
|
||||
# ftxui
|
||||
]
|
||||
++ linuxPkgs
|
||||
++ darwinPkgs;
|
||||
++ linuxPkgs;
|
||||
|
||||
linuxPkgs = nixpkgs.lib.optionals stdenv.isLinux (with pkgs;
|
||||
[
|
||||
|
@ -96,12 +100,6 @@
|
|||
xorg.libX11
|
||||
wayland
|
||||
]));
|
||||
|
||||
darwinPkgs = nixpkgs.lib.optionals stdenv.isDarwin (with pkgs.pkgsStatic.darwin.apple_sdk.frameworks; [
|
||||
Foundation
|
||||
MediaPlayer
|
||||
SystemConfiguration
|
||||
]);
|
||||
in
|
||||
with pkgs; {
|
||||
packages = rec {
|
||||
|
@ -144,7 +142,7 @@
|
|||
|
||||
clang-format = {
|
||||
enable = true;
|
||||
package = pkgs.llvmPackages_20.clang-tools;
|
||||
package = pkgs.llvmPackages.clang-tools;
|
||||
};
|
||||
};
|
||||
};
|
||||
|
@ -154,7 +152,7 @@
|
|||
[
|
||||
alejandra
|
||||
bear
|
||||
llvmPackages_20.clang-tools
|
||||
llvmPackages.clang-tools
|
||||
cmake
|
||||
lldb
|
||||
hyperfine
|
||||
|
|
34
meson.build
34
meson.build
|
@ -6,6 +6,7 @@ project(
|
|||
'default_library=static',
|
||||
'warning_level=everything',
|
||||
'buildtype=debugoptimized',
|
||||
'cpp_args=-fvisibility=hidden',
|
||||
],
|
||||
)
|
||||
|
||||
|
@ -28,7 +29,6 @@ if host_machine.system() == 'darwin'
|
|||
'-Wno-pre-c++20-compat-pedantic',
|
||||
'-Wno-switch-default',
|
||||
'-Wunused-function',
|
||||
'-fvisibility=hidden',
|
||||
],
|
||||
),
|
||||
language: 'objcpp',
|
||||
|
@ -47,7 +47,6 @@ common_cpp_args = [
|
|||
'-Wno-pre-c++20-compat-pedantic',
|
||||
'-Wno-switch-default',
|
||||
'-Wunused-function',
|
||||
'-fvisibility=hidden',
|
||||
'-fno-strict-enums',
|
||||
'-nostdlib++',
|
||||
]
|
||||
|
@ -86,6 +85,22 @@ deps = [
|
|||
dependency('tomlplusplus', include_type: 'system', static: true),
|
||||
]
|
||||
|
||||
if host_machine.system() == 'darwin'
|
||||
deps += dependency(
|
||||
'appleframeworks',
|
||||
modules : ['foundation', 'mediaplayer', 'systemconfiguration'],
|
||||
static: true,
|
||||
)
|
||||
elif host_machine.system() == 'linux' or host_machine.system() == 'freebsd'
|
||||
deps += dependency('SQLiteCpp')
|
||||
deps += dependency('sdbus-c++')
|
||||
deps += dependency('x11')
|
||||
deps += dependency('xcb')
|
||||
deps += dependency('xau')
|
||||
deps += dependency('xdmcp')
|
||||
deps += dependency('wayland-client')
|
||||
endif
|
||||
|
||||
ftxui_dep = dependency(
|
||||
'ftxui',
|
||||
modules: ['ftxui::screen', 'ftxui::dom', 'ftxui::component'],
|
||||
|
@ -109,21 +124,6 @@ reflectcpp_proj = cmake.subproject('reflectcpp')
|
|||
reflectcpp_dep = reflectcpp_proj.dependency('reflectcpp')
|
||||
deps += reflectcpp_dep
|
||||
|
||||
if host_machine.system() == 'darwin'
|
||||
deps += dependency('Foundation')
|
||||
deps += dependency('MediaPlayer')
|
||||
deps += dependency('SystemConfiguration')
|
||||
deps += dependency('iconv')
|
||||
elif host_machine.system() == 'linux' or host_machine.system() == 'freebsd'
|
||||
deps += dependency('SQLiteCpp')
|
||||
deps += dependency('sdbus-c++')
|
||||
deps += dependency('x11')
|
||||
deps += dependency('xcb')
|
||||
deps += dependency('xau')
|
||||
deps += dependency('xdmcp')
|
||||
deps += dependency('wayland-client')
|
||||
endif
|
||||
|
||||
objc_args = []
|
||||
link_args = []
|
||||
|
||||
|
|
|
@ -1,5 +1,3 @@
|
|||
|
||||
|
||||
#include <rfl.hpp>
|
||||
#include <rfl/Field.hpp>
|
||||
|
||||
|
|
Loading…
Reference in a new issue