1998-10-08 18:40:27 +08:00
|
|
|
# Top level Makefile for rpm
|
|
|
|
|
1999-01-20 07:54:30 +08:00
|
|
|
AUTOMAKE_OPTIONS = 1.4 foreign
|
1998-10-08 18:40:27 +08:00
|
|
|
|
1999-03-18 02:11:01 +08:00
|
|
|
EXTRA_DIST = CHANGES CREDITS GROUPS README.amiga INSTALL RPM-PGP-KEY \
|
1999-01-22 02:42:53 +08:00
|
|
|
autodeps/none autodeps/*.prov autodeps/*.req autogen.sh \
|
1999-07-20 06:20:01 +08:00
|
|
|
gendiff po/*.in po/*.po po/rpm.pot \
|
1999-07-16 06:26:15 +08:00
|
|
|
python/*.am python/*.in python/*.c python/testit \
|
1999-01-22 06:30:50 +08:00
|
|
|
rpm.magic rpmpopt rpm.spec rpm.8ru rpm2cpio.8ru
|
1999-01-22 02:42:53 +08:00
|
|
|
|
1999-04-04 01:13:35 +08:00
|
|
|
EXTRA_PROGRAMS = rpmconvert
|
|
|
|
|
1999-07-16 04:15:23 +08:00
|
|
|
# XXX TODO: python perl
|
1999-07-20 06:13:12 +08:00
|
|
|
SUBDIRS = popt build lib po intl misc tools scripts tests doc .
|
1998-10-08 18:40:27 +08:00
|
|
|
|
1999-04-09 22:15:28 +08:00
|
|
|
INCLUDES = \
|
|
|
|
-I$(top_srcdir)/build \
|
|
|
|
-I$(top_srcdir)/lib \
|
|
|
|
-I$(top_srcdir)/intl \
|
|
|
|
-I$(top_srcdir)/popt \
|
|
|
|
@INCPATH@
|
1998-10-08 18:40:27 +08:00
|
|
|
|
1999-01-23 02:42:31 +08:00
|
|
|
mylibs= $(top_builddir)/build/librpmbuild.la \
|
|
|
|
$(top_builddir)/lib/librpm.la \
|
|
|
|
$(top_builddir)/popt/libpopt.la
|
1999-01-22 06:30:50 +08:00
|
|
|
|
1999-01-26 03:46:40 +08:00
|
|
|
LDFLAGS = @LDFLAGS_STATIC@
|
1998-10-08 18:40:27 +08:00
|
|
|
|
|
|
|
rpmbindir = $(subst usr/bin,bin,$(bindir))
|
|
|
|
rpmbin_PROGRAMS = rpm
|
|
|
|
|
|
|
|
bin_PROGRAMS = rpm2cpio
|
|
|
|
bin_SCRIPTS = gendiff
|
1999-04-04 01:13:35 +08:00
|
|
|
|
1999-04-09 04:09:48 +08:00
|
|
|
noinst_PROGRAMS = @BUILD_RPMCONVERT@
|
1998-10-08 18:40:27 +08:00
|
|
|
|
1999-01-27 02:08:14 +08:00
|
|
|
pkglibdir = @RPMCONFIGDIR@
|
|
|
|
pkglib_DATA = rpmrc rpmpopt macros
|
|
|
|
pkglib_SCRIPTS = find-provides find-requires mkinstalldirs \
|
|
|
|
config.guess config.sub
|
1998-10-08 18:40:27 +08:00
|
|
|
|
|
|
|
noinst_HEADERS = \
|
1999-07-15 00:47:30 +08:00
|
|
|
acconfig.h build.h system.h
|
1998-10-08 18:40:27 +08:00
|
|
|
|
1999-07-15 00:47:30 +08:00
|
|
|
rpm_SOURCES = build.c rpm.c
|
1999-01-23 02:42:31 +08:00
|
|
|
rpm_LDADD = $(mylibs) @LIBMISC@
|
1998-10-08 18:40:27 +08:00
|
|
|
|
1999-01-23 02:42:31 +08:00
|
|
|
$(PROGRAMS): $(mylibs) @LIBMISC@
|
1998-10-08 18:40:27 +08:00
|
|
|
|
1998-11-21 04:18:22 +08:00
|
|
|
.PHONY: lclint
|
|
|
|
lclint:
|
|
|
|
lclint ${DEFS} ${INCLUDES} ${rpm_SOURCES}
|
|
|
|
|
1998-10-08 22:23:53 +08:00
|
|
|
CVSTAG = r$(subst .,-,$(VERSION))
|
|
|
|
|
1998-10-08 18:40:27 +08:00
|
|
|
rpm2cpio_SOURCES = rpm2cpio.c
|
1999-01-23 02:42:31 +08:00
|
|
|
rpm2cpio_LDADD = $(mylibs)
|
1998-10-08 18:40:27 +08:00
|
|
|
|
|
|
|
rpmconvert_SOURCES = convertdb.c oldrpmdb.c
|
1999-06-18 05:35:34 +08:00
|
|
|
## Libmisc.a is required for rpmconvert.
|
|
|
|
rpmconvert_LDADD = $(mylibs) @LIBMISC@ -lgdbm
|
1998-10-08 18:40:27 +08:00
|
|
|
|
|
|
|
install-data-local:
|
1999-04-30 23:55:45 +08:00
|
|
|
@$(mkinstalldirs) $(DESTDIR)$(varprefix)/lib/rpm
|
1998-11-19 05:41:05 +08:00
|
|
|
@rm -f $(DESTDIR)/$(libdir)/rpmrc
|
|
|
|
@ln -s rpm/rpmrc $(DESTDIR)/$(libdir)/rpmrc
|
|
|
|
@rm -f $(DESTDIR)/$(libdir)/rpmpopt
|
|
|
|
@ln -s rpm/rpmpopt $(DESTDIR)/$(libdir)/rpmpopt
|
1998-10-20 21:40:27 +08:00
|
|
|
@$(mkinstalldirs) $(DESTDIR)/$(prefix)/src/redhat/BUILD
|
1999-03-12 14:00:17 +08:00
|
|
|
@case "@build_cpu@" in \
|
|
|
|
*86) $(mkinstalldirs) $(DESTDIR)/$(prefix)/src/redhat/RPMS/i386 ;;\
|
|
|
|
alpha*) $(mkinstalldirs) $(DESTDIR)/$(prefix)/src/redhat/RPMS/alpha ;;\
|
1999-03-14 08:34:52 +08:00
|
|
|
sparc*) $(mkinstalldirs) $(DESTDIR)/$(prefix)/src/redhat/RPMS/sparc ;;\
|
1999-03-28 08:47:40 +08:00
|
|
|
powerpc*) $(mkinstalldirs) $(DESTDIR)/$(prefix)/src/redhat/RPMS/ppc ;;\
|
1999-03-12 14:00:17 +08:00
|
|
|
esac
|
1999-06-18 05:35:34 +08:00
|
|
|
@case "@build_os@" in \
|
|
|
|
mint) $(mkinstalldirs) $(DESTDIR)/$(prefix)/src/redhat/RPMS/m68kmint ;;\
|
1999-06-18 07:28:54 +08:00
|
|
|
*) $(mkinstalldirs) $(DESTDIR)/$(prefix)/src/redhat/RPMS/@build_cpu@ ;;\
|
1999-06-18 05:35:34 +08:00
|
|
|
esac
|
1999-03-14 08:34:52 +08:00
|
|
|
@$(mkinstalldirs) $(DESTDIR)/$(prefix)/src/redhat/RPMS/noarch
|
1998-10-20 21:40:27 +08:00
|
|
|
@$(mkinstalldirs) $(DESTDIR)/$(prefix)/src/redhat/SOURCES
|
|
|
|
@$(mkinstalldirs) $(DESTDIR)/$(prefix)/src/redhat/SPECS
|
|
|
|
@$(mkinstalldirs) $(DESTDIR)/$(prefix)/src/redhat/SRPMS
|
|
|
|
@$(mkinstalldirs) $(DESTDIR)/var/tmp
|
1998-10-08 18:40:27 +08:00
|
|
|
|
|
|
|
.PHONY: tar
|
|
|
|
tar:
|
|
|
|
rm -rf /tmp/rpm-$(VERSION)
|
1999-04-30 23:55:45 +08:00
|
|
|
$(MAKE) DESTDIR=/tmp/rpm-$(VERSION) install
|
1998-10-08 18:40:27 +08:00
|
|
|
cd /tmp/rpm-$(VERSION) ; tar cvf /tmp/rpm-$(VERSION).tar .
|
|
|
|
|
|
|
|
.PHONY: noconfig
|
|
|
|
noconfig:
|
|
|
|
find . -name "Makefile" -exec rm {} \;
|
|
|
|
rm -f *gz *rpm config.*
|
|
|
|
|
|
|
|
.PHONY: archive
|
|
|
|
archive:
|
1999-01-27 05:57:57 +08:00
|
|
|
@cvs -d `cat CVS/Root` diff 2>&1 > /dev/null || { \
|
1999-01-27 03:04:39 +08:00
|
|
|
echo " " ; \
|
|
|
|
echo "==> Please resolve differences between the repository and" ; \
|
|
|
|
echo "==> your rpm check out before tagging." ; \
|
|
|
|
echo " " ; \
|
|
|
|
cvs -n up ; \
|
|
|
|
echo " " ; \
|
|
|
|
exit 1 ; \
|
|
|
|
}
|
|
|
|
@cvs -d `cat CVS/Root` -Q tag -F $(CVSTAG) .
|
1999-01-27 02:08:14 +08:00
|
|
|
@make dist
|
1998-10-08 18:40:27 +08:00
|
|
|
@echo " "
|
|
|
|
@echo "The final archive is ./rpm-$(VERSION).tar.gz."
|
1999-01-27 03:07:25 +08:00
|
|
|
|
|
|
|
.PHONY: nextsrpm
|
1999-01-27 06:25:24 +08:00
|
|
|
nextsrpm: all archive
|
1999-01-27 03:07:25 +08:00
|
|
|
@sudo ./rpm -ta rpm-$(VERSION).tar.gz
|