deb build

This commit is contained in:
Alfie King 2024-10-23 11:28:23 +01:00
parent e53fd06a68
commit b8a41bd474
3 changed files with 19 additions and 5 deletions

View File

@ -1,6 +1,4 @@
cmake_minimum_required(VERSION 3.5) 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) project(owo)
add_executable(owo src/main.cpp) add_executable(owo src/main.cpp)
target_link_libraries(owo) target_link_libraries(owo)

View File

@ -1,4 +1,4 @@
all: dirs build_unix all: clean dirs build_all
dirs: dirs:
@mkdir -p build/ @mkdir -p build/
@ -6,8 +6,6 @@ dirs:
clean: clean:
@rm -rf build/ @rm -rf build/
build_all: build_unix build_win
build_unix: build_unix:
@echo "Building for unix..." @echo "Building for unix..."
g++ -o build/owo src/main.cpp g++ -o build/owo src/main.cpp
@ -16,4 +14,21 @@ build_win:
@echo "Building for windows..." @echo "Building for windows..."
x86_64-w64-mingw32-g++ -o build/owo.exe src/main.cpp 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 .PHONY: all dirs clean build_all build_unix build_win

1
src/term-owo-cpp Submodule

@ -0,0 +1 @@
Subproject commit e53fd06a680352b424b41d4a97ebee15b16f3ee4