GithubHelp home page GithubHelp logo

Comments (6)

elockman avatar elockman commented on July 18, 2024

@dreirund did you ever resolve this issue?

I found that this error is not present with gcc v9.4, but is introduced in gcc v10 and v11.
TAILQ_HEAD() in the peer_lists.h header file creates a peers and blacklist variable in peers.c.o, ampe.c.o, and sae.c.o, so the linker complains.

from authsae.

dreirund avatar dreirund commented on July 18, 2024

@dreirund did you ever resolve this issue?

No, and I also know almost nothing about linkin, gcc, C/C++-code and related stuff, so I can only report but not bugfix.

from authsae.

dreirund avatar dreirund commented on July 18, 2024

I found that this error is not present with gcc v9.4, but is introduced in gcc v10 and v11

With gcc 9.5.0 I get the following error:

[...]
[  5%] Building C object CMakeFiles/sae.dir/sae.c.o
/usr/bin/gcc-9  -I/tmp/makepkg/build/authsae-git/src/authsae -g0 -march=x86-64 -mtune=native -O3 -flto -ffat-lto-objects -pipe -fstack-protector --param=ssp-buffer-size=4 -D_FORTIFY_SOURCE=2 -fomit-frame-pointer -fPIC -Wall    -g -MD -MT CMakeFiles/sae.dir/sae.c.o -MF CMakeFiles/sae.dir/sae.c.o.d -o CMakeFiles/sae.dir/sae.c.o -c /tmp/makepkg/build/authsae-git/src/authsae/sae.c
/tmp/makepkg/build/authsae-git/src/authsae/sae.c:81:18: error: static declaration of ‘HMAC_CTX_new’ follows non-static declaration
   81 | static HMAC_CTX *HMAC_CTX_new(void) {
      |                  ^~~~~~~~~~~~
In file included from /tmp/makepkg/build/authsae-git/src/authsae/sae.c:42:
/usr/include/openssl/hmac.h:33:33: note: previous declaration of ‘HMAC_CTX_new’ was here
   33 | OSSL_DEPRECATEDIN_3_0 HMAC_CTX *HMAC_CTX_new(void);
      |                                 ^~~~~~~~~~~~
/tmp/makepkg/build/authsae-git/src/authsae/sae.c: In function ‘HMAC_CTX_new’:
/tmp/makepkg/build/authsae-git/src/authsae/sae.c:82:36: error: invalid application of ‘sizeof’ to incomplete type ‘HMAC_CTX’ {aka ‘struct hmac_ctx_st’}
   82 |   return (HMAC_CTX *)calloc(sizeof(HMAC_CTX), 1);
      |                                    ^~~~~~~~
/tmp/makepkg/build/authsae-git/src/authsae/sae.c: At top level:
/tmp/makepkg/build/authsae-git/src/authsae/sae.c:85:13: error: static declaration of ‘HMAC_CTX_free’ follows non-static declaration
   85 | static void HMAC_CTX_free(HMAC_CTX *ctx) {
      |             ^~~~~~~~~~~~~
In file included from /tmp/makepkg/build/authsae-git/src/authsae/sae.c:42:
/usr/include/openssl/hmac.h:35:28: note: previous declaration of ‘HMAC_CTX_free’ was here
   35 | OSSL_DEPRECATEDIN_3_0 void HMAC_CTX_free(HMAC_CTX *ctx);
      |                            ^~~~~~~~~~~~~
/tmp/makepkg/build/authsae-git/src/authsae/sae.c: In function ‘HMAC_CTX_free’:
/tmp/makepkg/build/authsae-git/src/authsae/sae.c:87:5: warning: implicit declaration of function ‘HMAC_CTX_cleanup’; did you mean ‘HMAC_CTX_free’? [-Wimplicit-function-declaration]
   87 |     HMAC_CTX_cleanup(ctx);
      |     ^~~~~~~~~~~~~~~~
      |     HMAC_CTX_free
/tmp/makepkg/build/authsae-git/src/authsae/sae.c: In function ‘prf’:
/tmp/makepkg/build/authsae-git/src/authsae/sae.c:171:5: warning: ‘HMAC_Init_ex’ is deprecated: Since OpenSSL 3.0 [-Wdeprecated-declarations]
  171 |     HMAC_Init_ex(ctx, key, keylen, EVP_sha256(), NULL);
      |     ^~~~~~~~~~~~
[...]
make[2]: *** [CMakeFiles/sae.dir/build.make:177: CMakeFiles/sae.dir/sae.c.o] Error 1
make[2]: Leaving directory '/tmp/makepkg/build/authsae-git/src/authsae'
make[1]: *** [CMakeFiles/Makefile2:106: CMakeFiles/sae.dir/all] Error 2
make[1]: Leaving directory '/tmp/makepkg/build/authsae-git/src/authsae'
make: *** [Makefile:139: all] Error 2

And lot more warnings.

I get the samee error with 12.2.1 now. So some newer libraries (OpenSSL 3.x) might have broken other things, too?

Full make -j1 output: make.log (second run).

from authsae.

dreirund avatar dreirund commented on July 18, 2024

OK, with openssl-1.1 and gcc9 it builds (with warnings) :-). ↗ AUR package is updated. But the issue I leave open because it needs fixes in the code.

from authsae.

elockman avatar elockman commented on July 18, 2024

@dreirund you can try my fork if you'd like here.
I'd like to hear feedback if you have any issues pop up.

from authsae.

dreirund avatar dreirund commented on July 18, 2024

@dreirund you can try my fork if you'd like here. I'd like to hear feedback if you have any issues pop up.

It compiles and links for me with OpenSSL 3.0.8 and gcc 12.2.1. Thanks!

However, I cannot find anymore the official version number. In https://github.com/cozybit/authsae/, it could be retrieved via git describe --tags. In https://github.com/elockman/authsae, the above command does not retrieve anything, and I also could not find it within the source files (doing simple grep searches vor 1.3 and version and VERSION). Would be helpful to have the official version number carried on.

Also, writing in the README.md what your changes are about with respect to the original can be helpful for people who stumble upon different authsae-repositories.

Regards!

from authsae.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.