Pcornel
Linux

Software & Source

Cheat sheet · https://pcornel.dk/topic.php?topic=2905

Back to the Topic

Answer

Software and source management on Linux covers version control (Git), building software from source (compilers, make, build systems) and how programs find their libraries.

Remember

Prefer distribution packages; build from source only when needed and install into /usr/local or /opt. Track source in Git. Record build dependencies so builds are reproducible.

First checks

  • git status / git log --oneline -5 — repository state
  • ldd <binary> — shared libraries
  • ldconfig -p | grep <lib> — libraries in the linker cache
  • make --version; gcc --version — build tools

Commands

make
Evaluate build rules and execute the commands needed to bring declared targets up to date.
gcc
Compile, assemble and link C or related source code according to selected toolchain options.

Verify in this order

source in Git → dependencies installed → built → installed in /usr/local or /opt → libraries resolved

Where it usually breaks

First mismatch in persistent intent → provider/parser/generator → kernel/userspace runtime → dependency/security context → logs/counters → consumer-visible read-back; preserve identity/native diagnostic/pre-state before mutation.

Read-only verification commands unless stated otherwise. Confirm syntax for your platform and release. Full reference: https://pcornel.dk/topic.php?topic=2905

Confirmation

Confirm action

Continue?