commit 4ac780e3e98a9fb891b5b55fb99b3c7d1a4f761c Author: Aryadev Chavali Date: Thu Jan 22 17:55:59 2026 +0000 hello world! diff --git a/.dir-locals.el b/.dir-locals.el new file mode 100644 index 0000000..477c21e --- /dev/null +++ b/.dir-locals.el @@ -0,0 +1,7 @@ +;;; Directory Local Variables -*- no-byte-compile: t -*- +;;; For more information see (info "(emacs) Directory Variables") + +((nil . ((compile-command . "make MODE=debug -B -k") + (+license/license-choice . "MIT License"))) + (c-mode . ((mode . clang-format))) + (c++-mode . ((mode . clang-format)))) diff --git a/.gitignore b/.gitignore new file mode 100644 index 0000000..d163863 --- /dev/null +++ b/.gitignore @@ -0,0 +1 @@ +build/ \ No newline at end of file diff --git a/LICENSE b/LICENSE new file mode 100644 index 0000000..b7147c3 --- /dev/null +++ b/LICENSE @@ -0,0 +1,21 @@ +MIT License + +Copyright (c) 2026 Aryadev Chavali + +Permission is hereby granted, free of charge, to any person obtaining a copy +of this software and associated documentation files (the "Software"), to deal +in the Software without restriction, including without limitation the rights +to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +copies of the Software, and to permit persons to whom the Software is +furnished to do so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all +copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE +SOFTWARE. \ No newline at end of file diff --git a/Makefile b/Makefile new file mode 100644 index 0000000..8fd88f3 --- /dev/null +++ b/Makefile @@ -0,0 +1,33 @@ +CXX=c++ + +DIST=build +OUT=$(DIST)/main.out + +LDFLAGS= +GFLAGS=-Wall -Wextra -Wpedantic -std=c++23 +DFLAGS=-ggdb -fsanitize=address -fsanitize=undefined +RFLAGS=-O3 + +MODE=release +ifeq ($(MODE), release) +CFLAGS=$(GFLAGS) $(RFLAGS) +else +CFLAGS=$(GFLAGS) $(DFLAGS) +endif + +$(OUT): $(DIST)/main.o | $(DIST) + $(CXX) $(CFLAGS) -o $@ $^ $(LDFLAGS) + +$(DIST)/main.o: main.cpp | $(DIST) + $(CXX) $(CFLAGS) -c -o $@ $^ + +$(DIST): + mkdir -p $(DIST) + +.PHONY: run clean +ARGS= +run: $(OUT) + ./$^ $(ARGS) + +clean: + rm -rf $(DIST) diff --git a/README b/README new file mode 100644 index 0000000..e69de29 diff --git a/main.cpp b/main.cpp new file mode 100644 index 0000000..99ef05e --- /dev/null +++ b/main.cpp @@ -0,0 +1,26 @@ +/* main.cpp: + * Created: 2026-01-22 + * Author: Aryadev Chavali + * License: See end of file + * Commentary: + */ + +#include + +int main(void) +{ + puts("Hello, world!"); + return 0; +} + +/* Copyright (C) 2026 Aryadev Chavali + + * This program is distributed in the hope that it will be useful, but WITHOUT + * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS + * FOR A PARTICULAR PURPOSE. See the MIT License for details. + + * You may distribute and modify this code under the terms of the MIT License, + * which you should have received a copy of along with this program. If not, + * please go to . + + */