Note: This bug is displayed in read-only format because the product is no longer active in Red Hat Bugzilla.
RHEL Engineering is moving the tracking of its product development work on RHEL 6 through RHEL 9 to Red Hat Jira (issues.redhat.com). If you're a Red Hat customer, please continue to file support cases via the Red Hat customer portal. If you're not, please head to the "RHEL project" in Red Hat Jira and file new tickets here. Individual Bugzilla bugs in the statuses "NEW", "ASSIGNED", and "POST" are being migrated throughout September 2023. Bugs of Red Hat partners with an assigned Engineering Partner Manager (EPM) are migrated in late September as per pre-agreed dates. Bugs against components "kernel", "kernel-rt", and "kpatch" are only migrated if still in "NEW" or "ASSIGNED". If you cannot log in to RH Jira, please consult article #7032570. That failing, please send an e-mail to the RH Jira admins at rh-issues@redhat.com to troubleshoot your issue as a user management inquiry. The email creates a ServiceNow ticket with Red Hat. Individual Bugzilla bugs that are migrated will be moved to status "CLOSED", resolution "MIGRATED", and set with "MigratedToJIRA" in "Keywords". The link to the successor Jira issue will be found under "Links", have a little "two-footprint" icon next to it, and direct you to the "RHEL project" in Red Hat Jira (issue links are of type "https://issues.redhat.com/browse/RHEL-XXXX", where "X" is a digit). This same link will be available in a blue banner at the top of the page informing you that that bug has been migrated.

Bug 1246155

Summary: Colord make check fails on /colord/device qualifiers on ppc64le
Product: Red Hat Enterprise Linux 7 Reporter: Vadim Rutkovsky <vrutkovs>
Component: colordAssignee: Richard Hughes <rhughes>
Status: CLOSED NOTABUG QA Contact: Desktop QE <desktop-qa-list>
Severity: unspecified Docs Contact:
Priority: unspecified    
Version: 7.2CC: mclasen, tpelka, vrutkovs
Target Milestone: rc   
Target Release: ---   
Hardware: ppc64le   
OS: Unspecified   
Whiteboard:
Fixed In Version: Doc Type: If docs needed, set a value
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2017-03-08 14:27:42 UTC Type: Bug
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:
Bug Depends On: 1250914    
Bug Blocks:    

Description Vadim Rutkovsky 2015-07-23 14:50:04 UTC
Description of problem:
Internal 'make check' fails on ppc64le machine

Version-Release number of selected component (if applicable):
colord-1.2.7-2.el7.ppc64le

How reproducible:
Always

Steps to Reproduce:
1. Run 'make check' in buildroot of colord

Actual results:

/colord/device{invalid}: OK
/colord/device{qualifiers}: **
libcolord:ERROR:cd-test-daemon.c:165:colord_device_qualifiers_func: assertion failed (error == NULL): failed to open stream (cd_client_error, 7)

See full log at https://desktopqe-jenkins.rhev-ci-vms.eng.rdu2.redhat.com/job/desktop-colord-RHEL-7.2-2-runtest/56/artifact/testresults-FAKE/test-suite.log

Expected results:
make check passes

Additional info:
Environment: 
 ppc64le machine - https://beaker.engineering.redhat.com/view/ibm-p8-03-lp5.rhts.eng.bos.redhat.com#details

 package versions - https://desktopqe-jenkins.rhev-ci-vms.eng.rdu2.redhat.com/job/desktop-colord-RHEL-7.2-2-runtest/56/artifact/packages.list

Comment 1 Richard Hughes 2015-07-24 13:12:29 UTC
This is quite odd; the error is from:

	stream = fdopen (fd, "r");
	if (stream == NULL) {
		g_set_error (error,
			     CD_ICC_ERROR,
			     CD_ICC_ERROR_FAILED_TO_OPEN,
			     "failed to open stream from fd %i",
			     fd);
		return FALSE;
	}

is there any way you can gdb the cd-test-daemon executable and find out the errno? That would help this along a huge amount.

For the other failure, I think this is a failure of the lcms2 library on PPC64:

	priv->lcms_profile = cmsOpenProfileFromMemTHR (priv->context_lcms,
						       data, data_len);
	if (priv->lcms_profile == NULL) {
		g_set_error_literal (error,
				     CD_ICC_ERROR,
				     CD_ICC_ERROR_FAILED_TO_PARSE,
				     "failed to load: not an ICC icc");
		return FALSE;
	}

i.e. i think there's some kind of endian issue when we're opening the file in lcms2.

Comment 2 Vadim Rutkovsky 2015-07-24 13:52:32 UTC
(In reply to Richard Hughes from comment #1)
> is there any way you can gdb the cd-test-daemon executable and find out the
> errno? That would help this along a huge amount.

Sure, will do.

> i.e. i think there's some kind of endian issue when we're opening the file
> in lcms2.

Right, I think https://desktopqe-jenkins.rhev-ci-vms.eng.rdu2.redhat.com/job/desktop-lcms2-RHEL-7.2-2-runtest/26/artifact/testresults-FAKE/lcms2tests.log is not happy about endianess - I'll file a new bug on this and link it here

Comment 3 Tomas Pelka 2015-08-06 12:38:10 UTC
I can see this on x86_64 too

Comment 4 Tomas Pelka 2015-08-06 12:46:15 UTC
*** Bug 1224743 has been marked as a duplicate of this bug. ***

Comment 5 Vadim Rutkovsky 2015-08-12 10:00:17 UTC
Let first fix the lcms2 issue (bug 1250914) and see if this helps

Comment 6 Tomas Pelka 2015-09-07 09:39:24 UTC
Probably still blocked by bug 1250914) which is not fixed yet.

Comment 8 Tomas Pelka 2016-08-04 09:51:37 UTC
So with the new lcms2 I got a bit different output:

=============================================
   colord 1.2.7: lib/colord/test-suite.log
=============================================

# TOTAL: 2
# PASS:  1
# SKIP:  0
# XFAIL: 0
# FAIL:  1
# XPASS: 0
# ERROR: 0

.. contents:: :depth: 2

FAIL: cd-test-daemon
====================

/colord/client: OK
/colord/device: OK
/colord/device{embedded}: OK
/colord/device{invalid-kind}: OK
/colord/device{duplicate}: OK
/colord/device{seat}: OK
/colord/device{enabled}: OK
/colord/device{invalid}: OK
/colord/device{qualifiers}: **
libcolord:ERROR:cd-test-daemon.c:165:colord_device_qualifiers_func: assertion failed (error == NULL): failed to load file: Error opening file: Permission denied (cd_client_error, 7)

Note that the test is executed as root, is it correct?

Comment 9 Richard Hughes 2017-02-28 14:21:01 UTC
(In reply to Tomas Pelka from comment #8)
> So with the new lcms2 I got a bit different output:
> Note that the test is executed as root, is it correct?

No, you need to run the tests as a normal user. I don't think running the daemon tests (this actually interacts with a running colord process, rather than doing just self tests) in the rpm file is a good idea.

Comment 10 Richard Hughes 2017-02-28 14:25:21 UTC
Can I close this as the daemon checks are nothing to do with ppc64le, and with the updated lcms2 package installed the self tests on the profile now pass?

Comment 11 Matthias Clasen 2017-03-08 13:23:11 UTC
No answer... I would say yes, lets close this.

Comment 12 Richard Hughes 2019-07-30 15:39:33 UTC
*** Bug 1171718 has been marked as a duplicate of this bug. ***