⸻ Ban DHMO 🇦🇺 ⸻

  • 12 Posts
  • 249 Comments
Joined 1 year ago
cake
Cake day: June 13th, 2023

help-circle



  • I’ve worked it out, thanks for the responses, maybe I didn’t word the question properly or something, but here’s what I did for anyone interested in the future:

    You only need to do this once for every machine you want to work on.

    Add the llvm freedesktop sdk extensions to get a clangd executable to your flatpak manifest:

    "sdk-extensions": [
            "org.freedesktop.Sdk.Extension.llvm18"
        ],
    

    Install these extensions:

    • Native Debug
    • Flatpak
    • Meson Build
    • clangd (optional)

    Run the Flatpak: Build command in the command palette (Ctrl+Shift+P) this might take a minute. Make sure you have the required sdks installed (see the manifest for details).

    There should now be two folders: .flatpak and _build. There should also be a script generated at .flatpak/meson.sh. Run:

    python gen-flatpak-scripts.py
    

    This will generate .flatpak/gdb.sh and .flatpak/clangd.sh. If you want to use the clangd vscode extension extension add this to .vscode/settings.json:

    "clangd.path": "./.flatpak/clangd.sh"
    

    Now run the clangd: Restart language server command in the command palette (Ctrl+Shift+P) and you should be good to go!

    gen-flatpak-scripts.py:

    # Simple script to generate scripts to make life easy when using flatpak with vscode
    
    import subprocess;
    
    def gen_script(outfile, exec):
        with open(".flatpak/meson.sh", "rt") as fin:
            with open(outfile, "wt") as fout:
                for line in fin:
                    fout.write(line.replace("/usr/bin/meson", exec))
        subprocess.run(["chmod", "+x", outfile])
    
    # GDB for debugging
    gen_script(".flatpak/gdb.sh", "/usr/bin/gdb")
    # clangd for suggestions
    gen_script(".flatpak/clangd.sh", "/usr/lib/sdk/llvm18/bin/clangd")
    














  • It really depends alot on the situation, I do agree however, when you compare Open Source and Free Software, Open Source seems to be designed to be exploitative which is why it is supported by large companies. As you said the AGPL is really the only way to go as it means you get access to every modification a large company makes to your software, which is why the Linux kernel (albeit GPLv2, which is also a good copyleft license) has become such a big project, running on the phone I’m typing this on and the servers our Lemmy instances are on.

    It’s probably not the answer to everything and FUTO are trying to fix this (probably the wrong way though) but AGPL is really the best license to avoid exploitation, that way if they use it, you get in return more source code.


  • I wouldn’t recommend watching it, but the central argument of this video is to do with software support. They argue that “open source” was more relevant prior to the internet (in servers?) due to the long turnaround time in getting a software vender (in this video IBM) to fix a bug in their software, arguing that by having access to the source code support could instruct the server maintainer what changes to make without them needing to send the tape to IBM to debug (apparently that was something they did, but it seems people in the video comments disagree with this hinting that the youtuber has no actual experience in this area). They argue that due to high speed internet support can release software fixes much quicker so having access to the source code isn’t useful as paying for support contracts is a better option for businesses rather than having people who understand the software they’re running. Apparently this is the only reason why open source is useful. They go on to argue that Linux is only popular on servers because RedHat’s support contracts are cheaper than Microsoft’s, something which I doubt and probably has more to do with the kernel and OS being easy to modify and control allowing it to be extended to a large variety of use cases instead of writing a new system from scratch.

    There’s lots of issues with their argument and some have claimed it is trolling but I reckon that would be giving them too much credit. It is likely they are just an idiot fanboying for their favourite companies desperately trying to justify their irrational biases