1 TARGET
= git_cheetah_ext
2 MODULES
= menu.c util.c plugin.c ..
/compat
/posix.c
3 OBJECTS
= ${MODULES
:%.c
=%.o
}
7 $(shell pkg-config
--libs libnautilus-extension
)
9 WFLAGS
=-std
=c99
-Wall
-pedantic
11 # needed to get the proper declarations for glibc
12 COMPAT_CFLAGS
= -D_POSIX_C_SOURCE
=200112L -D_GNU_SOURCE
13 CFLAGS
= $(WFLAGS
) -fPIC
-g
$(COMPAT_CFLAGS
) \
14 $(shell pkg-config
--cflags libnautilus-extension
)
20 COMMON_OBJ
= ..
/common
/cheetahmenu.o ..
/common
/date.o ..
/common
/debug.o \
21 ..
/common
/exec.o ..
/common
/menuengine.o \
22 ..
/common
/sha1_file.o ..
/common
/strbuf.o \
23 ..
/common
/usage.o ..
/common
/wrapper.o
26 $(MAKE
) -C ..
/common
all
29 $(CC
) $(CFLAGS
) $< -c
-o
$@
32 $(CC
) $(CFLAGS
) -MM
$(MODULES
) > deps
34 $(TARGET
).so
: $(OBJECTS
) $(COMPAT_OBJ
) common-obj
35 gcc
$(LDFLAGS
) $(OBJECTS
) $(COMPAT_OBJ
) $(COMMON_OBJ
) \
41 mkdir
-p
$(LIBDIR
)/nautilus
/extensions-2.0
42 cp
$(TARGET
).so
$(LIBDIR
)/nautilus
/extensions-2.0
/
45 rm -f
$(OBJECTS
) $(COMPAT_OBJ
) $(TARGET
).so deps
46 $(MAKE
) -C ..
/common
clean