aboutsummaryrefslogtreecommitdiffstats
path: root/tools/dosfstools
Commit message (Expand)AuthorAgeFilesLines
* add PKG_CPE_ID ids to package and toolsAlexander Couzens2017-11-171-0/+1
* tools/dosfstools: Update to 4.1Daniel Engberg2017-03-203-38/+4
* treewide: clean up download hashesFelix Fietkau2016-12-161-1/+1
* dosfstools: fix autotools dependencyÁlvaro Fernández Rojas2016-10-121-0/+2
* tools: improve and simplify dosfstoolsÁlvaro Fernández Rojas2016-10-122-11/+27
* tools: remove old mkdosfs symlink from dosfstoolsÁlvaro Fernández Rojas2016-10-121-1/+0
* source: Switch to xz for packages and tools where possibleDaniel Engberg2016-10-061-2/+2
* dosfstools: fix build on OS XÁlvaro Fernández Rojas2016-07-132-10/+2
* dosfstools: update to v4.0Álvaro Fernández Rojas2016-07-0416-2508/+43
* dosfstools: switch back to release tarballs, update patches to the latest sen...Felix Fietkau2015-03-2216-1853/+2508
* dosfstools: fix build on OS XFelix Fietkau2015-03-151-0/+1849
* dosfstools: update to v3.0.27Felix Fietkau2015-03-151-7/+15
* tools: remove static linking supportJo-Philipp Wich2015-02-061-1/+1
* dosfstools: update to 3.0.26Nicolas Thill2015-01-111-8/+9
* use HOST_STATIC_LINKING instead of hardcoding -staticJo-Philipp Wich2012-08-121-1/+1
* dosfstools: link staticallyJo-Philipp Wich2012-08-101-1/+1
* add mktools and dosfstools which are needed for the raspberry piJohn Crispin2012-07-241-0/+30
ckground-color: #fff0f0 } /* Literal.String.Symbol */ .highlight .bp { color: #003388 } /* Name.Builtin.Pseudo */ .highlight .fm { color: #0066bb; font-weight: bold } /* Name.Function.Magic */ .highlight .vc { color: #336699 } /* Name.Variable.Class */ .highlight .vg { color: #dd7700 } /* Name.Variable.Global */ .highlight .vi { color: #3333bb } /* Name.Variable.Instance */ .highlight .vm { color: #336699 } /* Name.Variable.Magic */ .highlight .il { color: #0000DD; font-weight: bold } /* Literal.Number.Integer.Long */
#
# Copyright (c) 2006-2007, XenSource Inc.
#
# This library is free software; you can redistribute it and/or
# modify it under the terms of the GNU Lesser General Public
# License as published by the Free Software Foundation; either
# version 2.1 of the License, or (at your option) any later version.
#
# This library is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
# Lesser General Public License for more details.
#
# You should have received a copy of the GNU Lesser General Public
# License along with this library; if not, write to the Free Software
# Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307  USA
#
XEN_ROOT=$(CURDIR)/../..
include $(XEN_ROOT)/tools/Rules.mk

MAJOR = 1.0
MINOR = 0

CFLAGS += -Iinclude                     \
          $(shell xml2-config --cflags) \
          $(shell curl-config --cflags) \
          -fPIC

LDFLAGS += $(shell xml2-config --libs) \
           $(shell curl-config --libs)

LIBXENAPI_HDRS = $(wildcard include/xen/api/*.h) include/xen/api/xen_all.h
LIBXENAPI_OBJS = $(patsubst %.c, %.o, $(wildcard src/*.c))

TEST_PROGRAMS = test/test_bindings test/test_event_handling

.PHONY: all
all: libxenapi.so libxenapi.a

libxenapi.so: libxenapi.so.$(MAJOR)
	ln -sf $< $@

libxenapi.so.$(MAJOR): libxenapi.so.$(MAJOR).$(MINOR)
	ln -sf $< $@

libxenapi.so.$(MAJOR).$(MINOR): $(LIBXENAPI_OBJS)
	$(CC) $(LDFLAGS) -Wl,$(SONAME_LDFLAG) -Wl,libxenapi.so.$(MAJOR) $(SHLIB_LDFLAGS) -o $@ $^

libxenapi.a: $(LIBXENAPI_OBJS)
	$(AR) rcs libxenapi.a $^

$(TEST_PROGRAMS): test/%: test/%.o libxenapi.so
	$(CC) $(LDFLAGS) -o $@ $< -L . -lxenapi


.PHONY: install
install: all
	$(INSTALL_DIR) $(DESTDIR)$(INCLUDEDIR)/xen/api
	$(INSTALL_DIR) $(DESTDIR)$(LIBDIR)
	$(INSTALL_PROG) libxenapi.so.$(MAJOR).$(MINOR) $(DESTDIR)$(LIBDIR)
	ln -sf libxenapi.so.$(MAJOR).$(MINOR) $(DESTDIR)$(LIBDIR)/libxenapi.so.$(MAJOR)
	ln -sf libxenapi.so.$(MAJOR) $(DESTDIR)$(LIBDIR)/libxenapi.so
	$(INSTALL_DATA) libxenapi.a $(DESTDIR)$(LIBDIR)
	set -e; for i in $(LIBXENAPI_HDRS); do \
	    $(INSTALL_DATA) $$i $(DESTDIR)$(INCLUDEDIR)/xen/api; \
	done


.PHONY: clean
clean:
	rm -f `find -name *.o`
	rm -f libxenapi.so*
	rm -f libxenapi.a
	rm -f $(TEST_PROGRAMS)