Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > comp.unix.shell > #22504

Re: [ANN] KornShell 93u+m 1.0.0-beta.2

From Martijn Dekker <martijn@inlv.demon.nl>
Newsgroups comp.unix.shell
Subject Re: [ANN] KornShell 93u+m 1.0.0-beta.2
Date 2021-12-19 21:00 +0000
Message-ID <j29kr4Fsq85U1@mid.individual.net> (permalink)
References <j22f1cFh5m2U1@mid.individual.net> <spkpus$8ru$1@dont-email.me>

Show all headers | View raw


Op 18-12-21 om 14:07 schreef Janis Papanagnou:
> On 17.12.2021 04:38, Martijn Dekker wrote:
>> Announcing: KornShell 93u+m 1.0.0-beta.2
>> https://github.com/ksh93/ksh
>> [...]
>> Please download the source code tarball from our GitHub releases page:
>>
>>      https://github.com/ksh93/ksh/releases
>>
>> To build, follow the instructions in README.md or src/cmd/ksh93/README.
> 
> I tried a build of the shell, and after a long seamless running compile
> got an error. (I seem to recall that I detected it already in a previous
> release.)

Sorry, I'd forgotten about that.

> Note: in the logs below I replaced the actual top level directory by ~ .
> 
> + ~/ksh/arch/linux.i386-64/bin/ar x -lsum sumlib.o
> /usr/bin/ar: two different operation options specified
> mamake [lib/libcmd]: *** exit code 1 making sumlib.o
> mamake: *** exit code 1 making lib/libcmd
> mamake: *** exit code 1 making all
> 
> Got the usage info from the packaged ar (no idea where the -U thing
> comes from, and why a different path for ar is displayed)
> 
> ~/ksh/arch/linux.i386-64/bin/ar --help
> /usr/bin/ar: invalid option -- 'U'
> Usage: /usr/bin/ar [emulation options] [-]{dmpqrstx}[abcDfilMNoPsSTuvV]
> [--plugin <name>] [member-name] [count] archive-file file...
>         /usr/bin/ar -M [<mri-script]
[...]

The cause is probably this ar wrapper script:

     $ cat src/cmd/INIT/ar.linux.i386-64 

     : linux.i386-64 ar wrapper

     case $1 in
     *x*) /usr/bin/ar "$@" ;;
     *)   /usr/bin/ar U"$@" ;;
     esac

This gets copied into your package hierarchy as 
arch/linux.i386-64/bin/ar and put in $PATH.

If you delete the wrapper script in both places

     $ rm src/cmd/INIT/ar.linux.i386-64 arch/linux.i386-64/bin/ar

and then try 'bin/package make' again, does it build?

I have no idea what that U thing is for. The AT&T folks must have had 
some reason for adding it.

'man ar' on CentOS x86_64 documents:

        A number of modifiers (mod) may immediately follow the p
        keyletter, to specify variations on an operation's behavior:
[...]
        D   Operate in deterministic mode.  When adding files and the
            archive index use zero for UIDs, GIDs, timestamps, and use
            consistent file modes for all files.  When this option is
            used, if ar is used with identical options and identical
            input files, multiple runs will create identical output
            files regardless of the input files' owners, groups, file
            modes, or modification times.
[...]
        U   Do not operate in deterministic mode.  This is the inverse
            of the D modifier, above: added files and the archive index
            will get their actual UID, GID, timestamp, and file mode
            values.

            This is the default unless binutils was configured with
            --enable-deterministic-archives.

So the question is, why would we want to disable deterministic mode? It 
sounds like a good thing.

If you can confirm that deleting the wrapper script fixes your build 
failure, I'll get rid of it and see if anything breaks for anyone else.

(In fact in the long term I plan to get rid of all such wrapper scripts. 
It's a very flawed way of making a build work. Just overriding the 
default compiler or linker using the appropriate failures will disable 
the wrappers so the necessary flags aren't added. There are better ways 
of doing this.)

-- 
||    modernish -- harness the shell
||    https://github.com/modernish/modernish
||
||    KornShell lives!
||    https://github.com/ksh93/ksh

Back to comp.unix.shell | Previous | Next — Previous in thread | Next in thread | Find similar | Unroll thread


Thread

[ANN] KornShell 93u+m 1.0.0-beta.2 Martijn Dekker <martijn@inlv.demon.nl> - 2021-12-17 04:38 +0100
  Re: [ANN] KornShell 93u+m 1.0.0-beta.2 Janis Papanagnou <janis_papanagnou@hotmail.com> - 2021-12-17 09:43 +0100
    Re: [ANN] KornShell 93u+m 1.0.0-beta.2 Martijn Dekker <martijn@inlv.demon.nl> - 2021-12-17 11:18 +0100
      Re: [ANN] KornShell 93u+m 1.0.0-beta.2 Spiros Bousbouras <spibou@gmail.com> - 2021-12-17 12:50 +0000
        Arithmetic trivia (Was: [ANN] KornShell 93u+m 1.0.0-beta.2) gazelle@shell.xmission.com (Kenny McCormack) - 2021-12-17 13:10 +0000
          Re: Arithmetic trivia (Was: [ANN] KornShell 93u+m 1.0.0-beta.2) Janis Papanagnou <janis_papanagnou@hotmail.com> - 2021-12-17 21:39 +0100
        Re: [ANN] KornShell 93u+m 1.0.0-beta.2 Martijn Dekker <martijn@inlv.demon.nl> - 2021-12-17 19:58 +0000
  Re: [ANN] KornShell 93u+m 1.0.0-beta.2 Janis Papanagnou <janis_papanagnou@hotmail.com> - 2021-12-18 15:07 +0100
    Re: [ANN] KornShell 93u+m 1.0.0-beta.2 Martijn Dekker <martijn@inlv.demon.nl> - 2021-12-19 21:00 +0000
      Re: [ANN] KornShell 93u+m 1.0.0-beta.2 Martijn Dekker <martijn@inlv.demon.nl> - 2021-12-21 19:12 +0000
      Re: [ANN] KornShell 93u+m 1.0.0-beta.2 Janis Papanagnou <janis_papanagnou@hotmail.com> - 2021-12-24 14:46 +0100

csiph-web