kolibrios/contrib/C_Layer/EXAMPLE/img_example/Makefile
superturbocat2001 7d51fcdeb2 - Updated libimg loader.
- Updated kolibri_libimg.h. 
- Added adapted libimg example from ktcc.

git-svn-id: svn://kolibrios.org@8545 a494cfbc-eb01-0410-851d-a64ba20cac60
2021-01-24 19:54:09 +00:00

26 lines
715 B
Makefile

NAME=img_example
CC = kos32-gcc
LD = kos32-ld
SDK_DIR:= $(abspath ../../../sdk)
CLAYER:= $(abspath ../../)
LDFLAGS = -static -S -nostdlib -T $(SDK_DIR)/sources/newlib/app.lds \
--image-base 0
CFLAGS = -c -fno-ident -O2 -fomit-frame-pointer -fno-ident -U__WIN32__ -U_Win32 -U_WIN32 -U__MINGW32__ -UWIN32
INCLUDES= -I. -I$(SDK_DIR)/sources/newlib/libc/include -I$(CLAYER)/INCLUDE
LIBPATH:= -L $(SDK_DIR)/lib -L /home/autobuild/tools/win32/mingw32/lib
OBJPATH = $(CLAYER)/OBJ
all:
$(CC) $(CFLAGS) $(INCLUDES) $(SOURCES) main.c
$(LD) $(LIBPATH) $(LDFLAGS) --subsystem native main.o $(OBJPATH)/loadlibimg.obj -o $(NAME) -lgcc -lc.dll
strip -S $(NAME)
objcopy $(NAME) -O binary
clean:
-rm -f *.o