-
Notifications
You must be signed in to change notification settings - Fork 352
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
swift language support requires tweaking on unstable #514
Comments
I believe issue: #507 is related, closing because it is essentially a duplicate |
Sorry reopening because unsure if #507 is going to get merged. Additionally, when testing the patch in #507 it didn't resolve the issue: Here is my shell definition: {
pkgs,
inputs,
}: let
# inherit (pkgs) mkShell;
# in
# mkShell {
# nativeBuildInputs = with pkgs; [swift swiftpm];
# }
inherit (inputs.devenv.lib) mkShell;
in
mkShell {
inherit inputs pkgs;
modules = [
({
config,
pkgs,
...
}:
{
packages = with pkgs; [swift swiftpm];
languages.swift.enable = true;
}
// pkgs.lib.optionals pkgs.stdenv.isDarwin {
packages = [
pkgs.swiftPackages.Foundation
];
env.CFLAGS = [" -iframework ${config.env.DEVENV_PROFILE}/Library/Frameworks"];
})
];
} Here is direnv file
Here is the error I get: ❯ direnv reload
direnv: loading ~/src/me/test/greeting/.envrc
direnv: using flake /Users/chernand/src/me/nixcfg#swift --impure
direnv: nix-direnv: renewed cache
direnv: export +CC +CFLAGS +C_INCLUDE_PATH +DEVENV_DOTFILE +DEVENV_PROFILE +DEVENV_ROOT +DEVENV_STATE +IN_NIX_SHELL +LD_LIBRARY_PATH +LIBRARY_PATH +PKG_CONFIG_PATH +name ~PATH ~XDG_CONFIG_DIRS ~XDG_DATA_DIRS
me/test/greeting via 🐦 v5.7.3 via ❄️ impure (devenv-shell-env) took 2s
❯ swift build
error: 'greeting': Invalid manifest
/Users/chernand/src/me/test/greeting/Package.swift:4:8: error: missing required module 'Foundation'
import PackageDescription
^
error: ExitCode(rawValue: 1)
[0/1] Planning builderror: 'greeting': Invalid manifest
/Users/chernand/src/me/test/greeting/Package.swift:4:8: error: missing required module 'Foundation'
import PackageDescription
^
|
Please let me know if there is any additional information I can provide. Also the working shell definition is commented. |
Could you give it a try now? It should be fixed. |
This should be fixed, please reopen if not. |
Describe the bug
swift build fails on unstable
To Reproduce
Version
Added via flake inputs
The text was updated successfully, but these errors were encountered: