Chore: don't use cmake

This commit is contained in:
Dorian Zedler 2022-06-29 14:47:58 +02:00
parent 60b46c9687
commit 1178779d8d
Signed by: dorian
GPG key ID: 989DE36109AFA354
7 changed files with 24 additions and 278 deletions

1
.gitignore vendored
View file

@ -1 +0,0 @@
build

View file

@ -1,6 +1,5 @@
{ {
"recommendations": [ "recommendations": [
"ms-vscode.cpptools", "ms-vscode.cpptools"
"twxs.cmake"
] ]
} }

View file

@ -5,5 +5,4 @@
"helper.h": "c" "helper.h": "c"
}, },
"editor.formatOnSave": true, "editor.formatOnSave": true,
"cmake.sourceDirectory": "${workspaceFolder}/Implementierung"
} }

View file

@ -1,4 +1,2 @@
cmake_install.cmake build
CMakeCache.txt md2
md2
CMakeFiles

View file

@ -1,19 +0,0 @@
cmake_minimum_required(VERSION 3.0.0)
# here we specify that the project is C language only, so the default
# C compiler on the system will be used
project(md2 C)
add_executable(md2 "")
set(SOURCE_FILES
src/main.c
src/helper.c
src/io.c
src/md2.c
)
target_sources(md2 PRIVATE ${SOURCE_FILES})
target_include_directories(md2 PUBLIC
lib
)

View file

@ -1,262 +1,32 @@
# CMAKE generated file: DO NOT EDIT!
# Generated by "Unix Makefiles" Generator, CMake Version 3.23
# Default target executed when no arguments are given to make.
default_target: all
.PHONY : default_target
# Allow only one "make -f Makefile2" at a time, but pass parallelism. SRC = src/main.c src/helper.c src/io.c src/md2.c
.NOTPARALLEL: OBJ = ${subst src,build,${SRC:.c=.o}}
CC = gcc
CFLAGS = -Ilib
LDFLAGS =
#============================================================================= all: md2
# Special targets provided by cmake.
# Disable implicit rules so canonical targets will work.
.SUFFIXES:
# Disable VCS-based implicit rules.
% : %,v
# Disable VCS-based implicit rules.
% : RCS/%
# Disable VCS-based implicit rules.
% : RCS/%,v
# Disable VCS-based implicit rules.
% : SCCS/s.%
# Disable VCS-based implicit rules.
% : s.%
.SUFFIXES: .hpux_make_needs_suffix_list
# Command-line flag to silence nested $(MAKE).
$(VERBOSE)MAKESILENT = -s
#Suppress display of executed commands.
$(VERBOSE).SILENT:
# A target that is always out of date.
cmake_force:
.PHONY : cmake_force
#=============================================================================
# Set environment variables for the build.
# The shell in which to execute make rules.
SHELL = /bin/sh
# The CMake executable.
CMAKE_COMMAND = /usr/bin/cmake
# The command to remove a file.
RM = /usr/bin/cmake -E rm -f
# Escaping for special characters.
EQUALS = =
# The top-level source directory on which CMake was run.
CMAKE_SOURCE_DIR = /home/dorian/Documents/git/UNI/era/team199/Implementierung
# The top-level build directory on which CMake was run.
CMAKE_BINARY_DIR = /home/dorian/Documents/git/UNI/era/team199/Implementierung
#=============================================================================
# Targets provided globally by CMake.
# Special rule for the target edit_cache
edit_cache:
@$(CMAKE_COMMAND) -E cmake_echo_color --switch=$(COLOR) --cyan "Running CMake cache editor..."
/usr/bin/ccmake -S$(CMAKE_SOURCE_DIR) -B$(CMAKE_BINARY_DIR)
.PHONY : edit_cache
# Special rule for the target edit_cache
edit_cache/fast: edit_cache
.PHONY : edit_cache/fast
# Special rule for the target rebuild_cache
rebuild_cache:
@$(CMAKE_COMMAND) -E cmake_echo_color --switch=$(COLOR) --cyan "Running CMake to regenerate build system..."
/usr/bin/cmake --regenerate-during-build -S$(CMAKE_SOURCE_DIR) -B$(CMAKE_BINARY_DIR)
.PHONY : rebuild_cache
# Special rule for the target rebuild_cache
rebuild_cache/fast: rebuild_cache
.PHONY : rebuild_cache/fast
# The main all target
all: cmake_check_build_system
$(CMAKE_COMMAND) -E cmake_progress_start /home/dorian/Documents/git/UNI/era/team199/Implementierung/CMakeFiles /home/dorian/Documents/git/UNI/era/team199/Implementierung//CMakeFiles/progress.marks
$(MAKE) $(MAKESILENT) -f CMakeFiles/Makefile2 all
$(CMAKE_COMMAND) -E cmake_progress_start /home/dorian/Documents/git/UNI/era/team199/Implementierung/CMakeFiles 0
.PHONY : all
# The main clean target
clean: clean:
$(MAKE) $(MAKESILENT) -f CMakeFiles/Makefile2 clean rm -f md2 $(OBJ)
.PHONY : clean
# The main clean target
clean/fast: clean
.PHONY : clean/fast
# Prepare targets for installation.
preinstall: all
$(MAKE) $(MAKESILENT) -f CMakeFiles/Makefile2 preinstall
.PHONY : preinstall
# Prepare targets for installation.
preinstall/fast:
$(MAKE) $(MAKESILENT) -f CMakeFiles/Makefile2 preinstall
.PHONY : preinstall/fast
# clear depends
depend:
$(CMAKE_COMMAND) -S$(CMAKE_SOURCE_DIR) -B$(CMAKE_BINARY_DIR) --check-build-system CMakeFiles/Makefile.cmake 1
.PHONY : depend
#=============================================================================
# Target rules for targets named md2
# Build rule for target.
md2: cmake_check_build_system
$(MAKE) $(MAKESILENT) -f CMakeFiles/Makefile2 md2
.PHONY : md2
# fast build rule for target.
md2/fast:
$(MAKE) $(MAKESILENT) -f CMakeFiles/md2.dir/build.make CMakeFiles/md2.dir/build
.PHONY : md2/fast
src/helper.o: src/helper.c.o
.PHONY : src/helper.o
# target to build an object file
src/helper.c.o:
$(MAKE) $(MAKESILENT) -f CMakeFiles/md2.dir/build.make CMakeFiles/md2.dir/src/helper.c.o
.PHONY : src/helper.c.o
src/helper.i: src/helper.c.i
.PHONY : src/helper.i
# target to preprocess a source file
src/helper.c.i:
$(MAKE) $(MAKESILENT) -f CMakeFiles/md2.dir/build.make CMakeFiles/md2.dir/src/helper.c.i
.PHONY : src/helper.c.i
src/helper.s: src/helper.c.s
.PHONY : src/helper.s
# target to generate assembly for a file
src/helper.c.s:
$(MAKE) $(MAKESILENT) -f CMakeFiles/md2.dir/build.make CMakeFiles/md2.dir/src/helper.c.s
.PHONY : src/helper.c.s
src/io.o: src/io.c.o
.PHONY : src/io.o
# target to build an object file
src/io.c.o:
$(MAKE) $(MAKESILENT) -f CMakeFiles/md2.dir/build.make CMakeFiles/md2.dir/src/io.c.o
.PHONY : src/io.c.o
src/io.i: src/io.c.i
.PHONY : src/io.i
# target to preprocess a source file
src/io.c.i:
$(MAKE) $(MAKESILENT) -f CMakeFiles/md2.dir/build.make CMakeFiles/md2.dir/src/io.c.i
.PHONY : src/io.c.i
src/io.s: src/io.c.s
.PHONY : src/io.s
# target to generate assembly for a file
src/io.c.s:
$(MAKE) $(MAKESILENT) -f CMakeFiles/md2.dir/build.make CMakeFiles/md2.dir/src/io.c.s
.PHONY : src/io.c.s
src/main.o: src/main.c.o
.PHONY : src/main.o
# target to build an object file
src/main.c.o:
$(MAKE) $(MAKESILENT) -f CMakeFiles/md2.dir/build.make CMakeFiles/md2.dir/src/main.c.o
.PHONY : src/main.c.o
src/main.i: src/main.c.i
.PHONY : src/main.i
# target to preprocess a source file
src/main.c.i:
$(MAKE) $(MAKESILENT) -f CMakeFiles/md2.dir/build.make CMakeFiles/md2.dir/src/main.c.i
.PHONY : src/main.c.i
src/main.s: src/main.c.s
.PHONY : src/main.s
# target to generate assembly for a file
src/main.c.s:
$(MAKE) $(MAKESILENT) -f CMakeFiles/md2.dir/build.make CMakeFiles/md2.dir/src/main.c.s
.PHONY : src/main.c.s
src/md2.o: src/md2.c.o
.PHONY : src/md2.o
# target to build an object file
src/md2.c.o:
$(MAKE) $(MAKESILENT) -f CMakeFiles/md2.dir/build.make CMakeFiles/md2.dir/src/md2.c.o
.PHONY : src/md2.c.o
src/md2.i: src/md2.c.i
.PHONY : src/md2.i
# target to preprocess a source file
src/md2.c.i:
$(MAKE) $(MAKESILENT) -f CMakeFiles/md2.dir/build.make CMakeFiles/md2.dir/src/md2.c.i
.PHONY : src/md2.c.i
src/md2.s: src/md2.c.s
.PHONY : src/md2.s
# target to generate assembly for a file
src/md2.c.s:
$(MAKE) $(MAKESILENT) -f CMakeFiles/md2.dir/build.make CMakeFiles/md2.dir/src/md2.c.s
.PHONY : src/md2.c.s
# Help Target
help: help:
@echo "The following are some of the valid targets for this Makefile:" @echo === Project Build Help ===
@echo "... all (the default if no target is provided)" @echo
@echo "... clean" @echo Available targets:
@echo "... depend" @echo - all: build everything
@echo "... edit_cache" @echo - clean: clean distfiles
@echo "... rebuild_cache" @echo - help: show this help
@echo "... md2"
@echo "... src/helper.o"
@echo "... src/helper.i"
@echo "... src/helper.s"
@echo "... src/io.o"
@echo "... src/io.i"
@echo "... src/io.s"
@echo "... src/main.o"
@echo "... src/main.i"
@echo "... src/main.s"
@echo "... src/md2.o"
@echo "... src/md2.i"
@echo "... src/md2.s"
.PHONY : help
build:
mkdir build
build/%.o: src/%.c
@mkdir -p build
${CC} -c ${CFLAGS} -o $@ $<
#============================================================================= md2: ${OBJ}
# Special targets to cleanup operation of make. ${CC} -o $@ $(OBJ) ${LDFLAGS}
# Special rule to run CMake to check the build system integrity.
# No rule that depends on this can have commands that come from listfiles
# because they might be regenerated.
cmake_check_build_system:
$(CMAKE_COMMAND) -S$(CMAKE_SOURCE_DIR) -B$(CMAKE_BINARY_DIR) --check-build-system CMakeFiles/Makefile.cmake 0
.PHONY : cmake_check_build_system
.PHONY: all clean help