Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Define var using localstatedir and use rsync #4797

Closed
wants to merge 42 commits into from
Closed
Changes from 1 commit
Commits
Show all changes
42 commits
Select commit Hold shift + click to select a range
fc7e46d
spksrc: Create new staging/_var directory tree
th0ma7 Aug 18, 2021
5108254
spksrc: Do not copy empty folders from staging
th0ma7 Aug 18, 2021
464d211
spksrc: By default define LOCALSTATEDIR and --localstatedir
th0ma7 Aug 18, 2021
089eded
installer.dsm7: Use rsync, backup, and install new files at dest
th0ma7 Aug 18, 2021
09dcf94
spksrc: Fix typo ETC -> VAR
th0ma7 Aug 18, 2021
678753f
spksrc: Code alignment to previous entry
th0ma7 Aug 18, 2021
a61e111
mk: Only apply --localstatedir when >= DSM-7.0
th0ma7 Sep 8, 2021
ba4d2af
directories.mk: Add STAGING_INSTALL_PREFIX_VAR and adjust to _var
th0ma7 Sep 8, 2021
a460056
zap2epg: Use new STAGING_INSTALL_PREFIX_VAR variable
th0ma7 Sep 8, 2021
53fd214
spksrc.service.installer.dsm7: Remove backup as unecessary
th0ma7 Sep 8, 2021
05c91bc
directories.mk: INSTALL_PREFIX_VAR must point to target/../var
th0ma7 Sep 10, 2021
ef725d0
Migrate cross/* to using *INSTALL_PREFIX_VAR as needed
th0ma7 Sep 10, 2021
c08216c
spk/* Migrate to using STAGING_SPKVAR
th0ma7 Sep 10, 2021
addccb6
directories.mk: Only set target/../var when building from spk/*
th0ma7 Sep 10, 2021
0d06520
mk: Fix var from spk/* and output [var] value at configure time
th0ma7 Sep 10, 2021
7f06b3f
copy.mk: noarch may have no staging/_var directory
th0ma7 Sep 13, 2021
8f10f47
copy.mk: Fix conditional copying
th0ma7 Sep 14, 2021
7f45735
demoservice: Add README files to other generic directories
th0ma7 Sep 28, 2021
3925409
copy.mk: Manage staging/_var copy for DSM >= 7.0
th0ma7 Sep 28, 2021
f02919f
spk.mk: Also include files in staging root directory in package.tgz
th0ma7 Sep 28, 2021
e45074d
copy,mk: Embed creation of staging directory due to parallel build
th0ma7 Sep 28, 2021
7e7b8c9
installer.dsm7: Use tmp directory for DSM6->7 migration
th0ma7 Sep 28, 2021
01b0673
copy.mk: mkdir also needed for DSM <= 6
th0ma7 Sep 28, 2021
cf592e7
copy.mk: Fix _var when empty use case
th0ma7 Sep 29, 2021
0c379d1
salt-master: Fix package creation due to missing privilege file
th0ma7 Sep 29, 2021
0418a4f
installer.dsm7: Fix pre and postupgrade
th0ma7 Sep 30, 2021
e0bf76f
directories.mk: Provide more info in comment and fix typo
th0ma7 Oct 1, 2021
c0ece06
squidguard: Fix conflicts after rebase against master with #4695
th0ma7 Oct 1, 2021
f2563a5
ffsync: Use default target path
th0ma7 Oct 1, 2021
ca2e84f
squidguard: Make config refer to INSTALL_PREFIX_VAR dynamically
th0ma7 Oct 1, 2021
9644d77
c-icap: Change config dynamically and refer to INSTALL_PREFIX_VAR
th0ma7 Oct 1, 2021
a035c0c
squidclamav: Refer to INSTALL_PREFIX_VAR when updating config
th0ma7 Oct 1, 2021
51fa616
squidguard: Use INSTALL_PREFIX_VAR for db and logs
th0ma7 Oct 1, 2021
effcf7d
squidguardmanager: Use STAGING_INSTALL_PREFIX_VAR for installation
th0ma7 Oct 1, 2021
a749fd5
install.mk: Manage PLIST for target/../ when building for DSM >= 7
th0ma7 Oct 2, 2021
4ef3975
spk/*: Migrate SYNOPKG_PKGDEST/var to SYNOPKG_SPKVAR
th0ma7 Oct 5, 2021
3cd7dc4
pre-check.mk: Add option to declare broken packages
th0ma7 Oct 6, 2021
b385c9b
directories.mk: Add missing endif after rebasing to master
th0ma7 Oct 25, 2021
8f743a4
mutt: Fix Muttrc creation after master rebasing
th0ma7 Oct 26, 2021
f88a46b
sickchill: Back to being fully functional
th0ma7 Nov 20, 2021
fc48fa1
umurmur: Missing separator
th0ma7 Dec 8, 2021
062e3a1
kiwix: Migrate to using STAGING_SPKVAR
th0ma7 Dec 8, 2021
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
install.mk: Manage PLIST for target/../ when building for DSM >= 7
th0ma7 committed Dec 8, 2021
commit a749fd5843a90790c9265c789c90a3fe54c1380d
16 changes: 13 additions & 3 deletions mk/spksrc.install.mk
Original file line number Diff line number Diff line change
@@ -24,6 +24,16 @@ INSTALL_COOKIE = $(WORK_DIR)/.$(COOKIE_PREFIX)install_done
INSTALL_PLIST = $(WORK_DIR)/$(PKG_NAME).plist
PRE_INSTALL_PLIST = $(INSTALL_PLIST).tmp

# Define find search path for creating plist
ifeq ($(call version_ge, ${TCVERSION}, 7.0),1)
ifeq ($(lastword $(subst /, ,$(INSTALL_PREFIX))),target)
PLIST_SEARCH_PATH = $(INSTALL_DIR)/$(INSTALL_PREFIX)/../
endif
endif
ifeq ($(strip $(PLIST_SEARCH_PATH)),)
PLIST_SEARCH_PATH = $(INSTALL_DIR)/$(INSTALL_PREFIX)/
endif

$(PRE_INSTALL_PLIST): install_msg_target
ifeq ($(strip $(PRE_INSTALL_TARGET)),)
PRE_INSTALL_TARGET = pre_install_target
@@ -48,7 +58,7 @@ install_msg_target:
$(PRE_INSTALL_PLIST):
$(create_target_dir)
@mkdir -p $(INSTALL_DIR)/$(INSTALL_PREFIX) $(INSTALL_DIR)/$(INSTALL_PREFIX_VAR)
find $(INSTALL_DIR)/$(INSTALL_PREFIX)/ \! -type d -printf '%P\n' | sort > $@
find $(PLIST_SEARCH_PATH) \! -type d -printf '%P\n' | sed 's?^target/??g' | sort > $@

pre_install_target: install_msg_target $(PRE_INSTALL_PLIST)

@@ -61,8 +71,8 @@ install_destdir_target: $(PRE_INSTALL_TARGET)
post_install_target: $(INSTALL_TARGET)

$(INSTALL_PLIST):
find $(INSTALL_DIR)/$(INSTALL_PREFIX)/ \! -type d -printf '%P\n' | sort | \
diff $(PRE_INSTALL_PLIST) - | grep '>' | cut -d' ' -f2- > $@
find $(PLIST_SEARCH_PATH)/ \! -type d -printf '%P\n' | sed 's?^target/??g' | sort | \
diff $(PRE_INSTALL_PLIST) - | grep '>' | sed 's?> ??g' > $@
# Generate $(PKG_NAME).plist.auto for newly added files (diff against .tmp)
comm -3 $(PRE_INSTALL_PLIST) $(INSTALL_PLIST) > $(INSTALL_PLIST).auto