News for hackers. Stuff that matters.
Re:C Macro Reflection in Zig – Zig Has Better C Interop Than... by bluGill on Tuesday July 30, 2024 @09:22AM (#41108921)
> With hindsight, it is strange that the C community, with all the people and money behind it (and what scale!) never even managed to build a proper packaging manager (okay, there's now Conan, but that came from Python guys).

Package managers are a lot more complex than people realize. Every attempt I've seen in every language has significant lacks for common real world cases.

Most commonly they assume all the world is their language. Very commonly they want to take over all package management but don't have a good easy story for working with the OS package manager (I know Windows doesn't really have a package manager - but you still need to interoperate with it!). Those are big issues anyone in a complex project will face in the real world, there are also lots of little warts that will bite you.

Yes package managers are nice on your trival project. However they all get in the way in your non-complex project - some more than others.

Re:C Macro Reflection in Zig – Zig Has Better C Interop Than... by Joker_vD on Tuesday July 30, 2024 @10:48AM (#41109697)
Why would anyone want to integrate with the OS package manager? Windows, as you've said yourself, doesn't even have one (and thank goodness for that) while on Linux, the distributed packages are normally about 2 to 4 years out of date — unless you discover and use specific 3rd-party repositories at which point what's even the point then? Just use the language's CPAN/PyPI/Hex/Crates.io/etc. analogue.
Re:C Macro Reflection in Zig – Zig Has Better C Interop Than... by bluGill on Tuesday July 30, 2024 @10:55AM (#41109767)
> Why would anyone want to integrate with the OS package manage

Because if they don't integrate you end up with several different versions of the same package installed. When you program grabs the wrong version how do you fix it. Now what if you are in support trying to help a customer.

> on Linux, the distributed packages are normally about 2 to 4 years out of date

Maybe you need to find a different distribution. Some make it a point to be out of date. Some make it a point to be up to date.

Re:C Macro Reflection in Zig – Zig Has Better C Interop Than... by kitkat_new on Tuesday July 30, 2024 @08:08PM (#41115310)
Windows has winget
Re:C Macro Reflection in Zig – Zig Has Better C Interop Than... by greenavocado on Tuesday July 30, 2024 @10:04AM (#41109328)
Weird take. Does pip have to interface with the Windows or iOS package managers? No. Yet it's wildly successful.
Re:C Macro Reflection in Zig – Zig Has Better C Interop Than... by jordanozang on Tuesday July 30, 2024 @10:59AM (#41109814)
If you use pip without protection, it will gladly and malevolently mess up your system. Every Python user learns quickly about the virtual environment work around. Various distributions (e.g. through Homebrew on Os X, Arch Linux, Ubuntu Linux) ship pip without the ability to make system-wide installations (externally-managed-environment). Even on Windows, where there is no standardized package management system, doing a pip install will place a bunch of dlls in the system's PATH that could get in the way of any program on your system.

The anti-solution of ignoring the problem is what got us here.

Re:C Macro Reflection in Zig – Zig Has Better C Interop Than... by bluGill on Tuesday July 30, 2024 @10:52AM (#41109725)
> Does pip have to interface with the Windows or iOS package managers? No. Yet it's wildly successful.

Successful I agree. I have issues on any system I use it on because now I have the package installed by PIP and the package installed by my OS package manager - slightly different.