pkgsrc-WIP-changes archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

pkglint/pkg_developer cleanup



Module Name:	pkgsrc-wip
Committed By:	Frank Kardel <kardel%netbsd.org@localhost>
Pushed By:	kardel
Date:		Thu Jul 23 13:16:50 2020 +0200
Changeset:	16e4b2809e64d132b2f3e1e6f232d85842b0c13e

Modified Files:
	bareos/Makefile
	bareos/Makefile.common
	bareos/distinfo
	bareos/patches/patch-core_scripts_CMakeLists.txt
Added Files:
	bareos/patches/patch-core_cmake_BareosFindPrograms.cmake
	bareos/patches/patch-core_cmake_BareosInstallConfigFiles.cmake
Removed Files:
	bareos/TODO

Log Message:
pkglint/pkg_developer cleanup

To see a diff of this commit:
https://wip.pkgsrc.org/cgi-bin/gitweb.cgi?p=pkgsrc-wip.git;a=commitdiff;h=16e4b2809e64d132b2f3e1e6f232d85842b0c13e

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.

diffstat:
 bareos/Makefile                                    |  2 +-
 bareos/Makefile.common                             |  1 -
 bareos/TODO                                        | 13 -----
 bareos/distinfo                                    |  4 +-
 .../patch-core_cmake_BareosFindPrograms.cmake      | 20 +++++++
 ...patch-core_cmake_BareosInstallConfigFiles.cmake | 62 ++++++++++++++++++++++
 bareos/patches/patch-core_scripts_CMakeLists.txt   | 13 ++++-
 7 files changed, 97 insertions(+), 18 deletions(-)

diffs:
diff --git a/bareos/Makefile b/bareos/Makefile
index 51374f9692..b9fff27eff 100644
--- a/bareos/Makefile
+++ b/bareos/Makefile
@@ -20,7 +20,7 @@ REPLACE_PERL+=		core/src/cats/make_catalog_backup.pl.in
 MAKE_DIRS_PERMS+=	${VARBASE}/${PKG_SYSCONFSUBDIR} \
 			${REAL_ROOT_USER} ${BAREOS_GROUP} 0770
 
-post-install: # should go away once we find out how to set the run link path in CMakefiles
+post-install:
 	${LN} -fs ${PKG_SYSCONFSUBDIR}/backends/libbareossd-gentape.so ${DESTDIR:Q}/${BAREOS_LIBDIR:Q}/libbareossd-gentape.so
 
 CONFIG_TEMPLATES!=	${EGREP} "^"${CONFIG_TEMPLATE_PATH:Q} PLIST.common 2>/dev/null | sed -e 's/ /\\ /g'
diff --git a/bareos/Makefile.common b/bareos/Makefile.common
index 42c21f0bb2..baa0476a49 100644
--- a/bareos/Makefile.common
+++ b/bareos/Makefile.common
@@ -19,7 +19,6 @@ LICENSE=	gnu-agpl-v3
 ONLY_FOR_PLATFORM=	NetBSD-*-*
 
 USE_LANGUAGES+=	c c++
-USE_TOOLS+=	awk
 USE_CMAKE=	yes
 CMAKE_ARG_PATH=	..
 CONFIGURE_DIRS=	core/_build
diff --git a/bareos/TODO b/bareos/TODO
deleted file mode 100644
index e0ceedcaaa..0000000000
--- a/bareos/TODO
+++ /dev/null
@@ -1,13 +0,0 @@
-Fix:
-
-=> Checking for work-directory references in bareos-19.2.8
-ERROR: /usr/pkg/lib/bareos/scripts/bareos-config-lib.sh:        AWK="/scratch/wip/bareos/work/.tools/bin/awk"
-ERROR: /usr/pkg/lib/bareos/scripts/bareos-ctl-dir:      export AWK="/scratch/wip/bareos/work/.tools/bin/awk"
-ERROR: /usr/pkg/lib/bareos/scripts/bareos-ctl-fd:       AWK=/scratch/wip/bareos/work/.tools/bin/awk
-ERROR: /usr/pkg/lib/bareos/scripts/bareos-ctl-sd:       AWK=/scratch/wip/bareos/work/.tools/bin/awk
-ERROR: *** The above files still have references to the build directory.
-ERROR:     This is possibly an error that should be fixed by unwrapping
-ERROR:     the files or adding missing tools to the package makefile!
-*** Error code 1
-
-
diff --git a/bareos/distinfo b/bareos/distinfo
index 4cf7636e6a..a07c1498db 100644
--- a/bareos/distinfo
+++ b/bareos/distinfo
@@ -7,11 +7,13 @@ Size (bareos-19.2.8.tar.gz) = 12604929 bytes
 SHA1 (patch-core_CMakeLists.txt) = 17524dd14c665f00a8911589b52f930ec55e1e0e
 SHA1 (patch-core_cmake_BareosCheckIncludes.cmake) = 8f2a88768acdbe9adf94939ae1dabd3edf40144b
 SHA1 (patch-core_cmake_BareosFindAllLibraries.cmake) = eb33f59f616a5d265a6371dcc028a3031b5dbab5
+SHA1 (patch-core_cmake_BareosFindPrograms.cmake) = fd8a188b2816397e53f2ec4da57c7bd979b655a7
+SHA1 (patch-core_cmake_BareosInstallConfigFiles.cmake) = fdaa273e8d460f45f8b08682f5a0a5a1a59b65a3
 SHA1 (patch-core_cmake_BareosSetVariableDefaults.cmake) = a0ff2802d0583fca2685250bd4a5e0c8259837b2
 SHA1 (patch-core_cmake_BareosTimeFunctions.cmake) = aafa1dd9652ae8cc57414a405f03247242100ba9
 SHA1 (patch-core_platforms_netbsd_CMakeLists.txt) = dd6a54bac7e4b51e3f564f83cc7f78a8826a0d8e
 SHA1 (patch-core_platforms_netbsd_chio-changer) = 4bc4d7382db8e41bd1a10852e429e8f4e16e9fe4
-SHA1 (patch-core_scripts_CMakeLists.txt) = 421198b1bc6cf0570051c018bf1a22024904412a
+SHA1 (patch-core_scripts_CMakeLists.txt) = b7869d18651e6e6da4ad5f23c8f4c80d0166aa7c
 SHA1 (patch-core_src_CMakeLists.txt) = 3db708e8ece43b1087773470a19ea3362aec3d79
 SHA1 (patch-core_src_cats_make__catalog__backup.pl.in) = 85f235ce37349ea14c7bf06db3c2fc2534374655
 SHA1 (patch-core_src_cats_postgresql__queries.inc) = d255a93a039d671d9dad7b7b096dfff97095aa6e
diff --git a/bareos/patches/patch-core_cmake_BareosFindPrograms.cmake b/bareos/patches/patch-core_cmake_BareosFindPrograms.cmake
new file mode 100644
index 0000000000..e760f961f7
--- /dev/null
+++ b/bareos/patches/patch-core_cmake_BareosFindPrograms.cmake
@@ -0,0 +1,20 @@
+$NetBSD$
+
+--- core/cmake/BareosFindPrograms.cmake.orig	2020-07-09 17:39:20.000000000 +0000
++++ core/cmake/BareosFindPrograms.cmake
+@@ -18,10 +18,14 @@
+ #   02110-1301, USA.
+ 
+ # find programs
++if(${CMAKE_SYSTEM_NAME} MATCHES "NetBSD")
++  # avoid confusion with pkgsrc build time tool path
++  find_program(AWK awk PATHS /bin /usr/bin ENV TOOLS_PLATFORM.awk NO_DEFAULT_PATH )
++endif()
+ find_program(AWK awk)
+ find_program(GAWK gawk)
+ if(${CMAKE_SYSTEM_NAME} MATCHES "SunOS")
+-  set(AWK ${GAWK})
++ set(AWK ${GAWK})
+ endif()
+ 
+ find_program(PIDOF pidof)
diff --git a/bareos/patches/patch-core_cmake_BareosInstallConfigFiles.cmake b/bareos/patches/patch-core_cmake_BareosInstallConfigFiles.cmake
new file mode 100644
index 0000000000..660c361360
--- /dev/null
+++ b/bareos/patches/patch-core_cmake_BareosInstallConfigFiles.cmake
@@ -0,0 +1,62 @@
+$NetBSD$
+
+--- core/cmake/BareosInstallConfigFiles.cmake.orig	2020-07-09 17:39:20.000000000 +0000
++++ core/cmake/BareosInstallConfigFiles.cmake
+@@ -69,6 +69,7 @@ macro(
+         file(
+           INSTALL "${configfile}.new"
+           DESTINATION "${DESTCONFDIR}/${resname}"
++	  FILE_PERMISSIONS OWNER_READ OWNER_WRITE GROUP_READ
+         )
+         file(RENAME "${configfile}.new" "${configfile}")
+       else()
+@@ -76,7 +77,8 @@ macro(
+           STATUS
+             "${resname}/${fname} as ${resname}/${fname} (new installation)"
+         )
+-        file(COPY "${configfile}" DESTINATION "${DESTCONFDIR}/${resname}")
++        file(COPY "${configfile}" DESTINATION "${DESTCONFDIR}/${resname}" 
++	     FILE_PERMISSIONS OWNER_READ OWNER_WRITE GROUP_READ)
+       endif()
+     endforeach()
+   endforeach()
+@@ -121,6 +123,7 @@ macro(
+         file(
+           COPY "${BackendConfigSrcDir}/${configfile}.new"
+           DESTINATION "${DESTCONFDIR}/${dir}"
++	  FILE_PERMISSIONS OWNER_READ OWNER_WRITE GROUP_READ
+         )
+         file(RENAME "${BackendConfigSrcDir}/${configfile}.new"
+              "${BackendConfigSrcDir}/${configfile}")
+@@ -129,6 +132,7 @@ macro(
+         file(
+           COPY "${BackendConfigSrcDir}/${configfile}"
+           DESTINATION "${DESTCONFDIR}/${dir}"
++	  FILE_PERMISSIONS OWNER_READ OWNER_WRITE GROUP_READ
+         )
+       endif()
+     endforeach()
+@@ -151,6 +155,7 @@ macro(
+       file(
+         COPY "${BackendConfigSrcDir}/${configfile}"
+         DESTINATION "${DESTCONFDIR}/${dir}"
++	FILE_PERMISSIONS OWNER_READ OWNER_WRITE GROUP_READ WORLD_READ
+       )
+     endforeach()
+ 
+@@ -183,11 +188,14 @@ macro(
+             file(
+               COPY "${configfile}.new"
+               DESTINATION "${DESTCONFDIR}/${resname}"
++	      FILE_PERMISSIONS OWNER_READ OWNER_WRITE GROUP_READ WORLD_READ
+             )
+             file(RENAME "${configfile}.new" "${configfile}")
+           else()
+             message(STATUS "${resname}/${fname} as ${resname}/${fname}")
+-            file(COPY "${configfile}" DESTINATION "${DESTCONFDIR}/${resname}")
++            file(COPY "${configfile}" DESTINATION "${DESTCONFDIR}/${resname}"
++	         FILE_PERMISSIONS OWNER_READ OWNER_WRITE GROUP_READ WORLD_READ
++	    )
+           endif()
+         else()
+           message(STATUS "skipping .in file ${configfile}:${IS_INFILE}")
diff --git a/bareos/patches/patch-core_scripts_CMakeLists.txt b/bareos/patches/patch-core_scripts_CMakeLists.txt
index 85305231d3..168761d9d4 100644
--- a/bareos/patches/patch-core_scripts_CMakeLists.txt
+++ b/bareos/patches/patch-core_scripts_CMakeLists.txt
@@ -2,9 +2,18 @@ $NetBSD$
 
 suppress mtx-changer installation if not found
 
---- core/scripts/CMakeLists.txt.orig	2020-06-22 13:14:51.366971896 +0000
+--- core/scripts/CMakeLists.txt.orig	2020-07-09 17:39:20.000000000 +0000
 +++ core/scripts/CMakeLists.txt
-@@ -42,18 +42,30 @@ install(
+@@ -35,25 +35,37 @@ install(
+ install(
+   FILES bareos btraceback.gdb btraceback.dbx btraceback.mdb bareos-config
+         bareos-config-lib.sh bareos-ctl-funcs
+-  PERMISSIONS OWNER_READ OWNER_WRITE OWNER_EXECUTE GROUP_READ GROUP_EXECUTE
+-              WORLD_READ WORLD_EXECUTE
++  PERMISSIONS OWNER_READ OWNER_WRITE GROUP_READ
++              WORLD_READ
+   DESTINATION "${scriptdir}"
+ )
  
  if(NOT client-only)
    install(


Home | Main Index | Thread Index | Old Index