Build xbps-{bin,cmpver,digest,pkgdb,repo} as static, and install them
as foo.static. Updated README to note the new requirements for it. It will be used to reduce the number of dependencies when building packages in the chroot. --HG-- extra : convert_revision : xtraeme%40gmail.com-20091015222234-360i67zychjge3nh
This commit is contained in:
parent
6798be2f58
commit
865b06be5d
@ -1,5 +1,9 @@
|
|||||||
|
TOPDIR = ../..
|
||||||
|
include $(TOPDIR)/vars.mk
|
||||||
|
|
||||||
BIN = xbps-bin
|
BIN = xbps-bin
|
||||||
OBJS = check.o install.o main.o remove.o show-deps.o ../xbps-repo/util.o
|
OBJS = check.o install.o main.o remove.o show-deps.o ../xbps-repo/util.o
|
||||||
|
STATIC_LIBS += -lz -lacl -lbz2 -llzmadec
|
||||||
|
|
||||||
TOPDIR = ../..
|
|
||||||
include $(TOPDIR)/prog.mk
|
include $(TOPDIR)/prog.mk
|
||||||
|
|
||||||
|
@ -1,4 +1,6 @@
|
|||||||
|
TOPDIR = ../..
|
||||||
|
include $(TOPDIR)/vars.mk
|
||||||
|
|
||||||
BIN = xbps-cmpver
|
BIN = xbps-cmpver
|
||||||
|
|
||||||
TOPDIR = ../..
|
|
||||||
include $(TOPDIR)/prog.mk
|
include $(TOPDIR)/prog.mk
|
||||||
|
@ -1,4 +1,6 @@
|
|||||||
|
TOPDIR = ../..
|
||||||
|
include $(TOPDIR)/vars.mk
|
||||||
|
|
||||||
BIN = xbps-digest
|
BIN = xbps-digest
|
||||||
|
|
||||||
TOPDIR = ../..
|
|
||||||
include $(TOPDIR)/prog.mk
|
include $(TOPDIR)/prog.mk
|
||||||
|
@ -1,4 +1,6 @@
|
|||||||
|
TOPDIR = ../..
|
||||||
|
include $(TOPDIR)/vars.mk
|
||||||
|
|
||||||
BIN = xbps-pkgdb
|
BIN = xbps-pkgdb
|
||||||
|
|
||||||
TOPDIR = ../..
|
|
||||||
include $(TOPDIR)/prog.mk
|
include $(TOPDIR)/prog.mk
|
||||||
|
@ -1,5 +1,8 @@
|
|||||||
|
TOPDIR = ../..
|
||||||
|
include $(TOPDIR)/vars.mk
|
||||||
|
|
||||||
BIN = xbps-repo
|
BIN = xbps-repo
|
||||||
OBJS = main.o util.o index.o
|
OBJS = main.o util.o index.o
|
||||||
|
STATIC_LIBS += -lz -lbz2 -lacl -llzmadec
|
||||||
|
|
||||||
TOPDIR = ../..
|
|
||||||
include $(TOPDIR)/prog.mk
|
include $(TOPDIR)/prog.mk
|
||||||
|
@ -33,8 +33,12 @@ and install xbps binary packages:
|
|||||||
* GNU Make
|
* GNU Make
|
||||||
* GNU Bison
|
* GNU Bison
|
||||||
* fakeroot
|
* fakeroot
|
||||||
* wget
|
* wget OR curl OR fetch
|
||||||
* libarchive (development package)
|
* libarchive (devel package with static library.
|
||||||
|
acl, lzma, bzip2 support)
|
||||||
|
* libacl (devel package with static library)
|
||||||
|
* lzma/xz (devel package with static library)
|
||||||
|
* bzip2 (devel package with static library)
|
||||||
* perl
|
* perl
|
||||||
* sudo
|
* sudo
|
||||||
|
|
||||||
|
15
prog.mk
15
prog.mk
@ -1,23 +1,26 @@
|
|||||||
include $(TOPDIR)/vars.mk
|
BIN_STATIC ?= $(BIN).static
|
||||||
|
|
||||||
OBJS ?= main.o
|
OBJS ?= main.o
|
||||||
|
|
||||||
all: $(BIN)
|
all: $(BIN) $(BIN_STATIC)
|
||||||
.PHONY: all
|
.PHONY: all
|
||||||
|
|
||||||
|
$(BIN_STATIC): $(OBJS)
|
||||||
|
$(CC) -static $^ $(LDFLAGS) $(STATIC_LIBS) -o $@
|
||||||
|
|
||||||
$(BIN): $(OBJS)
|
$(BIN): $(OBJS)
|
||||||
$(CC) $(LDFLAGS) $^ -o $@
|
$(CC) $^ $(LDFLAGS) -o $@
|
||||||
|
|
||||||
.PHONY: clean
|
.PHONY: clean
|
||||||
clean: clean-bins clean-objs
|
clean: clean-bins clean-objs
|
||||||
|
|
||||||
clean-bins:
|
clean-bins:
|
||||||
-rm -f $(BIN)
|
-rm -f $(BIN) $(BIN_STATIC)
|
||||||
|
|
||||||
clean-objs:
|
clean-objs:
|
||||||
-rm -f $(OBJS)
|
-rm -f $(OBJS)
|
||||||
|
|
||||||
.PHONY: install
|
.PHONY: install
|
||||||
install: $(BIN)
|
install: $(BIN) $(BIN_STATIC)
|
||||||
install -d $(SBINDIR)
|
install -d $(SBINDIR)
|
||||||
install $(INSTALL_STRIPPED) -m 755 $(BIN) $(SBINDIR)
|
install $(INSTALL_STRIPPED) -m 755 $(BIN) $(SBINDIR)
|
||||||
|
install $(INSTALL_STRIPPED) -m 755 $(BIN_STATIC) $(SBINDIR)
|
||||||
|
1
vars.mk
1
vars.mk
@ -13,6 +13,7 @@ ETCDIR ?= $(PREFIX)/etc
|
|||||||
TOPDIR ?= ..
|
TOPDIR ?= ..
|
||||||
INSTALL_STRIPPED ?= -s
|
INSTALL_STRIPPED ?= -s
|
||||||
|
|
||||||
|
STATIC_LIBS ?= -lprop -lpthread -larchive
|
||||||
LDFLAGS += -L$(TOPDIR)/lib -L$(PREFIX)/lib -lxbps
|
LDFLAGS += -L$(TOPDIR)/lib -L$(PREFIX)/lib -lxbps
|
||||||
CPPFLAGS += -I$(TOPDIR)/include -D_BSD_SOURCE -D_XOPEN_SOURCE=600
|
CPPFLAGS += -I$(TOPDIR)/include -D_BSD_SOURCE -D_XOPEN_SOURCE=600
|
||||||
CPPFLAGS += -D_GNU_SOURCE
|
CPPFLAGS += -D_GNU_SOURCE
|
||||||
|
Loading…
x
Reference in New Issue
Block a user