xref: /tools/libs/store/Makefile
  • Home
  • Annotate
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
  • current directory
1XEN_ROOT=$(CURDIR)/../../..
2include $(XEN_ROOT)/tools/Rules.mk
3
4MAJOR = 4
5MINOR = 1
6version-script := libxenstore.map
7
8ifeq ($(CONFIG_Linux),y)
9LDLIBS += -ldl
10endif
11
12OBJS-y   += xs.o
13
14LIBHEADER = xenstore.h xenstore_lib.h
15
16include ../libs.mk
17
18# Include configure output (config.h)
19CFLAGS += -include $(XEN_ROOT)/tools/config.h
20CFLAGS += $(CFLAGS_libxentoolcore)
21
22xs.opic: CFLAGS += -DUSE_PTHREAD
23ifeq ($(CONFIG_Linux),y)
24xs.opic: CFLAGS += -DUSE_DLSYM
25endif
26
27.PHONY: install
28install::
29	$(INSTALL_DIR) $(DESTDIR)$(includedir)
30	$(INSTALL_DIR) $(DESTDIR)$(includedir)/xenstore-compat
31	$(INSTALL_DATA) $(XEN_INCLUDE)/xenstore-compat/xs.h $(DESTDIR)$(includedir)/xenstore-compat/xs.h
32	$(INSTALL_DATA) $(XEN_INCLUDE)/xenstore-compat/xs_lib.h $(DESTDIR)$(includedir)/xenstore-compat/xs_lib.h
33	ln -sf xenstore-compat/xs.h  $(DESTDIR)$(includedir)/xs.h
34	ln -sf xenstore-compat/xs_lib.h $(DESTDIR)$(includedir)/xs_lib.h
35
36.PHONY: uninstall
37uninstall::
38	rm -f $(DESTDIR)$(includedir)/xs_lib.h
39	rm -f $(DESTDIR)$(includedir)/xs.h
40	rm -f $(DESTDIR)$(includedir)/xenstore-compat/xs_lib.h
41	rm -f $(DESTDIR)$(includedir)/xenstore-compat/xs.h
42	if [ -d $(DESTDIR)$(includedir)/xenstore-compat ]; then \
43		rmdir --ignore-fail-on-non-empty $(DESTDIR)$(includedir)/xenstore-compat; \
44	fi
45

Last Index update Fri Aug 22 02:49:16 CST 2025