File tree 2 files changed +60
-2
lines changed
2 files changed +60
-2
lines changed Original file line number Diff line number Diff line change @@ -64,14 +64,13 @@ if (INTROSPECTION)
64
64
HINTS ${PC_g_ir_compiler}
65
65
)
66
66
67
- set (G_IR_SCANNER_CMD "${G_IR_SCANNER} " )
68
67
set (web_libpath "$<TARGET_FILE_DIR:webembed>" )
69
68
70
69
add_custom_command (
71
70
TARGET webembed
72
71
WORKING_DIRECTORY ${CMAKE_CURRENT_SOURCE_DIR}
73
72
POST_BUILD
74
- COMMAND ${G_IR_SCANNER_CMD}
73
+ COMMAND " ${G_IR_SCANNER} "
75
74
--warn-all --no -libtool --verbose
76
75
--namespace=Web
77
76
--nsversion=0.0
@@ -98,4 +97,36 @@ if (INTROSPECTION)
98
97
-o ${web_libpath} /Web-0.0.typelib
99
98
DEPENDS ${web_libpath} /Web-0.0.gir webembed
100
99
)
100
+ endif ()
101
+
102
+ # gi-docgen generate -C config.toml /usr/share/gir-1.0/Gtk-4.0.gir
103
+
104
+ if (DOCUMENTATION AND INTROSPECTION)
105
+ find_package (PkgConfig)
106
+ pkg_check_modules(GI_DOCGEN QUIET gi-docgen)
107
+
108
+ find_program (GI_DOCGEN gi-docgen
109
+ HINTS ${PC_gi_docgen}
110
+ )
111
+
112
+ if (${CMAKE_SYSTEM_NAME} MATCHES "Darwin" )
113
+ set (EXTRA_SEARCH_PATH "/opt/homebrew/share/gir-1.0" )
114
+ else ()
115
+ set (EXTRA_SEARCH_PATH "" )
116
+ endif ()
117
+
118
+
119
+ add_custom_command (
120
+ TARGET webembed
121
+ POST_BUILD
122
+ COMMAND "${GI_DOCGEN} "
123
+ generate
124
+ -C ${CMAKE_CURRENT_SOURCE_DIR} /config.toml
125
+ ${web_libpath} /Web-0.0.gir
126
+ --output -dir ${CMAKE_CURRENT_BINARY_DIR} /../docs
127
+ --add-include -path "${EXTRA_SEARCH_PATH} "
128
+ --no -namespace-dir
129
+ DEPENDS ${web_libpath} /Web-0.0.gir webembed
130
+ )
131
+
101
132
endif ()
Original file line number Diff line number Diff line change
1
+ [library ]
2
+ description = " LibWeb GTK"
3
+ authors = " Matthew Jakeman"
4
+ license = " BSD 2-Clause"
5
+ browse_url = " https://github.com/mjakeman/libweb-gtk"
6
+ repository_url = " https://github.com/mjakeman/libweb-gtk.git"
7
+ website_url = " https://github.com/mjakeman/libweb-gtk"
8
+ dependencies = [
9
+ " GObject-2.0" ,
10
+ " Gtk-4.0" ,
11
+ " Soup-3.0"
12
+ ]
13
+
14
+ [dependencies ."GObject-2 .0" ]
15
+ name = " GObject"
16
+ description = " The base type system library"
17
+ docs_url = " https://docs.gtk.org/gobject/"
18
+
19
+ [dependencies ."Gtk-4 .0" ]
20
+ name = " Gtk"
21
+ description = " The GTK toolkit"
22
+ docs_url = " https://docs.gtk.org/gtk4/"
23
+
24
+ [dependencies ."Soup-3 .0" ]
25
+ name = " Soup"
26
+ description = " HTTP client/server library for GNOME"
27
+ docs_url = " https://libsoup.org/libsoup-3.0/"
You can’t perform that action at this time.
0 commit comments