commit 97a99175f4f33282fb02e0ad75e02dbc30ace80c Author: Shav Kinderlehrer Date: Sun Apr 9 13:42:44 2023 -0400 Initial commit diff --git a/.gitignore b/.gitignore new file mode 100644 index 0000000..e3dd7f6 --- /dev/null +++ b/.gitignore @@ -0,0 +1,133 @@ +build/ +# Created by https://www.toptal.com/developers/gitignore/api/c,macos,windows,linux,c +# Edit at https://www.toptal.com/developers/gitignore?templates=c,macos,windows,linux,c + +### C ### +# Prerequisites +*.d + +# Object files +*.o +*.ko +*.obj +*.elf + +# Linker output +*.ilk +*.map +*.exp + +# Precompiled Headers +*.gch +*.pch + +# Libraries +*.lib +*.a +*.la +*.lo + +# Shared objects (inc. Windows DLLs) +*.dll +*.so +*.so.* +*.dylib + +# Executables +*.exe +*.out +*.app +*.i*86 +*.x86_64 +*.hex + +# Debug files +*.dSYM/ +*.su +*.idb +*.pdb + +# Kernel Module Compile Results +*.mod* +*.cmd +.tmp_versions/ +modules.order +Module.symvers +Mkfile.old +dkms.conf + +### Linux ### +*~ + +# temporary files which can be created if a process still has a handle open of a deleted file +.fuse_hidden* + +# KDE directory preferences +.directory + +# Linux trash folder which might appear on any partition or disk +.Trash-* + +# .nfs files are created when an open file is removed but is still being accessed +.nfs* + +### macOS ### +# General +.DS_Store +.AppleDouble +.LSOverride + +# Icon must end with two \r +Icon + +# Thumbnails +._* + +# Files that might appear in the root of a volume +.DocumentRevisions-V100 +.fseventsd +.Spotlight-V100 +.TemporaryItems +.Trashes +.VolumeIcon.icns +.com.apple.timemachine.donotpresent + +# Directories potentially created on remote AFP share +.AppleDB +.AppleDesktop +Network Trash Folder +Temporary Items +.apdisk + +### macOS Patch ### +# iCloud generated files +*.icloud + +### Windows ### +# Windows thumbnail cache files +Thumbs.db +Thumbs.db:encryptable +ehthumbs.db +ehthumbs_vista.db + +# Dump file +*.stackdump + +# Folder config file +[Dd]esktop.ini + +# Recycle Bin used on file shares +$RECYCLE.BIN/ + +# Windows Installer files +*.cab +*.msi +*.msix +*.msm +*.msp + +# Windows shortcuts +*.lnk + +# End of https://www.toptal.com/developers/gitignore/api/c,macos,windows,linux,c + diff --git a/Makefile b/Makefile new file mode 100644 index 0000000..7eb6e35 --- /dev/null +++ b/Makefile @@ -0,0 +1,36 @@ +NAME=main + +SRCDIR=src +IDIR=include +ODIR=obj +BINDIR=build + +CC=cc +CFLAGS=-I$(IDIR) -Wall -Wextra -pedantic +LIB= + +_DEPS= +DEPS=$(patsubst %,$(IDIR)/%,$(_DEPS)) + +_OBJ=$(NAME).o +OBJ=$(patsubst %,$(ODIR)/%,$(_OBJ)) + + +$(ODIR)/%.o: $(SRCDIR)/%.c $(DEPS) + $(CC) -c -o $@ $< $(CFLAGS) $(LIB) + +$(NAME): $(OBJ) + $(CC) -o $(BINDIR)/$@ $^ $(CFLAGS) $(LIB) + +.PHONY: prep +prep: + -@mkdir -p $(SRCDIR) + -@mkdir -p $(IDIR) + -@mkdir -p $(ODIR) + -@mkdir -p $(BINDIR) + @echo $(BINDIR)/ >> .gitignore + +.PHONY: clean +clean: + -rm -f $(ODIR)/* + -rm -f $(BINDIR)/* diff --git a/src/main.c b/src/main.c new file mode 100644 index 0000000..03b2213 --- /dev/null +++ b/src/main.c @@ -0,0 +1,3 @@ +int main(void) { + return 0; +}