Google Groups no longer supports new Usenet posts or subscriptions. Historical content remains viewable.
Dismiss

Being gobsmacked...

69 views
Skip to first unread message

Kenny McCormack

unread,
Jul 14, 2016, 7:54:58 AM7/14/16
to
In any earlier thread, Andy wrote:

>I am gobsmacked that you think this is easier than downloading and
>installing 2 tarballs and running "gawk -l xml".

I don't think Ed has access to a compiler/build-system. That's the whole point.

As I argued earlier (in the semi-penultimate round of this, several months
ago), the key is that people like Ed would rather cut off their hands than
dirty them with compilers and sh*t like that. Running compilers and sh*t
like that is for "other people".

Furthermore, people working under Windows (as opposed to Linux) simply
don't have compilers available to them at all (unless they go to the
trouble to find/download/debug/install/configure/etc one on their own).

>You could easily have installed the gawk-xml extension in less time than
>you have wasted on this discussion.

It is not about time; it is about policy.
And it is not a waste.

P.S. The analogies (microwaves/cars) are entirely on-point and useful.
Just because you don't understand them (or, more likely, insist on
pretending not to understand them) doesn't mean they don't work for the
rest of us.

--
The book "1984" used to be a cautionary tale;
Now it is a "how-to" manual.

Ed Morton

unread,
Jul 14, 2016, 2:24:29 PM7/14/16
to
On 7/14/2016 6:54 AM, Kenny McCormack wrote:
> In any earlier thread, Andy wrote:
>
>> I am gobsmacked that you think this is easier than downloading and
>> installing 2 tarballs and running "gawk -l xml".
>
> I don't think Ed has access to a compiler/build-system. That's the whole point.

To be clear about my environment: I have access to a compiler on some, but not
all machines I use. I use various types of UNIX-ish machines including cygwin,
Solaris, Linux, and OSX. On machines where I do have a compiler I use it to
compile my own C/C++ code. I never have to use make, GNU Autotools, build
libraries, etc. for that. In scenarios where make, etc. are required I have a
completely different build system provided by the company I work for that
isolates me from that. Compilation of the tools I use is done for me by the nice
people at cygwin and sysadmins everywhere else so:

a) It's not something I do or am in any way interested in learning how to do, and
b) I use a dozen different machines so I don't want to have to build/install
anything on every machine I use or might use, and
c) I don't have access to a compiler on some machines, and
d) Even where I do have access to a compiler I don't always have permission to
build/install tools/libraries.

Ed.

Andrew Schorr

unread,
Jul 14, 2016, 9:33:07 PM7/14/16
to
I think we all agree that it would be really nice if the various gawk extension libraries were available via the standard package distribution mechanisms provided by the various operating systems. The challenge is that the gawkextlib libraries are fairly new and don't have a big community behind them. What we really need is for volunteers to step forward to put in the time and effort to get the gawkextlib libraries included in each distribution. I believe that most, if not all, open-source packages start in the download/configure/make stage before attracting enough support to get included in the regular O/S package distribution mechanisms. The hope is that people will try the libraries, find them useful, and then volunteer or promote them to help us get them into the O/S distributions.

At the moment, I have a very busy day job, and I also work on core gawk and gawkextlib projects in my free time. I just don't have the time right now to volunteer to be a package maintainer to get these into an O/S distribution. If I did have the time, I'd target Fedora, since that's the one I use the most. We really need volunteers to help out with this.

Thanks,
Andy

Kenny McCormack

unread,
Jul 18, 2016, 9:47:35 AM7/18/16
to
In article <3097a602-7c3e-4290...@googlegroups.com>,
Andrew Schorr <asc...@telemetry-investments.com> wrote:
>I think we all agree that it would be really nice if the various gawk
>extension libraries were available via the standard package distribution
>mechanisms provided by the various operating systems.

I think that libgawkextlib (i.e., the smaller, less inclusive definition)
*should* be part of the core gawk distribution (i.e., the larger, more
inclusive definition). That is, when you do "configure/make/make install"
on the GAWK tarball, you should get libgawkextlib installed. The reason
for this is that building/installing/being-able-to-rely-on-its-being-present
(and note that that last thing is really the most important; that's really
the crux of all these threads) is the primary stumbling block to people
being able to comfortably use the gawkextlib-dependent extensions.

Similarly, if you do "apt-get install gawk", you would also get it.

Now, the next point I want to make is that it should also be possible to do
it all without being root/admin. As things currently stand, you have to
have root on your system in order to use gawkextlib. This is because the
only really supported way to use gawkextlib is to do a "make install" (or,
alternatively, an "apt-get install") and this requires root access. I
spent some time trying to get gawkextlib working without using root, and
failed. I suspect that if I had been willing to bang my head against the
wall longer than I was, I might eventually have figured it out, but
clearly, this is not a fruitful path to be on.

This touches on Ed's point about not having root (and/or not having
"permission") on some of the systems upon which he wants this stuff to run.

And finally, there is the problem of the Windows users. There exists no
good mechanism for making all this stuff available to them.

--
The randomly chosen signature file that would have appeared here is more than 4
lines long. As such, it violates one or more Usenet RFCs. In order to remain in
compliance with said RFCs, the actual sig can be found at the following web address:
http://www.xmission.com/~gazelle/Sigs/Mandela

Andrew Schorr

unread,
Jul 18, 2016, 10:16:52 PM7/18/16
to
On Monday, July 18, 2016 at 9:47:35 AM UTC-4, Kenny McCormack wrote:
> I think that libgawkextlib (i.e., the smaller, less inclusive definition)
> *should* be part of the core gawk distribution (i.e., the larger, more
> inclusive definition). That is, when you do "configure/make/make install"
> on the GAWK tarball, you should get libgawkextlib installed. The reason
> for this is that building/installing/being-able-to-rely-on-its-being-present
> (and note that that last thing is really the most important; that's really
> the crux of all these threads) is the primary stumbling block to people
> being able to comfortably use the gawkextlib-dependent extensions.

My impression from Ed's messages is that his primary stumbling block is that he simply doesn't want to run configure/make/make install, end of story.
So my understanding is that having to run configure/make/make install an extra time for libgawkextlib is not his problem. He doesn't ever want to run those commands for any package.

I know you disagree with me, but my feeling is that anybody who's willing to run it once for gawk-xml should not get too bent out of shape if there's a need to first run it for libgawkextlib. It takes less than 5 seconds:

bash-4.2$ time sh -c 'tar xf ~/src/xgawk/git/lib/gawkextlib-1.0.0.tar.gz && cd gawkextlib-1.0.0 && ./configure --prefix=/tmp/test-install && make && make check && make install && echo DONE'
checking for a BSD-compatible install... /usr/local/bin/ginstall -c
checking whether build environment is sane... yes
...
make[2]: Leaving directory `/extra_disk/tmp/gawkextlib-1.0.0'
make[1]: Leaving directory `/extra_disk/tmp/gawkextlib-1.0.0'
DONE

real 0m2.819s
user 0m0.704s
sys 0m0.428s

bash-4.2$ find /tmp/test-install -ls
334012720 0 drwxr-xr-x 4 schorr ead 80 Jul 18 22:10 /tmp/test-install
334012728 0 drwxr-xr-x 2 schorr ead 60 Jul 18 22:10 /tmp/test-install/include
334012729 8 -rw-r--r-- 1 schorr ead 4116 Jul 18 22:10 /tmp/test-install/include/gawkextlib.h
334012721 0 drwxr-xr-x 2 schorr ead 120 Jul 18 22:10 /tmp/test-install/lib
334012726 4 -rwxr-xr-x 1 schorr ead 951 Jul 18 22:10 /tmp/test-install/lib/libgawkextlib.la
334012724 0 lrwxrwxrwx 1 schorr ead 22 Jul 18 22:10 /tmp/test-install/lib/libgawkextlib.so -> libgawkextlib.so.0.0.0
334012723 0 lrwxrwxrwx 1 schorr ead 22 Jul 18 22:10 /tmp/test-install/lib/libgawkextlib.so.0 -> libgawkextlib.so.0.0.0
334009073 32 -rwxr-xr-x 1 schorr ead 32721 Jul 18 22:10 /tmp/test-install/lib/libgawkextlib.so.0.0.0


> Now, the next point I want to make is that it should also be possible to do
> it all without being root/admin. As things currently stand, you have to
> have root on your system in order to use gawkextlib. This is because the
> only really supported way to use gawkextlib is to do a "make install" (or,
> alternatively, an "apt-get install") and this requires root access. I
> spent some time trying to get gawkextlib working without using root, and
> failed. I suspect that if I had been willing to bang my head against the
> wall longer than I was, I might eventually have figured it out, but
> clearly, this is not a fruitful path to be on.

This is a big challenge. Suppose you want to parse XML with gawk. In order to do so, you certainly need to have the expat library installed on your system. If it's not already installed, then somebody with root privileges needs to install it, unless you want to start installing things in non-standard locations. If you want to go down that path, then yes, you can set up your own install tree and install expat and libgawkextlib and gawk-xml under that personal installation prefix. You will need to use the configure --prefix argument in each case, and when building gawk-xml, you may also need to use --with-gawkextlib and --with-expat (I'm not sure whether it finds those libraries automatically under the --prefix argument). Then, when you run gawk, you will want to set the AWKLIBPATH environment variable so that gawk will be able to find the gawk-xml library. In general, it's much better to have somebody with root privileges install this stuff so that you don't have private copies for every user.

> And finally, there is the problem of the Windows users. There exists no
> good mechanism for making all this stuff available to them.

What's wrong with Cygwin? All of the gawkextlib stuff builds easily on Cygwin.

Regards,
Andy

Kenny McCormack

unread,
Jul 18, 2016, 11:06:02 PM7/18/16
to
In article <551646c9-80f8-450e...@googlegroups.com>,
Andrew Schorr <asc...@telemetry-investments.com> wrote:
...
>In general, it's much better to have somebody with root privileges
>install this stuff so that you don't have private copies for every user.

If wishes were horses, then beggars would ride.
Or, as the economist says, "First, you assume a can opener".

I had meant to include a comment to the effect that I've been using and
installing software that uses the configure/make model for many, many
years, and I got my start at a time when ordinary users simply didn't have
root or any input on what the admins did (think shared school computers).

So, building the stuff in your home directory was the only way you could do
it, and you had to be adept at setting all the necessary environment
variables (PATH, LD_LIBRARY_PATH, AWKLIBPATH, etc) in order to make it
work. To this day, this is how I prefer to work. Old habits die hard, and
all that.

And, as I said, I did spend a fair amount of time trying to get the
Lightning extension working; most of that time was spent trying to get
gawkextlib built (and built in such a way that the Lightning extension
build process would fine and use it). I failed. As I said in my previous
post, I have no doubt that if I had been a little more willing to endure
the pain of banging my head against the wall for longer than I was, I
probably would have eventually gotten it to work.

>> And finally, there is the problem of the Windows users. There exists no
>> good mechanism for making all this stuff available to them.
>
>What's wrong with Cygwin? All of the gawkextlib stuff builds easily on Cygwin.

Of course it all "just works" with Cygwin. And I strongly agree with your
sentiment that that is the best way to do it. That's how I would do it.

But Cygwin is:
a) Not native Windows. It requires some technical knowledge and the
willingness to go out, find it, debug it, and install it on your
system - in order to be able to do any compiling/building of
software such as GAWK.
2) Not considered "native" by Windows purists (people not raised on
Unix/Linux). Hence the recent discussion thread in this very
newsgroups to that effect. See thread "People who don't like
Cygwin for some reason".

--
Alice was something of a handful to her father, Theodore Roosevelt. He was once
asked by a visiting dignitary about parenting his spitfire of a daughter and he
replied, "I can be President of the United States, or I can control Alice. I
cannot possibly do both."

Ed Morton

unread,
Jul 19, 2016, 9:05:48 PM7/19/16
to
On 7/18/2016 9:16 PM, Andrew Schorr wrote:
> On Monday, July 18, 2016 at 9:47:35 AM UTC-4, Kenny McCormack wrote:
>> I think that libgawkextlib (i.e., the smaller, less inclusive definition)
>> *should* be part of the core gawk distribution (i.e., the larger, more
>> inclusive definition). That is, when you do "configure/make/make install"
>> on the GAWK tarball, you should get libgawkextlib installed. The reason
>> for this is that building/installing/being-able-to-rely-on-its-being-present
>> (and note that that last thing is really the most important; that's really
>> the crux of all these threads) is the primary stumbling block to people
>> being able to comfortably use the gawkextlib-dependent extensions.
>
> My impression from Ed's messages is that his primary stumbling block is that he simply doesn't want to run configure/make/make install, end of story.
> So my understanding is that having to run configure/make/make install an extra time for libgawkextlib is not his problem. He doesn't ever want to run those commands for any package.

Correct. Too many boxes to do it on and too little enthusiasm...

Ed.

Andrew Schorr

unread,
Jul 20, 2016, 10:25:48 AM7/20/16
to
On Monday, July 18, 2016 at 11:06:02 PM UTC-4, Kenny McCormack wrote:
> And, as I said, I did spend a fair amount of time trying to get the
> Lightning extension working; most of that time was spent trying to get
> gawkextlib built (and built in such a way that the Lightning extension
> build process would fine and use it). I failed. As I said in my previous
> post, I have no doubt that if I had been a little more willing to endure
> the pain of banging my head against the wall for longer than I was, I
> probably would have eventually gotten it to work.

Gosh, I wish you had asked for help. You got me nervous that it might not work, so I just tested this on my Fedora 23 laptop. It took about 5 minutes to get this going. Here are the steps I followed:

- as root: dnf -y install lmdb-devel

I did everything else as my regular non-administrative user:

mkdir ~/src
cd ~/src
tar xf ~/Downloads/gawkextlib-1.0.0.tar.gz
cd gawkextlib-1.0.0
./configure --prefix=/home/users/schorr/gawkextlib && make && make check && make install && echo DONE
cd ..
tar xf ~/Downloads/gawk-lmdb-1.0.1.tar.gz
cd gawk-lmdb-1.0.1
./configure --prefix=/home/users/schorr/gawkextlib --with-gawkextlib=/home/users/schorr/gawkextlib && make && make check && make install && echo DONE

And that's it. Now it works:

[schorr@ajs-t530 ~]$ AWKLIBPATH=/home/users/schorr/gawkextlib/lib/gawk gawk -l lmdb 'BEGIN {print mdb_version()}'
LMDB 0.9.18: (February 5, 2016)

Note: if I didn't have root privileges to install lmdb-devel, then there would have been additional steps to download the lmdb tarball and build that with the same prefix. And then the configure command for gawk-lmdb would require an additional --with-lmdb=/home/users/schorr/gawkextlib argument. At least that's my theory. I didn't test it, so if you tell me that doesn't work, I will try it myself.

What went wrong for you?

Regards,
Andy
0 new messages