summaryrefslogtreecommitdiffstats
path: root/cpukit/libfs/wrapup/Makefile.am
blob: 8dce90f71a7134f0c561ceff815e4fa7ae6541d0 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
##
## $Id$
##


LIBNAME = libfs
LIB = $(ARCH)/$(LIBNAME).a

include $(top_srcdir)/../../../../automake/multilib.am
include $(top_srcdir)/../../../../automake/compile.am
include $(top_srcdir)/../../../../automake/lib.am

IMFSLIB = ../src/imfs/$(ARCH)/libimfs.a

if !UNIX
DOSFSLIB = ../src/dosfs/$(ARCH)/libdosfs.a
endif

TMP_LIBS = $(IMFSLIB) $(DOSFSLIB)

$(PROJECT_RELEASE)/lib/$(LIBNAME)$(LIB_VARIANT).a: $(LIB)
	$(INSTALL_DATA) $< $@

#
# (OPTIONAL) Add local stuff here using +=
#

$(LIB): $(TMP_LIBS)
	$(RM) $@
	$(RM) -r $(ARCH)
	mkdir $(ARCH)
	cd $(ARCH); for lib in $^; do $(AR) -xv ../$$lib; done
	$(AR) ruv $@ $(ARCH)/*
	$(RANLIB) $@

TMPINSTALL_FILES += $(PROJECT_RELEASE)/lib/$(LIBNAME)$(LIB_VARIANT).a

all-local: $(ARCH) $(LIB) $(TMPINSTALL_FILES)

.PRECIOUS: $(LIB)

include $(top_srcdir)/../../../../automake/local.am