From b8a41bd474dafe93f2cb8798740554d8598e15bc Mon Sep 17 00:00:00 2001 From: Alfie King Date: Wed, 23 Oct 2024 11:28:23 +0100 Subject: [PATCH] deb build --- CMakeLists.txt | 2 -- makefile | 21 ++++++++++++++++++--- src/term-owo-cpp | 1 + 3 files changed, 19 insertions(+), 5 deletions(-) create mode 160000 src/term-owo-cpp diff --git a/CMakeLists.txt b/CMakeLists.txt index e841582..0835c30 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -1,6 +1,4 @@ cmake_minimum_required(VERSION 3.5) -find_program(CMAKE_C_COMPILER NAMES $ENV{CC} gcc PATHS ENV PATH NO_DEFAULT_PATH) -find_program(CMAKE_CXX_COMPILER NAMES $ENV{CXX} g++ PATHS ENV PATH NO_DEFAULT_PATH) project(owo) add_executable(owo src/main.cpp) target_link_libraries(owo) diff --git a/makefile b/makefile index 30fc4ab..7a422cb 100644 --- a/makefile +++ b/makefile @@ -1,4 +1,4 @@ -all: dirs build_unix +all: clean dirs build_all dirs: @mkdir -p build/ @@ -6,8 +6,6 @@ dirs: clean: @rm -rf build/ -build_all: build_unix build_win - build_unix: @echo "Building for unix..." g++ -o build/owo src/main.cpp @@ -16,4 +14,21 @@ build_win: @echo "Building for windows..." x86_64-w64-mingw32-g++ -o build/owo.exe src/main.cpp +make_deb: + mkdir build/owo_deb + mkdir build/owo_deb/DEBIAN + mkdir -p build/owo_deb/usr/local/bin + cp build/owo build/owo_deb/usr/local/bin + touch build/owo_deb/DEBIAN/control + echo "Package: owo" >> build/owo_deb/DEBIAN/control + echo "Version: 1.0" >> build/owo_deb/DEBIAN/control + echo "Maintainer: Alfie King" >> build/owo_deb/DEBIAN/control + echo "Architecture: amd64" >> build/owo_deb/DEBIAN/control + echo "Description: owoify text" >> build/owo_deb/DEBIAN/control + dpkg-deb --build build/owo_deb + mv build/owo_deb.deb build/owo.deb + rm -rf build/owo_deb + +build_all: build_unix build_win make_deb + .PHONY: all dirs clean build_all build_unix build_win \ No newline at end of file diff --git a/src/term-owo-cpp b/src/term-owo-cpp new file mode 160000 index 0000000..e53fd06 --- /dev/null +++ b/src/term-owo-cpp @@ -0,0 +1 @@ +Subproject commit e53fd06a680352b424b41d4a97ebee15b16f3ee4