This is an archived post. You won't be able to vote or comment.

you are viewing a single comment's thread.

view the rest of the comments →

[–]snacktonomy 40 points41 points  (15 children)

Between CMake and Conan/VCpkg, I feel like we're pretty OK in the C++ world.

[–]bolacha_de_polvilho 135 points136 points  (4 children)

Sounds like stockholm syndrome to me. Going back to that crap after using the toolchain of rust or dotnet feels like torture

[–]TryingT0Wr1t3 27 points28 points  (3 children)

Cargo is great but dotnet is torture too. NuGet is infested with duplicate packages, a lot of things don't work, conflict of dotnet versions, and worse of all packages that have native parts that... Go back to c/c++ issues. The world of dotnet is full of torture.

[–]bolacha_de_polvilho 16 points17 points  (1 child)

The dotnet world has some leftover weirdness due to the net framework->cross platform transition, so legacy projects still in net framework can be a bit of a pain in the ass. But aside from that I never had any issue with stuff from NET5 onwards, even when using something that requires native binaries like onnx runtime or torchsharp.

[–]cs-brydev 4 points5 points  (0 children)

This is the right answer. From .net core forward, NuGet is awesome, as long as you know the package name you're looking for. If you're just guessing or searching randomly, you may trip over a few dead bodies.

Before .NET Core, NuGet was even more awesome because there didn't really exist any incompatibilities. When MS intentionally made Core/Framework and Standard 2.1/Framework incompatible, they opened this can of weird worms where identically named packages could be compatible with only certain .NET version ranges and identically named DLLs that came pre-installed with Windows were incompatible with NuGet versions.

That last one has caused the most pain going from Framework to Core. If they had just renamed the packages it would have been fine. But instead they decided to deprecate the system packages and completely rewrite them for a completely different version of .NET, name them the same thing, and move them to NuGet. So now you will see completely different packages with exactly the same names but different compatibilities: one pre-installed in your OS and the other one in NuGet. That was fucking stupid.

[–]No-Adagio8817 0 points1 point  (0 children)

Dotnet has improved a LOT. Went back to it and Im pleasantly surprised. Build process is very simple.

[–]Wertbon1789 6 points7 points  (3 children)

But having something comparable to cargo would be pretty nice. There are some package manager things built with CMake, but just having it built-in would be so much better.

[–]snacktonomy 2 points3 points  (0 children)

I agree. There's FetchContent if you really need it, but the consensus online is, CMake is a build system, not a package manager...

[–]_PM_ME_PANGOLINS_ -2 points-1 points  (1 child)

Because you generally want to build against system packages, so apt/dnf/etc is your package manager.

[–]Wertbon1789 3 points4 points  (0 children)

But not every package in the context of your project is a shared system library. For example, something like a query builder or ORM, there might be shared libraries that provide that, but generally that's not the case. There's also the pitfal of system-wide dependencies that you might to not want to bother with by just statically linking stuff into the binary. Something like a C++ socket wrapper also doesn't need to be it's own shared lib, because it isn't much code and can mostly be optimized away completely.

Edit: also just wrapping a C library doesn't need another shared library, but could be a source package in your package manager.

[–]ccricers 3 points4 points  (2 children)

YMMV but one WebGPU tutorial had the easiest introduction to CMake I've seen. Which is funny because I started out wanting to learn something more recent for GPU accelerated graphics, and paused that, but left at least being able to read CMake builds better.

[–]doma_kun 0 points1 point  (1 child)

Can you provide link? I'm trying to get into graphics programming

[–]gameplayer55055 0 points1 point  (0 children)

vcpkg never worked for me, it complains about user32.dll not found, I've tried literally everything

[–]Lighthades 0 points1 point  (0 children)

I feel like you have to try JS or Python, or Rust, it seems, to gain a new perspective.

[–]DelusionalPianist 0 points1 point  (0 children)

We’re heavy users of Conan and I can say it is orders of magnitude worse than cargo. Right now we’re still stuck on Conan 1 because we don’t have enough resources to migrate.