fixed autoconf installation

This commit is contained in:
Roland Gruber 2016-10-09 10:37:35 +02:00
parent 0813e24b7a
commit cd46b06dd4
2 changed files with 7 additions and 5 deletions

View File

@ -68,7 +68,7 @@ install-lam:
(cd $(srcdir) ; $(COPY) $${i}/.htaccess \ (cd $(srcdir) ; $(COPY) $${i}/.htaccess \
$(DESTDIR)$(localstatedir)/$${i}) ; \ $(DESTDIR)$(localstatedir)/$${i}) ; \
done ; \ done ; \
LIST4="`(cd $(srcdir)/$(LIST3) ; ls -d * | $(GREP) -v sample)`" ; \ LIST4="`(cd $(srcdir)/$(LIST3) ; ls -d *)`" ; \
(cd $(srcdir)/$(LIST3) ; $(TAR) cf - .) | \ (cd $(srcdir)/$(LIST3) ; $(TAR) cf - .) | \
(cd $(DESTDIR)$(sysconfdir) ; $(TAR) xf -) ; \ (cd $(DESTDIR)$(sysconfdir) ; $(TAR) xf -) ; \
$(LN_S) $(sysconfdir) ${LIST3} ; \ $(LN_S) $(sysconfdir) ${LIST3} ; \
@ -91,10 +91,11 @@ do-chown:
@for i in $(LIST2) ; do \ @for i in $(LIST2) ; do \
$(CHOWN) $(HTTPD_USER):$(HTTPD_GROUP) $(DESTDIR)$(localstatedir)/$${i} ; \ $(CHOWN) $(HTTPD_USER):$(HTTPD_GROUP) $(DESTDIR)$(localstatedir)/$${i} ; \
done ; \ done ; \
LIST4="`(cd $(srcdir)/$(LIST3) ; ls -d * | $(GREP) -v sample)`" ; \ LIST4="`(cd $(srcdir)/$(LIST3) ; ls -d *)`" ; \
for i in $${LIST4} ; do \ for i in $${LIST4} ; do \
$(CHOWN) -R $(HTTPD_USER):$(HTTPD_GROUP) $(DESTDIR)$(sysconfdir)/$${i} ; \ $(CHOWN) -R $(HTTPD_USER):$(HTTPD_GROUP) $(DESTDIR)$(sysconfdir)/$${i} ; \
done done
$(CHOWN) $(HTTPD_USER):$(HTTPD_GROUP) $(DESTDIR)$(sysconfdir)/config
echo-chown: echo-chown:
@ -103,11 +104,12 @@ echo-chown:
echo "$(CHOWN) $(HTTPD_USER):$(HTTPD_GROUP) $(DESTDIR)$(localstatedir)/$${i}" \ echo "$(CHOWN) $(HTTPD_USER):$(HTTPD_GROUP) $(DESTDIR)$(localstatedir)/$${i}" \
>> $(RAR) ; \ >> $(RAR) ; \
done ; \ done ; \
LIST4="`(cd $(srcdir)/$(LIST3) ; ls -d * | $(GREP) -v sample)`" ; \ LIST4="`(cd $(srcdir)/$(LIST3) ; ls -d *)`" ; \
for i in $${LIST4} ; do \ for i in $${LIST4} ; do \
echo "$(CHOWN) -R $(HTTPD_USER):$(HTTPD_GROUP) $(DESTDIR)$(sysconfdir)/$${i}" \ echo "$(CHOWN) -R $(HTTPD_USER):$(HTTPD_GROUP) $(DESTDIR)$(sysconfdir)/$${i}" \
>> $(RAR) ; \ >> $(RAR) ; \
done ; \ done ; \
echo $(CHOWN) $(HTTPD_USER):$(HTTPD_GROUP) $(DESTDIR)$(sysconfdir)/config
echo "Switch user to root and run $(RAR)" echo "Switch user to root and run $(RAR)"

View File

@ -114,7 +114,7 @@ function upgradeConfigToServerProfileFolders($profiles) {
// copy default configs // copy default configs
if (!file_exists('../config/templates')) { if (!file_exists('../config/templates')) {
@mkdir('../config/templates'); @mkdir('../config/templates', 0700);
recursiveCopy('../config/pdf/', '../config/templates/pdf/', $profiles, 'default.'); recursiveCopy('../config/pdf/', '../config/templates/pdf/', $profiles, 'default.');
recursiveCopy('../config/profiles/', '../config/templates/profiles/', $profiles, 'default.'); recursiveCopy('../config/profiles/', '../config/templates/profiles/', $profiles, 'default.');
} }
@ -163,7 +163,7 @@ function copyConfigTemplates($profiles) {
function recursiveCopy($src, $dst, $profiles, $fileFilter = null, $overwrite = true) { function recursiveCopy($src, $dst, $profiles, $fileFilter = null, $overwrite = true) {
$dir = @opendir($src); $dir = @opendir($src);
if (!file_exists($dst)) { if (!file_exists($dst)) {
$tmpState = @mkdir($dst); $tmpState = @mkdir($dst, 0700, true);
if ($tmpState === false) { if ($tmpState === false) {
StatusMessage('ERROR', 'Upgrade failed.', 'The directory \'' . $dst . '\' could not be created.'); StatusMessage('ERROR', 'Upgrade failed.', 'The directory \'' . $dst . '\' could not be created.');
} }