• Re: ?The end of software secrecy is almost upon us?

    From Lawrence D?Oliveiro@3:633/10 to All on Sat Oct 24 03:39:07 2026
    On Fri, 23 Oct 2026 16:58:04 -0700, Chris M. Thomasson wrote:

    On 10/23/2026 3:46 PM, Lawrence D?Oliveiro wrote:

    On Fri, 23 Oct 2026 12:55:02 -0700, Chris M. Thomasson wrote:

    Fwiw, vcpkg has a lot of them, ready to automatically build and
    integrate. vcpkg is actually... Well, its pretty nice and so
    far... Seems to work for me.

    How does it work for end-users? Are your dependencies automatically
    brought in when they install your package? How are they kept
    up-to-date?

    Oh yeah. In your build directory, say Debug or Release, it has all
    of the built shared libs and everything you need to run it.

    Keeping them up to date is, afaict, manual.

    In the Linux world, we have ?development? packages versus ?runtime?
    packages.

    The development package contains the source includes, pkg-config info etc.
    The runtime version includes the actual shared library. So your built package has a dependency on the latter; when a user tries to install your package,
    it should automatically pull in the latter as necessary.

    Example from my system:

    lrwxrwxrwx 1 root root 13 Apr 24 2026 /usr/lib/x86_64-linux-gnu/libcairo.so -> libcairo.so.2
    lrwxrwxrwx 1 root root 21 Apr 24 2026 /usr/lib/x86_64-linux-gnu/libcairo.so.2 -> libcairo.so.2.11804.4
    -rw-r--r-- 1 root root 1366728 Apr 24 2026 /usr/lib/x86_64-linux-gnu/libcairo.so.2.11804.4

    Where did these come from?

    root@theon:~ # dpkg-query -S /usr/lib/x86_64-linux-gnu/libcairo.so.2
    libcairo2:amd64: /usr/lib/x86_64-linux-gnu/libcairo.so.2

    root@theon:~ # dpkg-query -S /usr/lib/x86_64-linux-gnu/libcairo.so
    libcairo2-dev:amd64: /usr/lib/x86_64-linux-gnu/libcairo.so

    Notice how the development library is not versioned, but is just a
    symlink to a versioned library.

    The runtime library is always versioned. This allows multiple versions
    of the library to be present at once, with some older packages, that haven?t been rebuilt, still depending on an older version, while up-to-date packages make use of the newer version.

    --- PyGate Linux v1.5.19
    * Origin: Dragon's Lair, PyGate NNTP<>Fido Gate (3:633/10)
  • From Lawrence D?Oliveiro@3:633/10 to All on Sat Oct 24 03:44:58 2026
    On Fri, 23 Oct 2026 23:31:41 GMT, Charlie Gibbs wrote:

    On 2026-10-23, Lawrence D?Oliveiro <ldo@nz.invalid> wrote:

    What was that error message? I was expecting something like ?DISK
    ERROR? or ?I/O ERROR?. Instead, it said

    I?m having trouble with the disk.

    The idea of an error message phrased in plain, approachable
    language (using a first-person pronoun, even) instead of technical
    terms?? That was a revelation.

    Unfortunately it's not the kind of revelation I welcome. Back in my
    mainframe days, I learned to hate catch-all error messages; they're
    the sign of a programmer who's too lazy to try to help the user. If
    something goes wrong, I want to be given some clues as to where to
    look. But more and more these days, your typical error message is
    "Something went wrong." Nothing more. This kind of conduct should be condemned.

    This was not like that though, was it? On systems of that era, you
    would typically get something like ?DISK ERROR? or ?I/O ERROR?. The plain-language message was no less specific than that.

    Do you want more detail about what went wrong? Perhaps a CRC
    validation failure? Sector-addressing failure? Missing address/data
    marks? Invalid GCR/RLL encoding?

    That kind of low-level detail might be helpful to somebody (perhaps a
    hardware engineer) trying to fix the problem. And perhaps it should
    appear in a system log somewhere.

    And it wouldn?t have mattered much in this case, anyway, since it
    would have been obvious to anybody? sitting or standing in front of the machine, that the most likely cause was the fact that there was no
    disk in the drive.

    ?Anybody who had made much use of floppy disks on micros, anyway.

    --- PyGate Linux v1.5.19
    * Origin: Dragon's Lair, PyGate NNTP<>Fido Gate (3:633/10)
  • From Chris M. Thomasson@3:633/10 to All on Sat Oct 24 13:04:38 2026
    On 10/23/2026 8:44 PM, Lawrence D?Oliveiro wrote:
    On Fri, 23 Oct 2026 23:31:41 GMT, Charlie Gibbs wrote:

    On 2026-10-23, Lawrence D?Oliveiro <ldo@nz.invalid> wrote:

    What was that error message? I was expecting something like ?DISK
    ERROR? or ?I/O ERROR?. Instead, it said

    I?m having trouble with the disk.

    The idea of an error message phrased in plain, approachable
    language (using a first-person pronoun, even) instead of technical
    terms?? That was a revelation.

    Unfortunately it's not the kind of revelation I welcome. Back in my
    mainframe days, I learned to hate catch-all error messages; they're
    the sign of a programmer who's too lazy to try to help the user. If
    something goes wrong, I want to be given some clues as to where to
    look. But more and more these days, your typical error message is
    "Something went wrong." Nothing more. This kind of conduct should be
    condemned.

    This was not like that though, was it? On systems of that era, you
    would typically get something like ?DISK ERROR? or ?I/O ERROR?. The plain-language message was no less specific than that.

    Do you want more detail about what went wrong? Perhaps a CRC
    validation failure? Sector-addressing failure? Missing address/data
    marks? Invalid GCR/RLL encoding?

    That kind of low-level detail might be helpful to somebody (perhaps a hardware engineer) trying to fix the problem. And perhaps it should
    appear in a system log somewhere.

    And it wouldn?t have mattered much in this case, anyway, since it
    would have been obvious to anybody? sitting or standing in front of the machine, that the most likely cause was the fact that there was no
    disk in the drive.

    ?Anybody who had made much use of floppy disks on micros, anyway.

    Iirc, BASIC had a fun error. I cannot remember the damn exact phrase, it
    was something like expression too complex or something.

    --- PyGate Linux v1.5.19
    * Origin: Dragon's Lair, PyGate NNTP<>Fido Gate (3:633/10)
  • From Charlie Gibbs@3:633/10 to All on Sat Oct 24 21:38:42 2026
    On 2026-10-24, Chris M. Thomasson <chris.m.thomasson.1@gmail.com> wrote:

    On 10/23/2026 8:44 PM, Lawrence D?Oliveiro wrote:

    On Fri, 23 Oct 2026 23:31:41 GMT, Charlie Gibbs wrote:

    On 2026-10-23, Lawrence D?Oliveiro <ldo@nz.invalid> wrote:

    What was that error message? I was expecting something like ?DISK
    ERROR? or ?I/O ERROR?. Instead, it said

    I?m having trouble with the disk.

    The idea of an error message phrased in plain, approachable
    language (using a first-person pronoun, even) instead of technical
    terms?? That was a revelation.

    Unfortunately it's not the kind of revelation I welcome. Back in my
    mainframe days, I learned to hate catch-all error messages; they're
    the sign of a programmer who's too lazy to try to help the user. If
    something goes wrong, I want to be given some clues as to where to
    look. But more and more these days, your typical error message is
    "Something went wrong." Nothing more. This kind of conduct should be
    condemned.

    This was not like that though, was it? On systems of that era, you
    would typically get something like ?DISK ERROR? or ?I/O ERROR?. The
    plain-language message was no less specific than that.

    Do you want more detail about what went wrong? Perhaps a CRC
    validation failure? Sector-addressing failure? Missing address/data
    marks? Invalid GCR/RLL encoding?

    That kind of low-level detail might be helpful to somebody (perhaps a
    hardware engineer) trying to fix the problem. And perhaps it should
    appear in a system log somewhere.

    And it wouldn?t have mattered much in this case, anyway, since it
    would have been obvious to anybody? sitting or standing in front of the
    machine, that the most likely cause was the fact that there was no
    disk in the drive.

    ?Anybody who had made much use of floppy disks on micros, anyway.

    Iirc, BASIC had a fun error. I cannot remember the damn exact phrase, it
    was something like expression too complex or something.

    "Who is General Failure and why is he reading my disk?"

    --
    /~\ Charlie Gibbs | In this world there are
    \ / <cgibbs@kltpzyxm.invalid> | two kinds of people:
    X I'm really at ac.dekanfrus | 1. Those who can extrapolate
    / \ if you read it the right way. | from incomplete data.

    --- PyGate Linux v1.5.19
    * Origin: Dragon's Lair, PyGate NNTP<>Fido Gate (3:633/10)
  • From Lawrence D?Oliveiro@3:633/10 to All on Mon Oct 26 21:59:06 2026
    On Mon, 26 Oct 2026 13:03:25 -0700, Chris M. Thomasson wrote:

    Shared state? Just use memory mapped files. You don't need
    pipes/sockets etc. You need to know how to properly sync things.

    Like it or not, the Unix-type model is the closest we have to a
    standard set of OS APIs. It?s the only one that starts from an
    official spec, namely POSIX.

    At one point, Sun did spearhead a campaign to standardize Microsoft
    Windows, believe it or not
    <https://www.youtube.com/watch?v=H5v0CK249rI> -- but of course
    Microsoft successfully stymied that effort.

    And as a result of all that past market strategizing, nowadays we have
    a multi-decade-long accumulation of Free software that assumes that
    basic Unix-type set of APIs, and nothing else is able to come close.
    So that is what we expect to have when we start new projects or keep
    existing ones going, because nobody wants to reinvent the wheel when
    they can build on all the high-quality work that has gone before.

    Like it or not, the Unix model has conquered the world.

    --- PyGate Linux v1.5.19
    * Origin: Dragon's Lair, PyGate NNTP<>Fido Gate (3:633/10)
  • From Chris M. Thomasson@3:633/10 to All on Mon Oct 26 19:43:04 2026
    On 10/24/2026 2:38 PM, Charlie Gibbs wrote:
    On 2026-10-24, Chris M. Thomasson <chris.m.thomasson.1@gmail.com> wrote:

    On 10/23/2026 8:44 PM, Lawrence D?Oliveiro wrote:

    On Fri, 23 Oct 2026 23:31:41 GMT, Charlie Gibbs wrote:

    On 2026-10-23, Lawrence D?Oliveiro <ldo@nz.invalid> wrote:

    What was that error message? I was expecting something like ?DISK
    ERROR? or ?I/O ERROR?. Instead, it said

    I?m having trouble with the disk.

    The idea of an error message phrased in plain, approachable
    language (using a first-person pronoun, even) instead of technical
    terms?? That was a revelation.

    Unfortunately it's not the kind of revelation I welcome. Back in my
    mainframe days, I learned to hate catch-all error messages; they're
    the sign of a programmer who's too lazy to try to help the user. If
    something goes wrong, I want to be given some clues as to where to
    look. But more and more these days, your typical error message is
    "Something went wrong." Nothing more. This kind of conduct should be
    condemned.

    This was not like that though, was it? On systems of that era, you
    would typically get something like ?DISK ERROR? or ?I/O ERROR?. The
    plain-language message was no less specific than that.

    Do you want more detail about what went wrong? Perhaps a CRC
    validation failure? Sector-addressing failure? Missing address/data
    marks? Invalid GCR/RLL encoding?

    That kind of low-level detail might be helpful to somebody (perhaps a
    hardware engineer) trying to fix the problem. And perhaps it should
    appear in a system log somewhere.

    And it wouldn?t have mattered much in this case, anyway, since it
    would have been obvious to anybody? sitting or standing in front of the
    machine, that the most likely cause was the fact that there was no
    disk in the drive.

    ?Anybody who had made much use of floppy disks on micros, anyway.

    Iirc, BASIC had a fun error. I cannot remember the damn exact phrase, it
    was something like expression too complex or something.

    "Who is General Failure and why is he reading my disk?"


    :^() Basically. The BASIC was about too complex, and it was a little odd
    to me.

    --- PyGate Linux v1.5.19
    * Origin: Dragon's Lair, PyGate NNTP<>Fido Gate (3:633/10)
  • From Chris M. Thomasson@3:633/10 to All on Mon Oct 26 19:51:23 2026
    On 10/23/2026 8:39 PM, Lawrence D?Oliveiro wrote:
    [...]

    I was in the linux world for a whiel, along with solaris, etc. But
    Windows, oh my. vcpkg is a big turn.

    --- PyGate Linux v1.5.19
    * Origin: Dragon's Lair, PyGate NNTP<>Fido Gate (3:633/10)
  • From Lawrence D?Oliveiro@3:633/10 to All on Tue Oct 27 05:56:28 2026
    On Mon, 26 Oct 2026 19:51:23 -0700, Chris M. Thomasson wrote:

    On 10/23/2026 8:39 PM, Lawrence D?Oliveiro wrote:

    On Fri, 23 Oct 2026 16:58:04 -0700, Chris M. Thomasson wrote:

    Keeping them up to date is, afaict, manual.

    In the Linux world, we have ?development? packages versus ?runtime?
    packages.

    The development package contains the source includes, pkg-config
    info etc. The runtime version includes the actual shared library.
    So your built package has a dependency on the latter; when a user
    tries to install your package, it should automatically pull in the
    latter as necessary.

    Example from my system:

    lrwxrwxrwx 1 root root 13 Apr 24 2026 /usr/lib/x86_64-linux-gnu/libcairo.so -> libcairo.so.2
    lrwxrwxrwx 1 root root 21 Apr 24 2026 /usr/lib/x86_64-linux-gnu/libcairo.so.2 -> libcairo.so.2.11804.4
    -rw-r--r-- 1 root root 1366728 Apr 24 2026 /usr/lib/x86_64-linux-gnu/libcairo.so.2.11804.4

    Where did these come from?

    root@theon:~ # dpkg-query -S /usr/lib/x86_64-linux-gnu/libcairo.so.2
    libcairo2:amd64: /usr/lib/x86_64-linux-gnu/libcairo.so.2

    root@theon:~ # dpkg-query -S /usr/lib/x86_64-linux-gnu/libcairo.so
    libcairo2-dev:amd64: /usr/lib/x86_64-linux-gnu/libcairo.so

    Notice how the development library is not versioned, but is just a
    symlink to a versioned library.

    The runtime library is always versioned. This allows multiple
    versions of the library to be present at once, with some older
    packages, that haven?t been rebuilt, still depending on an older
    version, while up-to-date packages make use of the newer version.

    I was in the linux world for a whiel, along with solaris, etc. But
    Windows, oh my. vcpkg is a big turn.

    Windows isn?t even in the same league, is it.

    --- PyGate Linux v1.5.19
    * Origin: Dragon's Lair, PyGate NNTP<>Fido Gate (3:633/10)
  • From Lawrence D?Oliveiro@3:633/10 to All on Fri Oct 30 22:35:05 2026
    On Fri, 30 Oct 2026 20:37:14 +0100, Jeroen Belleman wrote:

    That's where threads are useful: The GUI is one thread, and the
    "other things" are in one or more other threads. There are
    altogether too many programs that hang the GUI while "other things"
    are going on. That should never happen!

    Back in the 1990s, threading was seen as the answer to everything.
    Some even tried multithreaded GUIs.

    The trouble with threading is its ?default-shared-everything? model,
    as opposed to separate processes, which are ?default-shared-nothing?.
    It is all too easy to forget to synchronize access to shared objects,
    lock things properly etc, and end up with hard-to-diagnose bugs that
    tend to hide themselves when you try to go look for them (see
    ?Heisenbug?).

    The trend nowadays is to revive the old coroutine concept, in a new
    guise called ?stackless? coroutines. These give you support for async operations, but with transfers of control being made explicit at
    ?await? points, rather than unpredictably as with full preemptive
    threading. This greatly reduces the opportunity for race conditions.

    Credit to Microsoft for pioneering this, but nowadays you see the idea
    popping up in JavaScript and Python and who knows where else.

    Threading is still definitely useful, mainly for performance, where
    the bottleneck is in CPU usage. But if a program is spending most of
    its time waiting for I/O over the network, or for a user to initiate a
    GUI action, or something external and relatively slow like that, then coroutines keep things simpler.

    --- PyGate Linux v1.5.19
    * Origin: Dragon's Lair, PyGate NNTP<>Fido Gate (3:633/10)
  • From Charlie Gibbs@3:633/10 to All on Sat Oct 31 04:14:05 2026
    On 2026-10-30, Lawrence D?Oliveiro <ldo@nz.invalid> wrote:

    Threading is still definitely useful, mainly for performance, where
    the bottleneck is in CPU usage. But if a program is spending most of
    its time waiting for I/O over the network, or for a user to initiate a
    GUI action, or something external and relatively slow like that, then coroutines keep things simpler.

    I've always tried to avoid the complexities of threading; in most cases
    I can get away with round-robin scheduling. But I found that some servers
    are very slow to respond, and even when trying to do a non-blocking setup
    of a TCP/IP connection, the connect() API would unavoidably block. I had
    to spin that part off into its own thread to keep the rest of the program (including other connections) from hanging.

    --
    /~\ Charlie Gibbs | In this world there are
    \ / <cgibbs@kltpzyxm.invalid> | two kinds of people:
    X I'm really at ac.dekanfrus | 1. Those who can extrapolate
    / \ if you read it the right way. | from incomplete data.

    --- PyGate Linux v1.5.19
    * Origin: Dragon's Lair, PyGate NNTP<>Fido Gate (3:633/10)
  • From Lawrence D?Oliveiro@3:633/10 to All on Sat Oct 31 05:37:23 2026
    On Sat, 31 Oct 2026 04:14:05 GMT, Charlie Gibbs wrote:

    I've always tried to avoid the complexities of threading; in most
    cases I can get away with round-robin scheduling. But I found that
    some servers are very slow to respond, and even when trying to do a non-blocking setup of a TCP/IP connection, the connect() API would unavoidably block. I had to spin that part off into its own thread
    to keep the rest of the program (including other connections) from
    hanging.

    Here?s a fun little thing: if you set a socket to nonblocking and then
    do the connect(2) call, it will seemingly fail with an EINPROGRESS
    error. But in fact, the connection attempt gets initiated, and you can
    monitor its subsequent progress from your event loop.

    From the ERRORS section of <https://manpages.debian.org/connect(2)>:

    EINPROGRESS
    The socket is nonblocking and the connection cannot be
    completed immediately. (UNIX domain sockets failed with EAGAIN
    instead.) It is possible to select(2) or poll(2) for
    completion by selecting the socket for writing. After
    select(2) indicates writability, use getsockopt(2) to read the
    SO_ERROR option at level SOL_SOCKET to determine whether
    connect() completed successfully (SO_ERROR is zero) or
    unsuccessfully (SO_ERROR is one of the usual error codes
    listed here, explaining the reason for the failure).

    I?m not sure about doing this sort of thing from other libraries that
    wrap socket connections (e.g. SSL/TLS libraries); for these, the usual
    fallback is still available, as you say, by turning a blocking call
    into a nonblocking one by pushing it off to a separate thread.

    --- PyGate Linux v1.5.19
    * Origin: Dragon's Lair, PyGate NNTP<>Fido Gate (3:633/10)