Compare commits
9 Commits
fd6b5cb8de
...
latest
Author | SHA1 | Date | |
---|---|---|---|
5274c8a839 | |||
fb77671c94 | |||
21f2d4c5ab | |||
11ef7f988d | |||
d24dce7ffe | |||
13a50afcca | |||
b8a41bd474 | |||
e53fd06a68 | |||
19b8a1921e |
1
.gitignore
vendored
1
.gitignore
vendored
@@ -34,3 +34,4 @@
|
|||||||
|
|
||||||
# Build files
|
# Build files
|
||||||
build/
|
build/
|
||||||
|
.vscode/
|
5
PKGBUILD
5
PKGBUILD
@@ -1,4 +1,4 @@
|
|||||||
pkgname="term-owo-git"
|
pkgname="owo"
|
||||||
pkgver=1.0
|
pkgver=1.0
|
||||||
pkgrel=1
|
pkgrel=1
|
||||||
pkgdesc="A simple C++ program that owofies text"
|
pkgdesc="A simple C++ program that owofies text"
|
||||||
@@ -12,8 +12,7 @@ md5sums=('SKIP')
|
|||||||
|
|
||||||
build() {
|
build() {
|
||||||
cd "$srcdir/term-owo-cpp"
|
cd "$srcdir/term-owo-cpp"
|
||||||
cmake . -B build
|
make dirs build_unix
|
||||||
cd build && make
|
|
||||||
}
|
}
|
||||||
|
|
||||||
package() {
|
package() {
|
||||||
|
11
README.md
11
README.md
@@ -28,11 +28,8 @@ $ ./owo -o output.txt "Hello, world!"
|
|||||||
```
|
```
|
||||||
|
|
||||||
## Building
|
## Building
|
||||||
to build the program, you will need a c++ compiler. I have no idea what im doing with cmake so this uses a very basic make file that is made to build the linux and windows binaries.
|
|
||||||
If you are on windows, good luck. I have no clue how to setup g++ on windows. I would recommend using WSL or a VM. If you are on linux, you can build the program with the following commands
|
|
||||||
(assuming you have g++ installed):
|
|
||||||
```bash
|
```bash
|
||||||
$ make
|
$ make dirs build_unix
|
||||||
$ ./owo "Hello, world!"
|
$ ./owo "Hello, world!"
|
||||||
hewwo, wowld!
|
hewwo, wowld!
|
||||||
```
|
```
|
||||||
@@ -47,6 +44,12 @@ $ cd term-owo-cpp
|
|||||||
$ makepkg -si
|
$ makepkg -si
|
||||||
```
|
```
|
||||||
#### Custom Repo
|
#### Custom Repo
|
||||||
|
/etc/pacman.conf
|
||||||
|
```
|
||||||
|
[alfieking.dev]
|
||||||
|
Server = https://repo.alfieking.dev/x86_64
|
||||||
|
```
|
||||||
|
bash
|
||||||
```bash
|
```bash
|
||||||
$ pacman-key --recv-keys 1553B1410D80686C8D2A27338035E1AC0B1440DC
|
$ pacman-key --recv-keys 1553B1410D80686C8D2A27338035E1AC0B1440DC
|
||||||
$ pacman-key --lsign-key 1553B1410D80686C8D2A27338035E1AC0B1440DC
|
$ pacman-key --lsign-key 1553B1410D80686C8D2A27338035E1AC0B1440DC
|
||||||
|
28
makefile
28
makefile
@@ -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,28 @@ 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
|
||||||
|
|
||||||
|
make_arch:
|
||||||
|
mkdir build/owo_arch
|
||||||
|
cp PKGBUILD build/owo_arch
|
||||||
|
makepkg -D build/owo_arch
|
||||||
|
cp build/owo_arch/owo-1.0-1-x86_64.pkg.tar.zst build/owo.pkg.tar.zst
|
||||||
|
rm -rf build/owo_arch
|
||||||
|
|
||||||
|
build_all: build_unix build_win make_deb make_arch
|
||||||
|
|
||||||
.PHONY: all dirs clean build_all build_unix build_win
|
.PHONY: all dirs clean build_all build_unix build_win
|
Reference in New Issue
Block a user