about summary refs log tree commit diff stats
diff options
context:
space:
mode:
authorSilvino Silva <silvino@bk.ru>2019-12-24 04:10:14 +0000
committerSilvino Silva <silvino@bk.ru>2019-12-24 04:10:14 +0000
commit9a72a6e5cc23d29d510625c0c1677fb7ae465032 (patch)
tree89267b4bcf5852460bcf88fb9fac069a06d8ee3f
parent994cbeef3795b659e166d9aea93d4a6ca3010246 (diff)
downloaddoc-9a72a6e5cc23d29d510625c0c1677fb7ae465032.tar.gz
better c debugging and git tags doc
-rw-r--r--dev/c/debugging.html27
-rw-r--r--dev/git/branch.html8
2 files changed, 24 insertions, 11 deletions
diff --git a/dev/c/debugging.html b/dev/c/debugging.html
index 90dca1b..c26ae7e 100644
--- a/dev/c/debugging.html
+++ b/dev/c/debugging.html
@@ -42,7 +42,7 @@
 
         <h2 id="gdb">GDB</h2>
 
-        <p>If the program needs arguments you can set it;</p>
+        <p>If the program needs arguments you can set it at start or later;</p>
 
         <pre>
         (gdb)set args -parameter1 -parameter2
@@ -63,16 +63,24 @@
             <dd>TUI single key mode.</dd>
             <dt>Ctrl-L s</dt>
             <dd>Refresh screen.</dd>
-            <dt>Up</dt>
-            <dd>Scroll</dd>
-            <dt>Down</dt>
-            <dd>Scroll</dd>
-            <dt>Left</dt>
-            <dd>Scroll</dd>
-            <dt>Right</dt>
-            <dd>Scroll</dd>
         </dl>
 
+        <p>To attach to a process (pid 5922) and start UI with disassemble;<p>
+
+        <pre>
+        $ gdb -p 5922
+        (gdb) layout asm
+        (gdb) disassemble
+        (gdb) set disassembly-flavor intel
+        </pre>
+
+        <p>Break on memory address and inspect area of the memory;</p>
+
+        <pre>
+        (gdb) b *0x400671
+        (gdb) x/16gx 0x7ffe5217c03d
+        </pre>
+
         <pre>
         (gdb) info win
         (gdb) fs next
@@ -85,7 +93,6 @@
         info locals
         display
         print
-        x
         catch syscall open
         </pre>
 
diff --git a/dev/git/branch.html b/dev/git/branch.html
index 24acff8..7b31604 100644
--- a/dev/git/branch.html
+++ b/dev/git/branch.html
@@ -201,7 +201,13 @@
     <p id="tag">Tags are used to mark patch releases, get back in time to make security patches or to mark a new major or minor new release. Tag new release with projectname-version, this allows meaningful ports <a href="../core/ports.html">distfiles</a> when downloading releases from git archives;</p>
 
     <pre>
-    $ git tag -a projectname-1.2.0
+    $ git tag -a projectname-1.2.0 -m "project 1.2.0 release"
+    $ git push origin projectname-1.2.0
+    </pre>
+
+    <p>To push all local tags;</p>
+
+    <pre>
     $ git push --follow-tags
     </pre>
 
3' href='#n223'>223 224 225 226 227 228 229 230 231 232 233 234 235 236 237 238 239 240 241 242 243 244 245 246 247 248 249 250 251 252 253 254 255 256 257 258 259 260 261 262 263 264 265 266 267 268 269 270 271 272 273 274 275 276 277 278 279 280 281 282 283 284 285 286 287 288 289 290 291 292 293 294 295 296 297 298 299 300 301 302 303 304 305 306 307 308 309 310 311 312 313 314 315 316 317 318 319 320 321 322 323 324 325