Skip to content
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

Couldn't compile x86_64-linux-musl. #141

Open
gegogi opened this issue Nov 19, 2022 · 2 comments
Open

Couldn't compile x86_64-linux-musl. #141

gegogi opened this issue Nov 19, 2022 · 2 comments

Comments

@gegogi
Copy link

gegogi commented Nov 19, 2022

Couldn't figure out what was missing. ( As the error was FileNotFound. )
It seems that some generated source files are not there even after stage2 compilation success.

[ 98%] Built target zig1
[ 99%] Building stage2 object /home/gegogi/Projects/zig-bootstrap/out/build-zig-host/zig2.o
Consolidate compiler generated dependencies of target zig2
[100%] Linking CXX executable zig2
[100%] Built target zig2
[100%] Building stage3
[100%] Built target stage3
Install the project...
-- Install configuration: "Release"
error: FileNotFound
/home/gegogi/Projects/zig-bootstrap/zig/lib/std/os.zig:1741:23: 0x3547c8 in openatZ (build)
            .NOENT => return error.FileNotFound,
                      ^
/home/gegogi/Projects/zig-bootstrap/zig/lib/std/fs.zig:1175:13: 0x32bc06 in openFileZ (build)
            try os.openatZ(self.fd, sub_path, os_flags, 0);
            ^
/home/gegogi/Projects/zig-bootstrap/zig/lib/std/fs.zig:1102:9: 0x2ebf08 in openFile (build)
        return self.openFileZ(&path_c, flags);
        ^
/home/gegogi/Projects/zig-bootstrap/zig/lib/std/fs.zig:2532:24: 0x3a0efa in updateFile (build)
        var src_file = try source_dir.openFile(source_path, .{});
                       ^
/home/gegogi/Projects/zig-bootstrap/zig/lib/std/build.zig:1089:29: 0x3a9647 in updateFile (build)
        const prev_status = try fs.Dir.updateFile(cwd, source_path, cwd, dest_path, .{});
                            ^
/home/gegogi/Projects/zig-bootstrap/zig/lib/std/build.zig:3416:9: 0x3a9b84 in make (build)
        try builder.updateFile(self.artifact.getOutputSource().getPath(builder), full_dest_path);
        ^
/home/gegogi/Projects/zig-bootstrap/zig/lib/std/build.zig:3648:9: 0x2fe297 in make (build)
        try self.makeFn(self);
        ^
/home/gegogi/Projects/zig-bootstrap/zig/lib/std/build.zig:509:9: 0x2d8f14 in makeOneStep (build)
        try s.make();
        ^
/home/gegogi/Projects/zig-bootstrap/zig/lib/std/build.zig:503:17: 0x2d8e82 in makeOneStep (build)
                return err;
                ^
/home/gegogi/Projects/zig-bootstrap/zig/lib/std/build.zig:464:13: 0x2d8be2 in make (build)
            try self.makeOneStep(s);
            ^
/home/gegogi/Projects/zig-bootstrap/zig/lib/build_runner.zig:223:21: 0x2dbb4a in main (build)
            else => return err,
                    ^
error: the following build command failed with exit code 1:
/home/gegogi/Projects/zig-bootstrap/zig/zig-cache/o/29e34052682bcb81a1f1e6d70048a4ae/build /home/gegogi/Projects/zig-bootstrap/out/build-zig-host/zig2 /home/gegogi/Projects/zig-bootstrap/zig /home/gegogi/Projects/zig-bootstrap/zig/zig-cache /home/gegogi/.cache/zig --zig-lib-dir /home/gegogi/Projects/zig-bootstrap/zig/lib -Dconfig_h=/home/gegogi/Projects/zig-bootstrap/out/build-zig-host/config.h -Denable-llvm -Denable-stage1 -Drelease -Dstrip -Dtarget=native -Dcpu=baseline -Dversion-string=0.11.0-dev.78+28288dcbb --prefix /home/gegogi/Projects/zig-bootstrap/out/host
::
:: ERROR: 1
:: (execute_process)
::
:: argv: /home/gegogi/Projects/zig-bootstrap/out/build-zig-host/zig2 build --zig-lib-dir /home/gegogi/Projects/zig-bootstrap/zig/lib -Dconfig_h=/home/gegogi/Projects/zig-bootstrap/out/build-zig-host/config.h -Denable-llvm -Denable-stage1 -Drelease -Dstrip -Dtarget=native -Dcpu=baseline -Dversion-string=0.11.0-dev.78+28288dcbb --prefix /home/gegogi/Projects/zig-bootstrap/out/host
::
:: argv[0]: /home/gegogi/Projects/zig-bootstrap/out/build-zig-host/zig2
:: argv[1]: build
:: argv[2]: --zig-lib-dir
:: argv[3]: /home/gegogi/Projects/zig-bootstrap/zig/lib
:: argv[4]: -Dconfig_h=/home/gegogi/Projects/zig-bootstrap/out/build-zig-host/config.h
:: argv[5]: -Denable-llvm
:: argv[6]: -Denable-stage1
:: argv[7]: -Drelease
:: argv[8]: -Dstrip
:: argv[9]: -Dtarget=native
:: argv[10]: -Dcpu=baseline
:: argv[11]: -Dversion-string=0.11.0-dev.78+28288dcbb
:: argv[12]: --prefix
:: argv[13]: /home/gegogi/Projects/zig-bootstrap/out/host
::
CMake Error at /home/gegogi/Projects/zig-bootstrap/zig/cmake/install.cmake:26 (message):
Call Stack (most recent call first):
  cmake_install.cmake:62 (include)


gmake: *** [Makefile:100: install] Error 1
(base) [gegogi@fedora zig-bootstrap]$ 

@matu3ba
Copy link

matu3ba commented Jan 25, 2023

@gegogi Can you try again with current master HEAD? I was able to compile Zig on ubuntu 20.04, so I this should also work.

@motiejus
Copy link
Contributor

motiejus commented Mar 18, 2023

Maybe related to http://github.com/ziglang/zig/issues/14815

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants