1998-10-08 18:40:27 +08:00
|
|
|
# Makefile for rpm library.
|
|
|
|
|
2002-12-01 06:15:29 +08:00
|
|
|
LINT = splint
|
|
|
|
|
2007-08-05 16:30:55 +08:00
|
|
|
AM_CPPFLAGS = -I. \
|
2002-07-22 06:06:19 +08:00
|
|
|
-I$(top_srcdir) \
|
2001-05-08 08:03:14 +08:00
|
|
|
-I$(top_srcdir)/build \
|
|
|
|
-I$(top_srcdir)/rpmdb \
|
|
|
|
-I$(top_srcdir)/rpmio \
|
2003-05-23 05:21:43 +08:00
|
|
|
@WITH_BEECRYPT_INCLUDE@ \
|
2005-02-17 10:36:37 +08:00
|
|
|
@WITH_POPT_INCLUDE@ \
|
2005-01-18 07:58:09 +08:00
|
|
|
-I$(top_srcdir)/misc \
|
2001-05-08 08:03:14 +08:00
|
|
|
@INCPATH@
|
1998-10-08 18:40:27 +08:00
|
|
|
|
2007-08-09 15:13:05 +08:00
|
|
|
EXTRA_DIST = getdate.y
|
2004-10-10 13:30:48 +08:00
|
|
|
|
2007-08-09 15:13:05 +08:00
|
|
|
EXTRA_PROGRAMS =
|
2000-03-23 23:49:50 +08:00
|
|
|
|
1999-01-27 02:08:14 +08:00
|
|
|
pkgincdir = $(pkgincludedir)
|
|
|
|
pkginc_HEADERS = \
|
2002-05-20 02:42:25 +08:00
|
|
|
misc.h rpmcli.h rpmlib.h \
|
2004-10-18 09:08:56 +08:00
|
|
|
rpmal.h rpmds.h rpmfi.h rpmgi.h rpmps.h rpmsx.h rpmte.h rpmts.h \
|
2004-10-10 13:30:48 +08:00
|
|
|
stringbuf.h
|
1998-10-08 18:40:27 +08:00
|
|
|
|
2000-08-28 03:19:44 +08:00
|
|
|
LIBS =
|
1999-11-10 04:57:38 +08:00
|
|
|
|
2007-07-25 22:10:57 +08:00
|
|
|
usrlibdir = $(libdir)
|
2002-12-02 05:34:06 +08:00
|
|
|
usrlib_LTLIBRARIES = librpm.la
|
1999-01-23 02:42:31 +08:00
|
|
|
librpm_la_SOURCES = \
|
2007-08-10 20:10:52 +08:00
|
|
|
cpio.c cpio.h depends.c formats.c fs.c fsm.c fsm.h getdate.c \
|
|
|
|
manifest.c manifest.h misc.c package.c \
|
|
|
|
poptALL.c poptI.c poptQV.c psm.c psm.h query.c \
|
2004-10-18 09:08:56 +08:00
|
|
|
rpmal.c rpmchecksig.c rpmds.c rpmfi.c rpmgi.c rpminstall.c \
|
2007-08-10 20:10:52 +08:00
|
|
|
rpmlead.c rpmlead.h rpmlibprov.c rpmps.c rpmrc.c rpmsx.c rpmte.c rpmts.c \
|
|
|
|
rpmvercmp.c signature.c signature.h stringbuf.c transaction.c \
|
|
|
|
verify.c rpmlock.c rpmlock.h
|
2007-08-20 10:31:21 +08:00
|
|
|
librpm_la_LDFLAGS = -release 4.4 \
|
2002-12-15 05:39:19 +08:00
|
|
|
$(top_builddir)/rpmdb/librpmdb.la \
|
|
|
|
$(top_builddir)/rpmio/librpmio.la \
|
2005-02-17 10:36:37 +08:00
|
|
|
@WITH_POPT_LIB@ \
|
2005-01-18 07:58:09 +08:00
|
|
|
@WITH_SELINUX_LIB@ \
|
2007-07-24 19:21:32 +08:00
|
|
|
@LIBINTL@
|
2000-06-08 07:25:41 +08:00
|
|
|
|
2001-03-05 01:31:48 +08:00
|
|
|
getdate.c: getdate.y
|
|
|
|
@echo expect 10 shift/reduce conflicts
|
|
|
|
$(YACC) $(srcdir)/getdate.y
|
|
|
|
-@if test -f y.tab.c; then \
|
2001-06-04 21:55:58 +08:00
|
|
|
{ echo "/*@-globstate -statictrans -unqualifiedtrans -noparams @*/";\
|
2001-05-07 03:17:14 +08:00
|
|
|
echo "/*@-retvalint -usedef -varuse -nullderef -nullassign @*/";\
|
2001-10-16 22:58:57 +08:00
|
|
|
echo "/*@-readonlytrans -modunconnomods -compdef -noeffectuncon @*/";\
|
2001-10-16 01:53:34 +08:00
|
|
|
echo "/*@-globs -evalorderuncon -modobserveruncon -modnomods @*/";\
|
2001-10-18 00:43:36 +08:00
|
|
|
echo "/*@unused@*/";\
|
2001-05-07 03:17:14 +08:00
|
|
|
sed -e 's,y.tab.c,getdate.c,' y.tab.c \
|
|
|
|
-e 's,^YYSTYPE ,static &,' \
|
|
|
|
-e 's,^short ,static &,' \
|
|
|
|
-e 's,^const short ,static &,' \
|
|
|
|
-e 's,^int yydebug,/*@unused@*/ static &,' \
|
|
|
|
-e 's,^int ,static &,' ;\
|
2001-10-16 01:53:34 +08:00
|
|
|
echo "/*@=globs =evalorderuncon =modobserveruncon =modnomods @*/";\
|
2001-10-16 22:58:57 +08:00
|
|
|
echo "/*@=readonlytrans =modunconnomods =compdef =noeffectuncon @*/";\
|
2001-05-07 03:17:14 +08:00
|
|
|
echo "/*@=retvalint =usedef =varuse =nullderef =nullassign @*/";\
|
2001-06-04 21:55:58 +08:00
|
|
|
echo "/*@=globstate =statictrans =unqualifiedtrans =noparams @*/";\
|
2001-04-30 06:43:01 +08:00
|
|
|
} > getdate.c ;\
|
|
|
|
rm -f y.tab.c; \
|
2001-03-05 01:31:48 +08:00
|
|
|
else \
|
|
|
|
if test -f getdate.tab.c ; then \
|
|
|
|
mv getdate.tab.c getdate.c ; \
|
|
|
|
else \
|
|
|
|
echo '*** Unable to create getdate.c' ;\
|
|
|
|
fi ;\
|
|
|
|
fi
|
|
|
|
|
2002-06-26 02:43:40 +08:00
|
|
|
BUILT_SOURCES = getdate.c # rpmlib.lcd
|
2002-06-23 02:51:56 +08:00
|
|
|
|
2007-08-10 20:10:52 +08:00
|
|
|
rpmlib.lcd: Makefile.am ${librpm_la_SOURCES} ${pkginc_HEADERS}
|
2007-08-05 16:30:55 +08:00
|
|
|
-lclint ${DEFS} ${AM_CPPFLAGS} ${librpm_la_SOURCES} -dump $@ 2>/dev/null
|
1998-11-21 04:18:22 +08:00
|
|
|
|
2001-05-04 05:00:18 +08:00
|
|
|
.PHONY: sources
|
|
|
|
sources:
|
|
|
|
@echo $(librpm_la_SOURCES:%=lib/%)
|
|
|
|
|
2002-12-01 06:15:29 +08:00
|
|
|
.PHONY: lint
|
|
|
|
lint:
|
2007-08-05 16:30:55 +08:00
|
|
|
$(LINT) $(DEFS) $(AM_CPPFLAGS) $(librpm_la_SOURCES)
|
1999-04-21 03:17:23 +08:00
|
|
|
|
2007-08-15 19:42:05 +08:00
|
|
|
if SELINUX
|
2007-08-09 15:13:05 +08:00
|
|
|
EXTRA_PROGRAMS += setfiles
|
|
|
|
setfiles_SOURCES = setfiles.c
|
|
|
|
setfiles_LDFLAGS = @LDFLAGS_STATIC@
|
|
|
|
setfiles_LDADD = -lselinux \
|
|
|
|
../rpmio/librpmio.la \
|
|
|
|
@WITH_POPT_LIB@
|
2007-08-15 19:42:05 +08:00
|
|
|
endif
|
|
|
|
|
2007-08-12 12:12:21 +08:00
|
|
|
EXTRA_PROGRAMS += tds
|
|
|
|
tds_SOURCES = tds.c
|
|
|
|
tds_LDADD = librpm.la
|
2007-08-09 15:13:05 +08:00
|
|
|
|
|
|
|
EXTRA_PROGRAMS += trb
|
|
|
|
trb_SOURCES = trb.c
|
|
|
|
#trb_LDFLAGS = @LDFLAGS_STATIC@
|
|
|
|
trb_LDADD = librpm.la
|
|
|
|
|
|
|
|
EXTRA_PROGRAMS += tthread
|
|
|
|
tthread_SOURCES = tthread.c
|
|
|
|
tthread_LDFLAGS =
|
|
|
|
tthread_LDADD = librpm.la @WITH_LIBELF_LIB@
|
|
|
|
|
|
|
|
EXTRA_PROGRAMS += tsystem
|
|
|
|
tsystem_SOURCES = tsystem.c
|
|
|
|
tsystem_LDFLAGS =
|
|
|
|
tsystem_LDADD = ../rpmio/librpmio.la @WITH_POPT_LIB@
|
|
|
|
|
|
|
|
EXTRA_PROGRAMS += tre
|
|
|
|
tre_SOURCES = tre.c
|
|
|
|
tre_LDFLAGS =
|
|
|
|
tre_LDADD = librpm.la -lselinux
|
|
|
|
|
|
|
|
EXTRA_PROGRAMS += tcpu
|
|
|
|
tcpu_SOURCES = tcpu.c
|
|
|
|
# tcpu_LDFLAGS = @LDFLAGS_STATIC@
|
|
|
|
tcpu_LDADD = librpm.la
|
|
|
|
|
|
|
|
EXTRA_PROGRAMS += tplatform
|
|
|
|
tplatform_SOURCES = tplatform.c
|
|
|
|
# tplatform_LDFLAGS = @LDFLAGS_STATIC@
|
|
|
|
tplatform_LDADD = librpm.la
|
|
|
|
|
|
|
|
EXTRA_PROGRAMS += tgi
|
2004-10-18 09:08:56 +08:00
|
|
|
tgi_SOURCES = tgi.c
|
2007-08-09 15:13:05 +08:00
|
|
|
# tgi_LDFLAGS = @LDFLAGS_STATIC@
|
2004-10-10 13:30:48 +08:00
|
|
|
tgi_LDADD = librpm.la
|
2007-08-09 15:13:05 +08:00
|
|
|
|
|
|
|
CLEANFILES = $(EXTRA_PROGRAMS)
|