pcp
[Top] [All Lists]

Re: build woes

To: PCP <pcp@xxxxxxxxxxx>
Subject: Re: build woes
From: Ken McDonell <kenj@xxxxxxxxxxxxxxxx>
Date: Sat, 06 Jun 2015 07:04:25 +1000
Delivered-to: pcp@xxxxxxxxxxx
In-reply-to: <55715217.7000009@xxxxxxxxxxxxxxxx>
References: <55715217.7000009@xxxxxxxxxxxxxxxx>
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:31.0) Gecko/20100101 Thunderbird/31.7.0
On 05/06/15 17:39, Ken McDonell wrote:
...
In Debian-land, the build is OK, but run-time QA is hitting the wall ...

Traceback (most recent call last):
   File "/var/lib/pcp/pmdas/json/pmdajson.python", line 22, in <module>
     import jsonpointer
ImportError: No module named jsonpointer
1052: 51: read: Illegal option -u

The relevant package in Debian-land is python-json-pointer.

I've looked at the source some more, and now believe this is not really a build issue. The jsonpointer and six modules are not needed in the build they are only needed at run-time.

I suspect the rpm dependency is being added automagically by the rpm packaging (there is no reference to jsonpointer in the build/rpm directory), so that leaves the old rpm platforms as a bit of an issue.

For the non-rpm platforms we can live without any packaging dependency (I think) provided we guard against inappropriate execution in the QA environment ... I've added to qa/1052 to notrun if either of the Python modules jsonpointer or six are not installed (and tested this on FreeBSD).

The second issue (read -u) looks like a RH-ism that might need to be
translated into something more portable.

This is not a RH-ism it is a bash-ism. We run all our QA scripts with sh(1) not bash(1) ... and read is no part of sh(1) ... it works on some platforms when sh(1) and bash(1) are apparently the same, but fails on others where they are different.

This QA test needs some re-engineering to remove the bash-specific read use and make it a vanilla sh(1) script.

<Prev in Thread] Current Thread [Next in Thread>