New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

date plugin with musl / alpine 3.7 #2080

Open
ingwinlu opened this Issue Jun 15, 2018 · 3 comments

Comments

Projects
None yet
3 participants
@ingwinlu
Contributor

ingwinlu commented Jun 15, 2018

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.

@ingwinlu ingwinlu changed the title from date plugin with musl to date plugin with musl / alpine 3.7 Jun 15, 2018

@markus2330

This comment has been minimized.

Contributor

markus2330 commented Jun 15, 2018

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?

@markus2330

This comment has been minimized.

Contributor

markus2330 commented Jun 15, 2018

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

@tom-wa

This comment has been minimized.

Contributor

tom-wa commented Jun 16, 2018

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

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment