PPT Slide
# Makefile for Linux JNI Compilation
JDK_PATH = /usr/local/jdk117_v1a/
# define utility programs and options
CFLAGS = -I$(JDK_PATH)include -I$(JDK_PATH)include/genunix -shared
INDENT = $(UPATH)indent -bl -c41 -i4 -l72 -pcs
# default target - builds Hello executable
$(CC) $(CFLAGS) -o libHello.so Hello.c
# "debug" target - builds executable with debug code
@CFLAGS="$(CFLAGS) -DDEBUG";export CFLAGS;$(MAKE) -e
# "pretty" target - beautify source files
ls $? | xargs -p -n1 $(INDENT)
# "clean" target - remove unwanted object files and executables
rm -f Hello Hello.o pretty tags lint nohup.out a.out core