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

Building from source hangs indefinitely #449

Closed
brandonmaul opened this issue Feb 28, 2024 · 2 comments · Fixed by #450
Closed

Building from source hangs indefinitely #449

brandonmaul opened this issue Feb 28, 2024 · 2 comments · Fixed by #450
Labels
bug Something isn't working

Comments

@brandonmaul
Copy link
Contributor

Describe the bug

Attempting to build from source (via make install) hanged indefinitely. After compiling the build file swiftc ./scripts/build.swift it would run ./build and never exit.

To Reproduce

I was using a dev container, so this is pretty easy to reproduce.
Created a new dev container with Swift 5.9 selected from:
https://github.com/swift-server/swift-devcontainer-template

I believe I had to install make using apt, since the dev container didn't have it by default.

Attempted to install vapor toolbox as listed out by the docs:

git clone https://github.com/vapor/toolbox.git
cd toolbox
git checkout 18.7.4
make install

Expected behavior

The toolbox would build and install appropriately

Environment

Swift 5.9.2-RELEASE

  • Vapor Framework version: N/A
  • Vapor Toolbox version: 18.7.4
  • OS version: Derivative of Ubuntu:
    Distributor ID: Ubuntu
    Description: Ubuntu 22.04.3 LTS
    Release: 22.04
    Codename: jammy

Additional context

Add any other context about the problem here.

@brandonmaul brandonmaul added the bug Something isn't working label Feb 28, 2024
@gwynne
Copy link
Member

gwynne commented Feb 28, 2024

There is a known issue caused by the linker running out of memory which is the most common cause of this kind of problem; does your dev container have at least 2GiB of RAM allocated?

@brandonmaul
Copy link
Contributor Author

@gwynne The dev container had 4GB of RAM allocated at the time.

I fabricated a fix by modifying the /scripts/build.swift file. and opened it in PR #450

@0xTim 0xTim linked a pull request Mar 15, 2024 that will close this issue
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants