Skip to content

Use buildprefix in a few more places#9465

Merged
edolstra merged 1 commit intoNixOS:masterfrom
obsidiansystems:build-dir
Nov 30, 2023
Merged

Use buildprefix in a few more places#9465
edolstra merged 1 commit intoNixOS:masterfrom
obsidiansystems:build-dir

Conversation

@Ericson2314
Copy link
Member

Motivation

installcheck doesn't yet work, but the rest of the build can now happen mostly inside a separate build directory.

Context

Progress on #9342

Priorities

Add 👍 to pull requests you find important.

@github-actions github-actions bot added the with-tests Issues related to testing. PRs with tests have some priority label Nov 27, 2023
Copy link
Contributor

@fricklerhandwerk fricklerhandwerk left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

What a natural thing to have and do, one would think.

clean-files += Makefile.config
include mk/directories.mk

-include $(buildprefix)Makefile.config
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This seems circular. E.g. prefix is set in Makefile.config and mk/directories.mk depends on the value of prefix, so Makefile.config needs to be included before mk/directories.mk.

Maybe only the setting of buildprefix should be moved to before -include $(buildprefix)Makefile.config?

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think it worked because the way non-:= definitions are "lazy", but I do prefer your way because it is easier to understand. Done!

`installcheck` doesn't yet work, but the rest of the build can now
happen mostly inside a separate build directory.

Progress on NixOS#9342

Co-authored-by: Valentin Gagarin <valentin.gagarin@tweag.io>
@edolstra edolstra merged commit b6a3fde into NixOS:master Nov 30, 2023
@Ericson2314 Ericson2314 deleted the build-dir branch November 30, 2023 14:30
tebowy pushed a commit to tebowy/nix that referenced this pull request Jul 11, 2024
Use `buildprefix` in a few more places

(cherry picked from commit b6a3fde)
Change-Id: I2790663fa9f8242ac2db6582b7e421d2fdf42942
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

with-tests Issues related to testing. PRs with tests have some priority

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants