I want to compile C files using make with the libpng library. However, this is what I got after typing the "make"
makegcc mp5.o main.o -o mp5 -lpng -g -m32/usr/bin/ld: skipping incompatible /usr/lib/x86_64-linux-gnu/libpng.so when searching for -lpng/usr/bin/ld: skipping incompatible /usr/lib/x86_64-linux-gnu/libpng.a when searching for -lpng/usr/bin/ld: cannot find -lpng: No such file or directory/usr/bin/ld: skipping incompatible /usr/lib/x86_64-linux-gnu/libpng.so when searching for -lpngcollect2: error: ld returned 1 exit statusmake: *** [Makefile:14: mp5] Error 1
It seems that the issue is because I'm trying to run the library on a 32 bit machine. But, I don't know if there's any workaround. Should I just work on a 64 bit machine at this point?
Edit: I just realized that the machine that I'm currently working on is actually 64 bit. I just put the -m32 option there because I initially thought I was working in a 32 one. But removing it doesn't solve the problem though
I'm using WSL in Windows 11