Pārlūkot izejas kodu

Makefile: updated paths for installing the tools

Daniel-Constantin Mierla 8 gadi atpakaļ
vecāks
revīzija
1d8de2153c
2 mainītis faili ar 22 papildinājumiem un 22 dzēšanām
  1. 20 20
      src/Makefile
  2. 2 2
      src/Makefile.modules

+ 20 - 20
src/Makefile

@@ -202,7 +202,7 @@ cmodules=$(foreach mods,$(modules_dirs), $($(mods)))
 
 
 
 
 # list of utils directories that should be compiled by make utils
 # list of utils directories that should be compiled by make utils
-C_COMPILE_UTILS=	utils/kamcmd
+C_COMPILE_UTILS=	../utils/kamcmd
 # list of binaries that should be installed alongside
 # list of binaries that should be installed alongside
 # (they should be created after make utils, see C_COMPILE_UTILS)
 # (they should be created after make utils, see C_COMPILE_UTILS)
 C_INSTALL_BIN=	# kamcmd is now installed by ctl
 C_INSTALL_BIN=	# kamcmd is now installed by ctl
@@ -210,7 +210,7 @@ C_INSTALL_BIN=	# kamcmd is now installed by ctl
 # which utils know to install themselves and should be installed
 # which utils know to install themselves and should be installed
 # along the core (list of utils directories)
 # along the core (list of utils directories)
 ifeq ($(FLAVOUR),kamailio)
 ifeq ($(FLAVOUR),kamailio)
-C_INSTALL_UTILS= utils/kamctl
+C_INSTALL_UTILS= ../utils/kamctl
 else
 else
 C_INSTALL_UTILS=
 C_INSTALL_UTILS=
 endif
 endif
@@ -697,11 +697,11 @@ $(man_prefix)/$(man_dir)/man5:
 
 
 # note: sed with POSIX.1 regex doesn't support |, + or ? (darwin, solaris ...) 
 # note: sed with POSIX.1 regex doesn't support |, + or ? (darwin, solaris ...) 
 install-cfg: $(cfg_prefix)/$(cfg_dir)
 install-cfg: $(cfg_prefix)/$(cfg_dir)
-	@if [ -f etc/$(CFG_NAME).cfg ]; then \
+	@if [ -f ../etc/$(CFG_NAME).cfg ]; then \
 			sed $(foreach m,$(modules_dirs),\
 			sed $(foreach m,$(modules_dirs),\
 					-e "s#/usr/[^:]*lib/$(CFG_NAME)/$(m)\([:/\"]\)#$($(m)_target)\1#g") \
 					-e "s#/usr/[^:]*lib/$(CFG_NAME)/$(m)\([:/\"]\)#$($(m)_target)\1#g") \
 					-e "s#/usr/local/etc/$(CFG_NAME)/#$(cfg_target)#g" \
 					-e "s#/usr/local/etc/$(CFG_NAME)/#$(cfg_target)#g" \
-				< etc/$(CFG_NAME).cfg \
+				< ../etc/$(CFG_NAME).cfg \
 				> $(cfg_prefix)/$(cfg_dir)$(MAIN_NAME).cfg.sample; \
 				> $(cfg_prefix)/$(cfg_dir)$(MAIN_NAME).cfg.sample; \
 			chmod 644 $(cfg_prefix)/$(cfg_dir)$(MAIN_NAME).cfg.sample; \
 			chmod 644 $(cfg_prefix)/$(cfg_dir)$(MAIN_NAME).cfg.sample; \
 			if [ -z "${skip_cfg_install}" -a \
 			if [ -z "${skip_cfg_install}" -a \
@@ -710,11 +710,11 @@ install-cfg: $(cfg_prefix)/$(cfg_dir)
 					$(cfg_prefix)/$(cfg_dir)$(MAIN_NAME).cfg; \
 					$(cfg_prefix)/$(cfg_dir)$(MAIN_NAME).cfg; \
 			fi; \
 			fi; \
 		fi
 		fi
-	@if [ -f etc/$(CFG_NAME)-basic.cfg ]; then \
+	@if [ -f ../etc/$(CFG_NAME)-basic.cfg ]; then \
 			sed $(foreach m,$(modules_dirs),\
 			sed $(foreach m,$(modules_dirs),\
 					-e "s#/usr/[^:]*lib/$(CFG_NAME)/$(m)\([:/\"]\)#$($(m)_target)\1#g") \
 					-e "s#/usr/[^:]*lib/$(CFG_NAME)/$(m)\([:/\"]\)#$($(m)_target)\1#g") \
 					-e "s#/usr/local/etc/$(CFG_NAME)/#$(cfg_target)#g" \
 					-e "s#/usr/local/etc/$(CFG_NAME)/#$(cfg_target)#g" \
-				< etc/$(CFG_NAME)-basic.cfg \
+				< ../etc/$(CFG_NAME)-basic.cfg \
 				> $(cfg_prefix)/$(cfg_dir)$(MAIN_NAME)-basic.cfg.sample; \
 				> $(cfg_prefix)/$(cfg_dir)$(MAIN_NAME)-basic.cfg.sample; \
 			chmod 644 $(cfg_prefix)/$(cfg_dir)$(MAIN_NAME)-basic.cfg.sample; \
 			chmod 644 $(cfg_prefix)/$(cfg_dir)$(MAIN_NAME)-basic.cfg.sample; \
 			if [ -z "${skip_cfg_install}" -a \
 			if [ -z "${skip_cfg_install}" -a \
@@ -723,11 +723,11 @@ install-cfg: $(cfg_prefix)/$(cfg_dir)
 					$(cfg_prefix)/$(cfg_dir)$(MAIN_NAME)-basic.cfg; \
 					$(cfg_prefix)/$(cfg_dir)$(MAIN_NAME)-basic.cfg; \
 			fi; \
 			fi; \
 		fi
 		fi
-	@if [ -f etc/$(CFG_NAME)-oob.cfg ]; then \
+	@if [ -f ../etc/$(CFG_NAME)-oob.cfg ]; then \
 			sed $(foreach m,$(modules_dirs),\
 			sed $(foreach m,$(modules_dirs),\
 					-e "s#/usr/[^:]*lib/$(CFG_NAME)/$(m)\([:/\"]\)#$($(m)_target)\1#g") \
 					-e "s#/usr/[^:]*lib/$(CFG_NAME)/$(m)\([:/\"]\)#$($(m)_target)\1#g") \
 					-e "s#/usr/local/etc/$(CFG_NAME)/#$(cfg_target)#g" \
 					-e "s#/usr/local/etc/$(CFG_NAME)/#$(cfg_target)#g" \
-				< etc/$(CFG_NAME)-oob.cfg \
+				< ../etc/$(CFG_NAME)-oob.cfg \
 				> $(cfg_prefix)/$(cfg_dir)$(MAIN_NAME)-advanced.cfg.sample; \
 				> $(cfg_prefix)/$(cfg_dir)$(MAIN_NAME)-advanced.cfg.sample; \
 			chmod 644 $(cfg_prefix)/$(cfg_dir)$(MAIN_NAME)-advanced.cfg.sample; \
 			chmod 644 $(cfg_prefix)/$(cfg_dir)$(MAIN_NAME)-advanced.cfg.sample; \
 			if [ -z "${skip_cfg_install}" -a \
 			if [ -z "${skip_cfg_install}" -a \
@@ -763,7 +763,7 @@ install-cfg: $(cfg_prefix)/$(cfg_dir)
 			: ; done; true
 			: ; done; true
 	@# radius dictionary
 	@# radius dictionary
 	@$(INSTALL_TOUCH) $(cfg_prefix)/$(cfg_dir)/dictionary.$(CFG_NAME)
 	@$(INSTALL_TOUCH) $(cfg_prefix)/$(cfg_dir)/dictionary.$(CFG_NAME)
-	@$(INSTALL_CFG) etc/dictionary.$(CFG_NAME) $(cfg_prefix)/$(cfg_dir)
+	@$(INSTALL_CFG) ../etc/dictionary.$(CFG_NAME) $(cfg_prefix)/$(cfg_dir)
 	@echo "config files installed"
 	@echo "config files installed"
 
 
 install-bin: $(bin_prefix)/$(bin_dir) $(NAME)
 install-bin: $(bin_prefix)/$(bin_dir) $(NAME)
@@ -839,16 +839,16 @@ install-modules-all: install-every-module install-every-module-doc
 
 
 
 
 install-doc: $(doc_prefix)/$(doc_dir) install-every-module-doc
 install-doc: $(doc_prefix)/$(doc_dir) install-every-module-doc
-	$(INSTALL_TOUCH) $(doc_prefix)/$(doc_dir)/INSTALL 
-	$(INSTALL_DOC) INSTALL $(doc_prefix)/$(doc_dir)
-	$(INSTALL_TOUCH) $(doc_prefix)/$(doc_dir)/README-MODULES 
-	$(INSTALL_DOC) README-MODULES $(doc_prefix)/$(doc_dir)
-	$(INSTALL_TOUCH) $(doc_prefix)/$(doc_dir)/AUTHORS 
-	$(INSTALL_DOC) AUTHORS $(doc_prefix)/$(doc_dir)
+	$(INSTALL_TOUCH) $(doc_prefix)/$(doc_dir)/INSTALL
+	$(INSTALL_DOC) ../INSTALL $(doc_prefix)/$(doc_dir)
+	$(INSTALL_TOUCH) $(doc_prefix)/$(doc_dir)/README-MODULES
+	$(INSTALL_DOC) ../README-MODULES $(doc_prefix)/$(doc_dir)
+	$(INSTALL_TOUCH) $(doc_prefix)/$(doc_dir)/AUTHORS
+	$(INSTALL_DOC) ../AUTHORS $(doc_prefix)/$(doc_dir)
 	$(INSTALL_TOUCH) $(doc_prefix)/$(doc_dir)/NEWS
 	$(INSTALL_TOUCH) $(doc_prefix)/$(doc_dir)/NEWS
-	$(INSTALL_DOC) NEWS $(doc_prefix)/$(doc_dir)
-	$(INSTALL_TOUCH) $(doc_prefix)/$(doc_dir)/README 
-	$(INSTALL_DOC) README $(doc_prefix)/$(doc_dir)
+	$(INSTALL_DOC) ../NEWS $(doc_prefix)/$(doc_dir)
+	$(INSTALL_TOUCH) $(doc_prefix)/$(doc_dir)/README
+	$(INSTALL_DOC) ../README $(doc_prefix)/$(doc_dir)
 
 
 
 
 install-sr-man: $(man_prefix)/$(man_dir)/man8 $(man_prefix)/$(man_dir)/man5
 install-sr-man: $(man_prefix)/$(man_dir)/man8 $(man_prefix)/$(man_dir)/man5
@@ -858,7 +858,7 @@ install-sr-man: $(man_prefix)/$(man_dir)/man8 $(man_prefix)/$(man_dir)/man5
 				-e "s#/usr/lib/$(CFG_NAME)/$(m)\([^_]\)#$($(m)_target)\1#g") \
 				-e "s#/usr/lib/$(CFG_NAME)/$(m)\([^_]\)#$($(m)_target)\1#g") \
 			-e "s#/usr/share/doc/$(CFG_NAME)/#$(doc_target)#g" \
 			-e "s#/usr/share/doc/$(CFG_NAME)/#$(doc_target)#g" \
 			-e "s#$(SRC_NAME)#$(MAIN_NAME)#g" \
 			-e "s#$(SRC_NAME)#$(MAIN_NAME)#g" \
-			< doc/man/$(MAIN_NAME).8 >  \
+			< ../doc/man/$(MAIN_NAME).8 >  \
 							$(man_prefix)/$(man_dir)/man8/$(MAIN_NAME).8
 							$(man_prefix)/$(man_dir)/man8/$(MAIN_NAME).8
 		@chmod 644  $(man_prefix)/$(man_dir)/man8/$(MAIN_NAME).8
 		@chmod 644  $(man_prefix)/$(man_dir)/man8/$(MAIN_NAME).8
 		@sed -e "s#/etc/$(CFG_NAME)/$(CFG_NAME)\.cfg#$(cfg_target)$(MAIN_NAME).cfg#g" \
 		@sed -e "s#/etc/$(CFG_NAME)/$(CFG_NAME)\.cfg#$(cfg_target)$(MAIN_NAME).cfg#g" \
@@ -867,7 +867,7 @@ install-sr-man: $(man_prefix)/$(man_dir)/man8 $(man_prefix)/$(man_dir)/man5
 				-e "s#/usr/lib/$(CFG_NAME)/$(m)\([^_]\)#$($(m)_target)\1#g") \
 				-e "s#/usr/lib/$(CFG_NAME)/$(m)\([^_]\)#$($(m)_target)\1#g") \
 			-e "s#/usr/share/doc/$(CFG_NAME)/#$(doc_target)#g" \
 			-e "s#/usr/share/doc/$(CFG_NAME)/#$(doc_target)#g" \
 			-e "s#$(SRC_NAME)#$(MAIN_NAME)#g" \
 			-e "s#$(SRC_NAME)#$(MAIN_NAME)#g" \
-			< doc/man/$(MAIN_NAME).cfg.5 >  \
+			< ../doc/man/$(MAIN_NAME).cfg.5 >  \
 			$(man_prefix)/$(man_dir)/man5/$(MAIN_NAME).cfg.5
 			$(man_prefix)/$(man_dir)/man5/$(MAIN_NAME).cfg.5
 		@chmod 644  $(man_prefix)/$(man_dir)/man5/$(MAIN_NAME).cfg.5
 		@chmod 644  $(man_prefix)/$(man_dir)/man5/$(MAIN_NAME).cfg.5
 
 

+ 2 - 2
src/Makefile.modules

@@ -266,7 +266,7 @@ $(share_prefix)/$(share_dir):
 ifneq (,$(wildcard doc/Makefile))
 ifneq (,$(wildcard doc/Makefile))
 #doc/Makefile present => we can generate README
 #doc/Makefile present => we can generate README
 
 
-README: doc/*.xml ../../docbook/entities.xml
+README: doc/*.xml ../../../docbook/entities.xml
 	$(MAKE) -C doc $(MOD_NAME).txt
 	$(MAKE) -C doc $(MOD_NAME).txt
 	mv doc/$(MOD_NAME).txt $@
 	mv doc/$(MOD_NAME).txt $@
 
 
@@ -280,7 +280,7 @@ endif
 ifneq (,$(wildcard $(MOD_NAME).xml))
 ifneq (,$(wildcard $(MOD_NAME).xml))
 
 
 $(MOD_NAME).7: $(MOD_NAME).xml
 $(MOD_NAME).7: $(MOD_NAME).xml
-	$(DOCBOOK) -s ../../doc/stylesheets/serdoc2man.xsl $<
+	$(DOCBOOK) -s ../../../doc/stylesheets/serdoc2man.xsl $<
 
 
 man: $(MOD_NAME).7
 man: $(MOD_NAME).7