Month: April 2021

  • Build C/C++ libraries with debugging support

    I’ve been debugging a program which uses certain library on CLion. The IDE is great, but I cannot see most of the code from the library, the debugger shows me assembly code, and that’s not very helpful. The solution was to build and install the library with debugging symbols: The actual commands for my particular…

  • Hello-World AWS Encryption SDK C/C++ program

    In one of my projects, I need to encrypt and decrypt data in C, specifically using the AWS Encryption SDK. The SDK supports C, but the documentation is not very clear, in my opinion, so I decided to share my hello-world implementation with my learnings. Setup I’m working on Ubuntu, however, not all distributions are…

  • Hello-World CGO program

    I’m sharing my first CGO program, I hope it helps. File structure: hello.c hello.h main.go Build & run References I followed Cgo: First steps tutorial, but the examples provided didn’t compile for me (see error down below), I had to create a header file (hello.h) and a source file (hello.c), as shown in this post.…