switchbrew / switch-examples

Switch examples for devkitA64 and libnx.
https://devkitpro.org/viewforum.php?f=42
559 stars 99 forks source link

How to use an external header file in docker container? #105

Closed ghost closed 1 year ago

ghost commented 1 year ago

Yo!

I really don't know where else to ask this but I wanted to start playing around with some switch homebrew development. I was trying to see if I could use the switch as some sort of "backend" and tried to use this https://github.com/yhirose/cpp-httplib as it is a simple one header file that you include.

I'm using the docker image: "devkitpro/devkita64". The examples in this repository build fine but I tried building the simple example found in the template/application directory with the #include "httplib.h" added and I start getting errors where it doesn't find header files. I tried installing different packages and messing around with the Makefile but ultimately it all ended up in errors.

I'm not SUPER familiar with C/C++ but I was wondering if anyone could guide me in the right direction or if this is even possible?

WinterMute commented 1 year ago

The unfortunate thing about allegedly simple single header "libraries" is that they are often written with the assumption that they will be used on top of an OS (primarily linux). Currently we don't provide the dependencies needed by this "header only" library, sorry.

ghost commented 1 year ago

Gotcha, no worries.

Thank you for responding!