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

linux_testing_bcachefs: 4.15.2018.02.09 -> 4.15.2018.03.22 #37905

Merged
merged 2 commits into from Mar 27, 2018
Merged

linux_testing_bcachefs: 4.15.2018.02.09 -> 4.15.2018.03.22 #37905

merged 2 commits into from Mar 27, 2018

Conversation

Chiiruno
Copy link
Contributor

@Chiiruno Chiiruno commented Mar 27, 2018

Motivation for this change

zstd was added in a recent commit.
Further improvements to bcachefs, I find more frequent updates to this in particular is good since it's a rapidly developing project.
I hope it was alright to add myself as a maintainer to these two packages, since I'd like to maintain.

Things done
  • Tested using sandboxing (nix.useSandbox on NixOS, or option build-use-sandbox in nix.conf on non-NixOS)
  • Built on platform(s)
    • NixOS
    • macOS
    • other Linux distributions
  • Tested via one or more NixOS test(s) if existing and applicable for the change (look inside nixos/tests)
  • Tested compilation of all pkgs that depend on this change using nix-shell -p nox --run "nox-review wip"
  • Tested execution of all binary files (usually in ./result/bin/)
  • Fits CONTRIBUTING.md.

else
ROOT_SBINDIR=$(PREFIX)/sbin
- INITRAMFS_DIR=/etc/initramfs-tools
+ INITRAMFS_DIR=$(PREFIX)/etc/initramfs-tools
Copy link
Contributor

Choose a reason for hiding this comment

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

What is this for? Is this configuration really meant to be read-only?

Copy link
Contributor Author

@Chiiruno Chiiruno Mar 27, 2018

Choose a reason for hiding this comment

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

It wouldn't finish the make install command without it.
The path there is absolute, and assumed a normal linux installation, not something like NixOS.
Recently upstream added some initramfs stuff, so that's what that's about.

Copy link
Contributor

Choose a reason for hiding this comment

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

I'm guessing it's trying to create that path, which is of course bad. I wonder why, we should open an issue.

It is odd, since he even has a branch with nix support :) https://evilpiepirate.org/git/bcachefs-tools.git/commit/?h=dev

In the meantime, I'll merge, thanks!

@wmertens
Copy link
Contributor

Other than explaining that /etc change it looks good. I'm also very interested in bcachefs :)

@wmertens wmertens merged commit 4ba76fa into NixOS:master Mar 27, 2018
@wmertens
Copy link
Contributor

wmertens commented Mar 27, 2018

I wrote Kent about this, he replied:

The reason the makefile isn't using prefix for the initramfs dir is 
the initramfs tools don't check /usr/local/etc for scripts/hooks. I 
don't know what their reasoning for that is or if it's intentional, 
though. 

It does sound like the nix expression should be using DESTDIR and not 
PREFIX, if I follow you... and I am happy to pull whatever is needed 
for nix, as long as it doesn't break building the debian package 

On Tue, Mar 27, 2018 at 8:20 AM, Wout Mertens <wout.mertens@gmail.com> wrote: 
> Hi Kent, 
> 
> Please see https://github.com/NixOS/nixpkgs/pull/37905, what is happening is 
> that the Makefile is writing to /etc, because DESTDIR is unset but PREFIX is 
> set to the Nix output path. That latter is done so everything uses the full 
> path to the binary. 
> 
> Since I saw that you have nix expressions in the repo, I figured that maybe 
> you wanted to make sure it can build correctly without patches. Maybe the 
> right answer is that the build should be using DESTDIR, which would work if 
> the tools don't hardcode any paths? 

@Chiiruno so maybe we should be trying to use DESTDIR instead of PREFIX, but only if the code doesn't try to exec anything with a path.

Also, we should check what the initramfs file is that is put there, if it is needed we would need to have this file on NixOS. OTOH, I'm not sure that we use initramfstools?

Maybe we should add a makefile flag to just skip that whole part if it's not used on NixOS, but then if someone is using Nix on Debian they might need that.

What do you think?

@Chiiruno
Copy link
Contributor Author

Chiiruno commented Mar 28, 2018

@wmertens Probably a Makefile flag would be for the best.
I'm not too good with Make though, I usually use different build systems, so honestly I have no clue what to do.
IIRC the initramfs stuff is because he's planning on mainlining this into the Linux kernel relatively soon.

Is changing
INITRAMFS_DIR=$(PREFIX)/etc/initramfs-tools
to
INITRAMFS_DIR=$(DESTDIR)/etc/initramfs-tools
what you mean?

@Mic92
Copy link
Member

Mic92 commented Aug 5, 2018

bcachefs probably could need another update before the next release.

@Chiiruno
Copy link
Contributor Author

Chiiruno commented Aug 5, 2018

@Mic92 You mean before the next NixOS release?

@Mic92
Copy link
Member

Mic92 commented Aug 6, 2018

yes

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

Successfully merging this pull request may close these issues.

None yet

5 participants