I am trying to use AppWeb, and I wrote a very simple program for embedding AppWeb in my application using the function in the AppWeb library.
#include <appweb/appweb.h>
int main(int argc, char** argv)
{
return maRunWebServer("appweb.conf");
}
I do not know when I compile gcc (or cc), it compiled successfully. But, when I turn to compilation in Arm Architecture, an error occurs. This is my Makefile:
CC = gcc
LIBS = lib
FLAG = -lappweb -lmpr
TEST_TARGET = embed-appweb
OBJS = embed-appweb
all: clean compile
compile: run
$(CC) -Wall -L$(LIBS) $(FLAG) -o $(TEST_TARGET) $(OBJS).o
run:
$(CC) -Wall -L$(LIBS) $(FLAG) -c $(OBJS).c
clean:
@rm -rf $(TEST_TARGET) $(TEST_TARGET).trc *.o *~
@echo "Clean complete"
I replaced "CC = gcc" with "CC = arm-linux-gcc" in another to cross compile. Error in my problem:
arm-linux-gcc -Wall -Llib -lappweb -lmpr -c embed-appweb.c
embed-appweb.c:1:27: error: appweb/appweb.h: No such file or directory
embed-appweb.c: In function 'main':
embed-appweb.c:4: warning: implicit declaration of function 'maRunWebServer'
make: *** [run] Error 1
and I'm sure that the library "libappweb.so" exists in my folder "lib"
Can someone tell me why he got an error? and give me some advice?
Thank,