Advertisement
saleks28

make_lexa1

Jan 27th, 2021
2,550
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Make 0.83 KB | None | 0 0
  1. .PHONY: blob
  2.  
  3. CC=gcc
  4. CP=cp
  5. RM=rm
  6.  
  7. all: start static dynamic blob
  8.  
  9. static:
  10.     $(CC) -I./libs/include/ -I./libs/include/freetype2/ -L./libs/lib/ app_static.c -lfreetype -lpng -lz -lm -o app-static
  11.  
  12. dynamic:
  13.     $(RM) -f *.so
  14.     $(CP) -f ./libs/lib/libfreetype.so ./libfreetype.so
  15.     $(CP) -f ./libs/lib/libpng.so ./libpng.so
  16.     $(CC) -I./libs/include/ -I./libs/include/freetype2/ -DDYNAMIC app_dynamic.c -lm -ldl -o ./app-dynamic
  17.  
  18. blob:
  19.     $(CC) ./elfloader/elf_loader.c ./elfloader/main.c ./elfloader/wheelc/list.c -lm -ldl -o ./app-blob
  20.     $(CC) -I./libs/include/ -I./libs/include/freetype2/ -L./libs/lib/ -fno-stack-protector -fno-exceptions -nostdlib -pie -fPIE -fPIC -shared -DBLOB app_blob.c -lfreetype -lpng -lz -lm -o ./blob.bin
  21.  
  22. start: clean
  23.     $(RM) -f *.so
  24.     $(RM) -f *.png
  25.  
  26. clean:
  27.     $(RM) -f app-*
  28.     $(RM) -f app.o
  29.     $(RM) -f blob.bin
  30.  
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement