• Re: Bug#1064346: Source is missing errors on HTML source files

    From Wookey@21:1/5 to Shriram Ravindranathan on Thu Feb 22 14:10:01 2024
    On 2024-02-22 11:37 +0530, Shriram Ravindranathan wrote:
    Thank you Bastien,
    I tried doing this but it appears that the scripts to build these example files all depend on having the highlight binary itself installed on the machine. I am unsure whether it is okay to have the package depend on itself for building.

    Packages that use themselves to build are problematic for bootstrapping and cross-building.

    When cross-building you can't (usually) run the binaries just built
    because they are the wrong architecture.

    When bootstrapping packages that depend on themselves cause dependency
    loops which are a pain (we can't build foo because we don't have foo
    yet). We have 'build profiles' (older name 'staged builds') to deal
    with this. i.e you define a minimum 'stage1' build profile which does
    not have the circular dependency (and the normal build which does) so
    the building of the final version can be automated.

    The choices here are to
    1) use the binary just build during the build
    2) have a self dependency and use a packaged binary

    1) Is simple but prevents the package cross-building. Usually the best
    thing to do is just skip that part if cross-building (you can live without the examples)
    Just ensure that the build doesn't fail due to missing files.

    2) Works for cross-building (by the magic of multiarch) but you should
    add a stage notation so it can easily be built for new architectures,
    which is a bit of a faff.

    In case '2' you have to worry about version skew. How much does it
    matter if examples/whatever are built with the previous/an older
    version of the package? Case '1' avoids this. This is very specific to
    the package in question: sometimes it needs to be exactly the same,
    sometimes a version from a decade ago will be just fine. This is the
    main reason people usually pick option '1'.

    https://wiki.debian.org/BuildProfileSpec https://wiki.debian.org/DebianBootstrap https://wiki.debian.org/CrossBuildPackagingGuidelines

    All the above is quite a lot to take in, and you don't need to worry
    too much, but it is a good idea to at least have this stuff in the
    back of your mind when packaging. Ideally this would all work
    correctly on the whole archive, and packagers are the ones best-placed
    to stick in the necessary runes.

    Wookey
    --
    Principal hats: Debian, Wookware, ARM
    http://wookware.org/

    -----BEGIN PGP SIGNATURE-----

    iQIzBAABCgAdFiEER4nvI8Pe/wVWh5yq+4YyUahvnkcFAmXXRnoACgkQ+4YyUahv nkcu9xAAqy0q8YMQ73/V1KSu9bP6+oDvcfX9CDkOaDHrv2JBuxsi0P64BqhlDbnJ YxtsEnk27umVxBG/Oyoh74Bkci6hAQ8OQwNqO3kTqXMzlBtbDBqBzYXz+9OAxhKw yUhKzY05oWOHYFUI9b5pcOX7tltuLzAtc2i7PzlVGmUwB054t/h86O6309WM4fos S6+bq9oIK641QR2Ewhkvf7Ua1oFYYFX+3aUTJGnaOEdTnL+MeyXG4xT95wn8JuKt n9Qd+UEOBYyJrzdXW2bWch/Yn90M4RXCpsIKMHbK7eP9TyY6h8ryh2msl4HhoRfV yfRq3il6QMc8XYsSSvumEKGRerrEQJOQFl2gs7cAAJkNQc0q6Qp6u5DgsJrt5DLM ZasniXrq5MMTenn1a0UMAoOEwi18m7NGr+DjX7+Dj1+g5+nuY3IciKUG/vT2Y19r ZE93UM7Ca5UoPii3KStaqL0SZNQbOdUmSN5T1vCP+62dC59HgVB5FyyDAMdQ3VJp PBbsXRUF+1dsqw6jvASmGyHKozRh8EOEM9imAqVEe86vMREpFhs+4fSo4g+PfvCO 2sSbZSQ4Sxzg/STZ/HUsAjz+KWXcUoEFQEVZiiVrBsE8IbR8qWOjFsyGmjBo1YhX JhX330rf/z8W3X+qLHX3SS+qPB1gKOafldmV3mdDyZkxCeYYwfA=
    =w/l+
    -----END PGP SIGNATURE-----

    --- SoupGate-Win32 v1.05
    * Origin: fsxNet Usenet Gateway (21:1/5)