A .vscode/launch.json => .vscode/launch.json +23 -0
@@ 0,0 1,23 @@
+/*
+ * SPDX-FileCopyrightText: 2022 Andrea Pappacoda
+ * SPDX-License-Identifier: ISC
+ */
+
+{
+ "version": "0.2.0",
+ "configurations": [
+ {
+ "type": "lldb",
+ "expressions": "native",
+ "request": "launch",
+ "name": "Debug",
+ "preLaunchTask": "compile",
+ "program": "${workspaceFolder}/${workspaceFolderBasename}",
+ "args": ["example"],
+ "cwd": "${workspaceFolder}",
+ "env": {
+ "ASAN_OPTIONS": "detect_leaks=0"
+ }
+ }
+ ]
+}
A .vscode/tasks.json => .vscode/tasks.json +24 -0
@@ 0,0 1,24 @@
+/*
+ * SPDX-FileCopyrightText: 2022 Andrea Pappacoda
+ * SPDX-License-Identifier: ISC
+ */
+
+{
+ "version": "2.0.0",
+ "tasks": [
+ {
+ "label": "compile",
+ "type": "process",
+ "command": "make",
+ "args": [
+ "CC=cc",
+ "CFLAGS=-std=c89 -Wall -Wextra -Wpedantic -g3 -fsanitize=address -fno-omit-frame-pointer",
+ "LDFLAGS=-fsanitize=address"
+ ],
+ "presentation": {
+ "reveal": "silent",
+ "focus": false
+ }
+ }
+ ]
+}
M Makefile => Makefile +0 -5
@@ 1,10 1,5 @@
.POSIX:
-# Compilation stuff (mostly for development, I'll remove these later)
-CC = cc
-CFLAGS = -std=c89 -Wall -Wextra -Wpedantic -fsanitize=address -g
-LDFLAGS = -fsanitize=address
-
# Paths
PREFIX = /usr/local
BINDIR = bin