Comments (4)
Did you happen to resolve this issue. I am kind of stuck in same kind of issue.
from jwt-cpp.
@sarbjit-longia I just switched to a different lib cpp-jwt which is a header only lib.
from jwt-cpp.
ohhh :(
from jwt-cpp.
The reason this happens is due to incorrect specification if link order. The correct line in the makefile should be:
jwt_test: jwt.o
g++ -std=c++11 -Wall -L ../src -I /usr/include -I ../../src/include/ -I /usr/local/include jwt/jwt_test.cpp jwt/jwt.o -o jwt/jwt_test.o -ljwt -lssl -lcrypto
The following question on stackoverflow explains it in detail:
The GNU ld linker is a so-called smart linker. It will keep track of the functions used by preceding static libraries, permanently tossing out those functions that are not used from its lookup tables. The result is that if you link a static library too early, then the functions in that library are no longer available to static libraries later on the link line.
Since you included the libraries in the beginning all the required functions are tossed out of the lookup table, causing the strange linker issues.
from jwt-cpp.
Related Issues (20)
- Nested jwt
- header only? HOT 1
- Possibility to bundle your own nlohmann/json
- OPENSSL_LIBRARIES variable required for non-mac users
- Support that the last character in the jwt token is \n HOT 2
- Link error on linux HOT 2
- jwt.ccp char array HOT 2
- Update Nholmann Json to latest official release
- Use standard cmake module FindOpenSSL.cmake to find OpenSSL HOT 7
- Please create a new Release version of latest master HOT 2
- vs2015 link error HOT 2
- generate windows dll but can not export lib file
- CMakeList error for windows compile HOT 2
- Boost Software License? HOT 4
- Visual Studio 2015 Link Error HOT 1
- Link error on linux, undefined reference to RS256Validator::RS256Validator HOT 2
- Decode does not work for arm64 architecture android devices
- integrate with Yocto build
- OpenSSL 3.x support
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
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.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from jwt-cpp.