Well they're not. Maybe they should be but they're not.
In JavaScript, NPM is a package manager. Build systems (Vite, Webpack, Browserify, ...) are separate.
In C++, we have vcpkg and Conan. Both are package managers, neither are build systems. I haven't used vcpkg but at least Conan integrates with Meson, CMake and other build systems.
A good build system (i.e not Make) has a clean concept of what a "package" is and how the dependencies between "packages" work. But a build system does not need to know how to download packages, it just needs to know what to do about them once it's pointed at a package. The problem with Conan is that it has to support a bunch of different build systems, so the definition of what a "package" is gets muddied.
Well they're not. Maybe they should be but they're not.
In JavaScript, NPM is a package manager. Build systems (Vite, Webpack, Browserify, ...) are separate.
In C++, we have vcpkg and Conan. Both are package managers, neither are build systems. I haven't used vcpkg but at least Conan integrates with Meson, CMake and other build systems.
A good build system (i.e not Make) has a clean concept of what a "package" is and how the dependencies between "packages" work. But a build system does not need to know how to download packages, it just needs to know what to do about them once it's pointed at a package. The problem with Conan is that it has to support a bunch of different build systems, so the definition of what a "package" is gets muddied.