commit eb203bcf00d821598e9639222b153b312a035406 Author: portnoytmy Date: Mon Jun 2 22:43:21 2025 +0200 Initiales Commit für BS_Praktikum4 Projekt diff --git a/.gitignore b/.gitignore new file mode 100644 index 0000000..80ccb77 --- /dev/null +++ b/.gitignore @@ -0,0 +1,30 @@ +# Build-Verzeichnisse +build/ +bin/ +lib/ + +# CMake-Dateien +CMakeFiles/ +CMakeCache.txt +cmake_install.cmake +Makefile + +# Compiled Object files +*.o +*.obj + +# Shared objects +*.so +*.dylib +*.dll + +# Executables +*.exe +*.out +*.app + +# IDE-spezifische Dateien +.vscode/ +.idea/ +*.swp +*~ diff --git a/BS_Praktikum4.cpp b/BS_Praktikum4.cpp new file mode 100644 index 0000000..0af24eb --- /dev/null +++ b/BS_Praktikum4.cpp @@ -0,0 +1,11 @@ +/** + * @file BS_Praktikum4.cpp + * @brief Implementierung der Funktionen für das BS_Praktikum4 Projekt + */ + +#include "BS_Praktikum4.h" +#include + +void sayHello() { + std::cout << "Hallo aus der BS_Praktikum4 Implementierung!" << std::endl; +} diff --git a/BS_Praktikum4.h b/BS_Praktikum4.h new file mode 100644 index 0000000..5fdb736 --- /dev/null +++ b/BS_Praktikum4.h @@ -0,0 +1,14 @@ +/** + * @file BS_Praktikum4.h + * @brief Hauptheader für das BS_Praktikum4 Projekt + */ + +#ifndef BS_Praktikum4_H +#define BS_Praktikum4_H + +/** + * @brief Gibt eine Begrüßungsnachricht aus + */ +void sayHello(); + +#endif // BS_Praktikum4_H diff --git a/CMakeLists.txt b/CMakeLists.txt new file mode 100644 index 0000000..c825721 --- /dev/null +++ b/CMakeLists.txt @@ -0,0 +1,25 @@ +cmake_minimum_required(VERSION 3.10) +project(BS_Praktikum4 VERSION 0.1.0 LANGUAGES CXX) + +# Compiler-Optionen +set(CMAKE_CXX_STANDARD 17) +set(CMAKE_CXX_STANDARD_REQUIRED ON) +set(CMAKE_CXX_EXTENSIONS OFF) + +# Warnungen und Debug-Informationen bei Entwicklung aktivieren +if(CMAKE_BUILD_TYPE STREQUAL "Debug") + set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -Wall -Wextra -Wpedantic -g") +endif() + +# Aktuelles Verzeichnis als Include-Pfad hinzufügen +include_directories(.) + +# Quellen sammeln +file(GLOB SOURCES *.cpp) +file(GLOB HEADERS *.h *.hpp) + +# Ausführbare Datei erstellen +add_executable(${PROJECT_NAME} ${SOURCES}) + +# Installation konfigurieren +install(TARGETS ${PROJECT_NAME} DESTINATION bin) diff --git a/README.md b/README.md new file mode 100644 index 0000000..e69de29 diff --git a/main.cpp b/main.cpp new file mode 100644 index 0000000..6b4677f --- /dev/null +++ b/main.cpp @@ -0,0 +1,16 @@ +/** + * @file main.cpp + * @brief Hauptdatei für das BS_Praktikum4 Projekt + */ + +#include +#include "BS_Praktikum4.h" + +int main() { + std::cout << "Willkommen zum BS_Praktikum4 Projekt!" << std::endl; + + // Beispielaufruf einer Funktion aus der Header-Datei + sayHello(); + + return 0; +}