mirror of
https://git.kernel.org/pub/scm/fs/ext2/e2fsprogs.git
synced 2024-12-03 06:54:00 +08:00
39b503491b
Change to use new installation directory variables convention. Add uninstall rules.
42 lines
819 B
Makefile
42 lines
819 B
Makefile
#
|
|
# This is a Makefile stub which handles the creation of Linux BSD shared
|
|
# libraries.
|
|
#
|
|
# In order to use this stub, the following makefile variables must be defined.
|
|
#
|
|
# BSDLIB_VERSION = 1.0
|
|
# BSDLIB_IMAGE = libce
|
|
# BSDLIB_MYDIR = et
|
|
# BSDLIB_INSTALL_DIR = $(SHLIBDIR)
|
|
#
|
|
|
|
all:: pic image
|
|
|
|
subdirs:: pic
|
|
|
|
pic:
|
|
mkdir pic
|
|
|
|
BSD_LIB = $(BSDLIB_IMAGE).so.$(BSDLIB_VERSION)
|
|
|
|
image: $(BSD_LIB)
|
|
|
|
$(BSD_LIB): $(OBJS)
|
|
(cd pic; ld -Bshareable -o $(BSD_LIB) $(OBJS))
|
|
$(MV) pic/$(BSD_LIB) .
|
|
$(RM) -f ../$(BSD_LIB)
|
|
$(LN) $(BSD_LIB) ../$(BSD_LIB)
|
|
|
|
install-shlibs install:: $(BSD_LIB)
|
|
$(INSTALL_PROGRAM) $(BSD_LIB) \
|
|
$(DESTDIR)$(BSDLIB_INSTALL_DIR)/$(BSD_LIB)
|
|
-ldconfig
|
|
|
|
uninstall-shlibs uninstall::
|
|
$(RM) -f $(DESTDIR)$(BSDLIB_INSTALL_DIR)/$(BSD_LIB)
|
|
|
|
clean::
|
|
$(RM) -rf pic
|
|
$(RM) -f $(BSD_LIB)
|
|
$(RM) -f ../$(BSD_LIB)
|