cdepillabout / password

datatypes and functions for easily working with passwords in Haskell
http://hackage.haskell.org/package/password
55 stars 16 forks source link

tested to build with GHC 9.0.1 #50

Closed Vlix closed 2 years ago

Vlix commented 3 years ago

Updated CI and prepped to make the libraries build with GHC 9.0.1

Vlix commented 3 years ago

Hmmm, weird. I could build with --compiler ghc-9.0.1 --stack-yaml stack-ghc-9.yaml fine locally, but in the CI the unix-time C code throws errors?

cdepillabout commented 3 years ago

unix-time C code throws errors?

My guess is that these aren't actually errors:

https://github.com/cdepillabout/password/pull/50/checks?check_run_id=2758098911#step:5:2573

unix-time            > [5 of 5] Compiling Data.UnixTime
unix-time            > In file included from /usr/include/x86_64-linux-gnu/bits/libc-header-start.h:33,
unix-time            >                  from /usr/include/string.h:26,
unix-time            > 
unix-time            >                  /tmp/stack-43e4dfa14ec10c1d/unix-time-0.4.7/from cbits/conv.c:15:0: error: 
unix-time            > 
unix-time            > /usr/include/features.h:187:3: error:
unix-time            >      warning: #warning "_BSD_SOURCE and _SVID_SOURCE are deprecated, use _DEFAULT_SOURCE" [-Wcpp]
unix-time            >       187 | # warning "_BSD_SOURCE and _SVID_SOURCE are deprecated, use _DEFAULT_SOURCE"
unix-time            >           |   ^~~~~~~
unix-time            >     |
unix-time            > 187 | # warning "_BSD_SOURCE and _SVID_SOURCE are deprecated, use _DEFAULT_SOURCE"
unix-time            >     |   ^

I think that these are actually warnings, just with a confusing error message.

It looks like unix-time is actually installed and registered correctly, so I don't think these errors (warnings?) are actually fatal.

However, I don't really understand what could be happening. The last line is:

https://github.com/cdepillabout/password/pull/50/checks?check_run_id=2758098911#step:5:4336

Prelude.chr: bad argument: 4127195348

My only guess would be that the stack version that is being used in CI is too old to know how to use ghc-9.0?

My suggestion would be to go ahead and merge this in just with cabal support for now, and then just wait a few days until stackage nightly updates to ghc-9:

https://www.stackage.org/blog/2021/05/2021-05-29-upcomming-ghc-9-on-nightlies

Vlix commented 3 years ago

I've adjusted my safe-json library to build on GHC 9.0.1, and that seemed to work fine, so I think I'll give this another shot maybe somewhere next week(end)

REMINDER: Also add #41

Vlix commented 2 years ago

It builds now. Will remove the change to stack.yaml.lock after every build is confirmed to succeed.