void-packages/srcpkgs/signond/patches/cross.patch
Đoàn Trần Công Danh 4b97cd2fb4 srcpkgs/s*: convert patches to -Np1
```sh
git grep -l '^patch_args=-Np0' "srcpkgs/$1*/template" |
while read template; do
	for p in ${template%/template}/patches/*; do
		sed -i '
			\,^[+-][+-][+-] /dev/null,b
			/^[*-]\+ [0-9]\+\(,[0-9]\+\)\? [*-]\+$/b
			s,^[*][*][*] ,&a/,
			/^--- /{
				s,\(^--- \)\(./\)*,\1a/,
				s,[.-][Oo][Rr][Ii][Gg]\([	/]\),\1,
				s/[.-][Oo][Rr][Ii][Gg]$//
				s/[.]patched[.]\([^.]\)/.\1/
				h
			}
			/^+++ -/{
				g
				s/^--- a/+++ b/
				b
			}
			s,\(^+++ \)\(./\)*,\1b/,
		' "$p"
	done
	sed -i '/^patch_args=/d' $template
done
```
2021-06-20 13:17:29 +07:00

28 lines
1.2 KiB
Diff

--- a/lib/SignOn/SignOnQt5Config.cmake.in 2018-09-17 18:28:27.000000000 +0200
+++ b/lib/SignOn/SignOnQt5Config.cmake.in 2018-09-17 18:28:27.000000000 +0200
@@ -2,6 +2,21 @@
# SIGNONQT_LIBRARIES - The libraries needed to use libsignon-qt
# SIGNONQT_LIBRARIES_STATIC - The static version of libsignon-qt
-set(SIGNONQT_LIBRARIES $${INSTALL_LIBDIR}/lib$${TARGET}.so)
-set(SIGNONQT_LIBRARIES_STATIC $${INSTALL_LIBDIR}/lib$${TARGET}.a)
-set(SIGNONQT_INCLUDE_DIRS $${INSTALL_PREFIX}/include/$${TARGET})
\ No newline at end of file
+get_filename_component(_IMPORT_PREFIX "${CMAKE_CURRENT_LIST_FILE}" PATH)
+if(_realCurr STREQUAL _realOrig)
+ set(_IMPORT_PREFIX "/usr/lib/cmake/SignOnQt5")
+endif()
+unset(_realOrig)
+unset(_realCurr)
+get_filename_component(_IMPORT_PREFIX "${_IMPORT_PREFIX}" PATH)
+get_filename_component(_IMPORT_PREFIX "${_IMPORT_PREFIX}" PATH)
+get_filename_component(_IMPORT_PREFIX "${_IMPORT_PREFIX}" PATH)
+if(_IMPORT_PREFIX STREQUAL "/")
+ set(_IMPORT_PREFIX "")
+endif()
+
+set(SIGNONQT_LIBRARIES ${_IMPORT_PREFIX}/lib/lib$${TARGET}.so)
+set(SIGNONQT_LIBRARIES_STATIC ${_IMPORT_PREFIX}/lib/lib$${TARGET}.a)
+set(SIGNONQT_INCLUDE_DIRS ${_IMPORT_PREFIX}/include/$${TARGET})
+
+set(_IMPORT_PREFIX)