What is the name of libmount in NixOS?

Package 'mount', required by 'gio-2.0', not found
Package mount was not found in the pkg-config search path.
Perhaps you should add the directory containing `mount.pc'
to the PKG_CONFIG_PATH environment variable

I was searching nixpkgs for this library, but could not find it. Does anyone know the name of it?
Usually it’s known by the name of libmount-dev.

seems to be in util-linux:

~ % nix-locate /mount.pc
util-linux.dev                                      878 r /nix/store/mmzcs9aln1jcavkvzpngzj3798h8mpw5-util-linux-2.36.2-dev/lib/pkgconfig/mount.pc

Thanks a lot! This solved my problem. Also, I did not know about nix-locate utility. I think I’ll be using it a lot in the near future :grinning_face_with_smiling_eyes:

oh, note: nix-locate isn’t shipped with nixos, it’s provided by the nix-index package. :slight_smile:


No problem, when the utility is not found, Nix is helpful enough to print a command to get it, which was nix-shell -p nix-index in my case.

Which indeed is driven by nix-locate, but sadly neither its database nor the CLI are directly accessible unless you know where to find it…

Is there a similar utility, but for finding packages by C symbols they expose? For example, I have libepoxy.dev installed, but I’m still missing symbols, such as epoxy_eglDestroyContext. Or should I just find the C library with these through search engine and use nix-locate to find the name of that library on NixOS?

1 Like