equal
deleted
inserted
replaced
19 # libraries to use |
19 # libraries to use |
20 LOADLIBES = -lpng -lpthread |
20 LOADLIBES = -lpng -lpthread |
21 |
21 |
22 # output name |
22 # output name |
23 DIST_NAME = pngtile-${shell hg id -i} |
23 DIST_NAME = pngtile-${shell hg id -i} |
|
24 DIST_DEPS = python/pypngtile.c |
24 DIST_RESOURCES = README python/ pngtile/ static/ bin/ |
25 DIST_RESOURCES = README python/ pngtile/ static/ bin/ |
25 |
26 |
26 all: depend lib/libpngtile.so bin/pngtile |
27 all: depend lib/libpngtile.so bin/pngtile lib/pypngtile.so |
27 |
28 |
28 lib/libpngtile.so : \ |
29 lib/libpngtile.so : \ |
29 build/obj/lib/ctx.o build/obj/lib/image.o build/obj/lib/cache.o build/obj/lib/tile.o build/obj/lib/png.o build/obj/lib/error.o \ |
30 build/obj/lib/ctx.o build/obj/lib/image.o build/obj/lib/cache.o build/obj/lib/tile.o build/obj/lib/png.o build/obj/lib/error.o \ |
30 build/obj/shared/util.o build/obj/shared/log.o |
31 build/obj/shared/util.o build/obj/shared/log.o |
31 |
32 |
105 $(CC) -c -fPIC -I/usr/include/python2.5 $(CPPFLAGS) $(CFLAGS) $< -o $@ |
106 $(CC) -c -fPIC -I/usr/include/python2.5 $(CPPFLAGS) $(CFLAGS) $< -o $@ |
106 |
107 |
107 lib/py%.so : build/obj/python/py%.o |
108 lib/py%.so : build/obj/python/py%.o |
108 $(CC) -shared $(LDFLAGS) $+ $(LOADLIBES) $(LDLIBS) -o $@ |
109 $(CC) -shared $(LDFLAGS) $+ $(LOADLIBES) $(LDLIBS) -o $@ |
109 |
110 |
110 dist: |
111 dist: $(DIST_DEPS) |
111 rm -rf dist/$(DIST_NAME) |
112 rm -rf dist/$(DIST_NAME) |
112 mkdir -p dist/$(DIST_NAME) |
113 mkdir -p dist/$(DIST_NAME) |
113 cp -rv Makefile $(DIST_RESOURCES) src/ include/ dist/$(DIST_NAME)/ |
114 cp -rv Makefile $(DIST_RESOURCES) src/ include/ dist/$(DIST_NAME)/ |
114 rm dist/$(DIST_NAME)/src/*/.*.sw[op] |
|
115 make -C dist/$(DIST_NAME) dist-clean |
115 make -C dist/$(DIST_NAME) dist-clean |
116 tar -C dist -czvf dist/$(DIST_NAME).tar.gz $(DIST_NAME) |
116 tar -C dist -czvf dist/$(DIST_NAME).tar.gz $(DIST_NAME) |
117 @echo "*** Output at dist/$(DIST_NAME).tar.gz" |
117 @echo "*** Output at dist/$(DIST_NAME).tar.gz" |
118 |
118 |