mirror of
https://github.com/freebsd/freebsd-src
synced 2024-11-05 18:22:52 +00:00
Simplified using new SYMLINKS macro, mainly to test this macro. The
ifdefs are too ugly for this to be much of a simplification. The existence tests are even uglier now. Note that the previous commit was not submitted by me. It missed the point and just added a second layer of unused removals. Fixed hard-coded "libcrypt"s. The LCRYPTBASE macro mainly makes things hard to read, but use it while we have it.
This commit is contained in:
parent
2336a7ea75
commit
3c697e0a62
Notes:
svn2git
2020-12-20 02:59:44 +00:00
svn path=/head/; revision=44947
1 changed files with 15 additions and 26 deletions
|
@ -1,5 +1,5 @@
|
|||
#
|
||||
# $Id$
|
||||
# $Id: Makefile,v 1.17 1999/01/24 07:48:30 markm Exp $
|
||||
#
|
||||
|
||||
LCRYPTBASE= libcrypt
|
||||
|
@ -23,35 +23,24 @@ CFLAGS+= -I${.CURDIR}/../libmd -DLIBC_SCCS
|
|||
SONAME= ${LCRYPTBASE}.so.${SHLIB_MAJOR}
|
||||
.endif
|
||||
|
||||
# Include this early to pick up the definitions of SHLIB_MAJOR and
|
||||
# SHLIB_MINOR which are used in the existence tests.
|
||||
.include "${.CURDIR}/../Makefile.inc"
|
||||
|
||||
# We only install the links if they do not already exist.
|
||||
# This may have to be revised
|
||||
|
||||
afterinstall:
|
||||
.if !defined(NOPIC)
|
||||
@cd ${DESTDIR}${SHLIBDIR}; \
|
||||
if [ ! -e ${LCRYPTSO} ]; then \
|
||||
rm -f ${LCRYPTSO}; \
|
||||
ln -sf ${LSCRYPTSO} ${LCRYPTSO}; \
|
||||
fi
|
||||
.if !exists(${DESTDIR}${LIBDIR}/${LCRYPTBASE}.a)
|
||||
SYMLINKS+= ${LSCRYPTBASE}.a ${LIBDIR}/${LCRYPTBASE}.a
|
||||
.endif
|
||||
.if !defined(NOPIC) && ${OBJFORMAT} == elf
|
||||
@cd ${DESTDIR}${SHLIBDIR}; \
|
||||
if [ ! -e ${LCRYPTBASE}.so ]; then \
|
||||
rm -f ${LCRYPTBASE}.so; \
|
||||
ln -sf ${LSCRYPTBASE}.so libcrypt.so; \
|
||||
fi
|
||||
.if !defined(NOPROFILE) && !exists(${DESTDIR}${LIBDIR}/${LCRYPTBASE}_p.a)
|
||||
SYMLINKS+= ${LSCRYPTBASE}_p.a ${LIBDIR}/${LCRYPTBASE}_p.a
|
||||
.endif
|
||||
@cd ${DESTDIR}${LIBDIR}; \
|
||||
if [ ! -e ${LCRYPTBASE}.a ]; then \
|
||||
rm -f ${LCRYPTBASE}.a; \
|
||||
ln -sf ${LSCRYPTBASE}.a libcrypt.a; \
|
||||
fi
|
||||
.if !defined(NOPROFILE)
|
||||
@cd ${DESTDIR}${LIBDIR}; \
|
||||
if [ ! -e ${LCRYPTBASE}_p.a ]; then \
|
||||
rm -f ${LCRYPTBASE}_p.a; \
|
||||
ln -sf ${LSCRYPTBASE}_p.a libcrypt_p.a; \
|
||||
fi
|
||||
.if !defined(NOPIC) && !exists(${DESTDIR}${SHLIBDIR}/${LCRYPTSO})
|
||||
SYMLINKS+= ${LSCRYPTSO} ${SHLIBDIR}/${LCRYPTSO}
|
||||
.endif
|
||||
.if !defined(NOPIC) && ${OBJFORMAT} == elf && \
|
||||
!exists(${DESTDIR}${SHLIBDIR}/${LCRYPTBASE}.so)
|
||||
SYMLINKS+= ${LSCRYPTBASE}.so ${SHLIBDIR}/${LCRYPTBASE}.so
|
||||
.endif
|
||||
|
||||
.include <bsd.lib.mk>
|
||||
|
|
Loading…
Reference in a new issue