File: vcpkg.patch

package info (click to toggle)
apache-arrow 23.0.1-1
  • links: PTS
  • area: main
  • in suites: sid
  • size: 76,220 kB
  • sloc: cpp: 654,608; python: 70,522; ruby: 45,964; ansic: 18,742; sh: 7,365; makefile: 669; javascript: 125; xml: 41
file content (62 lines) | stat: -rw-r--r-- 2,633 bytes parent folder | download | duplicates (3)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
diff --git a/scripts/cmake/vcpkg_execute_build_process.cmake b/scripts/cmake/vcpkg_execute_build_process.cmake
index 60fd5b587a..c8dc021af8 100644
--- a/scripts/cmake/vcpkg_execute_build_process.cmake
+++ b/scripts/cmake/vcpkg_execute_build_process.cmake
@@ -131,6 +131,26 @@ function(vcpkg_execute_build_process)
             endif()
         endforeach()
         z_vcpkg_prettify_command_line(pretty_command ${arg_COMMAND})
+        # --- Try to print error logs
+        # Split the string by newline characters
+        string(REGEX MATCHALL "[^\n]+" file_list ${stringified_logs})
+
+        # Iterate over the list and print content of each file
+        foreach(file IN LISTS file_list)
+            string(STRIP "${file}" file_stripped)
+
+            # Print filename
+            message(STATUS "===")
+            message(STATUS "=== Build Failed. Content of ${file_stripped}:")
+
+            # Read the content of the file
+            file(READ ${file_stripped} file_content)
+
+            # Print the content
+            message(STATUS "${file_content}")
+            message(STATUS "=== End of content of ${file_stripped}")
+        endforeach()
+        # ---
         message(FATAL_ERROR
             "  Command failed: ${pretty_command}\n"
             "  Working Directory: ${arg_WORKING_DIRECTORY}\n"
diff --git a/scripts/cmake/vcpkg_execute_required_process.cmake b/scripts/cmake/vcpkg_execute_required_process.cmake
index 830aa409fd..90452d857b 100644
--- a/scripts/cmake/vcpkg_execute_required_process.cmake
+++ b/scripts/cmake/vcpkg_execute_required_process.cmake
@@ -109,6 +109,26 @@ Halting portfile execution.
         endforeach()
 
         z_vcpkg_prettify_command_line(pretty_command ${arg_COMMAND})
+        # --- Try to print error logs
+        # Split the string by newline characters
+        string(REGEX MATCHALL "[^\n]+" file_list ${stringified_logs})
+
+        # Iterate over the list and print content of each file
+        foreach(file IN LISTS file_list)
+            string(STRIP "${file}" file_stripped)
+
+            # Print filename
+            message(STATUS "===")
+            message(STATUS "=== Build Failed. Content of ${file_stripped}:")
+
+            # Read the content of the file
+            file(READ ${file_stripped} file_content)
+
+            # Print the content
+            message(STATUS "${file_content}")
+            message(STATUS "=== End of content of ${file_stripped}")
+        endforeach()
+        # ---
         message(FATAL_ERROR
             "  Command failed: ${pretty_command}\n"
             "  Working Directory: ${arg_WORKING_DIRECTORY}\n"