Libelektra: date plugin with musl / alpine 3.7

Created on 15 Jun 2018  Â·  6Comments  Â·  Source: ElektraInitiative/libelektra

The date plugin seems to have several problems when compiled with musl.

44/172 Test  #49: testmod_date .............................***Failed    0.00 sec
DATE     TESTS
==================

/home/jenkins/workspace/libelektra_PR-2063-LIVOSPL6L4UH5CAHYVKB57ZOFL2KYPEWGRHMTO5TDKMLMP5JUIOQ/src/plugins/date/testmod_date.c:47: error in testIso: validation failed
/home/jenkins/workspace/libelektra_PR-2063-LIVOSPL6L4UH5CAHYVKB57ZOFL2KYPEWGRHMTO5TDKMLMP5JUIOQ/src/plugins/date/testmod_date.c:62: error in testRfc2822: validation failed
/home/jenkins/workspace/libelektra_PR-2063-LIVOSPL6L4UH5CAHYVKB57ZOFL2KYPEWGRHMTO5TDKMLMP5JUIOQ/src/plugins/date/testmod_date.c:62: error in testRfc2822: validation failed
/home/jenkins/workspace/libelektra_PR-2063-LIVOSPL6L4UH5CAHYVKB57ZOFL2KYPEWGRHMTO5TDKMLMP5JUIOQ/src/plugins/date/testmod_date.c:62: error in testRfc2822: validation failed

I had a look around but cannot pinpoint the problems.

It also is relying on features.h which is discouraged.

bug help wanted stale

Most helpful comment

Just checked again, posix strptime doesn't support %z/%Z for timezones needed by rfc822. best course of action would probably be ignoring the timezone in strptime and implement a check for it, but i'm not sure if i can do it this week

All 6 comments

Thank you for reporting this problem!

@tom-wa Do you have an idea which parts are not portable? The README says POSIX.1-2001 should suffice?

The messages of the unit tests are useless. The tests should at least print the error+warnings of the plugin.

Just checked again, posix strptime doesn't support %z/%Z for timezones needed by rfc822. best course of action would probably be ignoring the timezone in strptime and implement a check for it, but i'm not sure if i can do it this week

Under CentOS 7 the same problem occurs:

Running testmod_date

DATE     TESTS
==================

/builddir/build/BUILD/elektra-0.8.26/src/plugins/date/testmod_date.c:32: error in testFmt: validation failed
/builddir/build/BUILD/elektra-0.8.26/src/plugins/date/testmod_date.c:47: error in testIso: validation failed
/builddir/build/BUILD/elektra-0.8.26/src/plugins/date/testmod_date.c:47: error in testIso: validation failed
/builddir/build/BUILD/elektra-0.8.26/src/plugins/date/testmod_date.c:47: error in testIso: validation failed

testmod_date Results: 72 Tests done — 4 errors.
error: testmod_date

Running testmod_dbus

I mark this issue stale as it did not have any activity for one year. I'll close it in two weeks if no further activity occurs. If you want it to be alive again, ping the issue by writing a message here or create a new issue with the remainder of this issue.
Thank you for your contributions :sparkling_heart:

I closed this issue now because it has been inactive for more than one year. If I closed it by mistake, please do not hesitate to reopen it or create a new issue with the remainder of this issue.
Thank you for your contributions :sparkling_heart:

Was this page helpful?
0 / 5 - 0 ratings

Related issues

markus2330 picture markus2330  Â·  4Comments

markus2330 picture markus2330  Â·  4Comments

mpranj picture mpranj  Â·  3Comments

sanssecours picture sanssecours  Â·  3Comments

sanssecours picture sanssecours  Â·  4Comments