https://github.com/soramimi/Guitar
https://soramimi.github.io/Guitar/

Guitar v1.2.999 (62c0516)
Git GUI Client  

rust Qt5 cmake

ca-certificates.tcz is installed 
sudo mkdir -p /etc/ssl/
sudo ln -s /usr/local/etc/ssl/certs /etc/ssl/certs

install latest rust compiler:
    # https://www.rust-lang.org/tools/install
    # reference: https://github.com/rust-lang/rust
curl --proto '=https' --tlsv1.2 -sSf https://sh.rustup.rs | sh

Development dependencies:
tce-load -i compiletc automake cmake bash yasm gettext-dev coreutils groff pkg-config pcre-dev liblzma-dev intltool

Building on a Unix-like system

Make sure you have installed the dependencies:
    g++ 5.1 or later or clang++ 3.5 or later
    python 3 or 2.7
    GNU make 3.81 or later
    cmake 3.4.3 or later
    curl
    git
    ssl which comes in libssl-dev or openssl-devel
    pkg-config if you are compiling on Linux and targeting Linux
    fontconfig-dev


source $HOME/.cargo/env

git clone https://github.com/soramimi/Guitar.git

https://soramimi.github.io/Guitar/html/build-en.html

Development dependencies:
tce-load -i ruby.tcz perl5.tcz qt-5.x-dev.tcz zlib_base-dev.tcz openssl-1.1.1-dev.tcz

cd Guitar
edit Guitar-amd64.pro
    #OPENSSL_LIB_DIR = /usr/lib/x86_64-linux-gnu
    OPENSSL_LIB_DIR = /usr/local/lib
ruby prepare.rb
qmake Guitar-amd64.pro

this is a cmake project

mkdir my_build_dir                              # 1. Create build directory
cd my_build_dir

cmake .. -LAH # review the _INSTALL_ DIRs

rm -f CMakeCache.txt # as needed to completely rebuild the CMAke cache

cmake .. -DCMAKE_INSTALL_PREFIX=my_install_dir   \
         -DCMAKE_INSTALL_LIBDIR=lib              \
         -DCMAKE_BUILD_TYPE=Release              \
         -DBUILD_TESTING=OFF                     \
         -Wno-dev                                \
         -DCMAKE_C_FLAGS_RELEASE="-flto -mtune=generic -Os -pipe" \
         -DCMAKE_CXX_FLAGS_RELEASE="-flto -mtune=generic -Os -pipe -fexceptions"

# I tried but didn't compile with -DCMAKE_CXX_FLAGS_RELEASE="-flto -mtune=generic -Os -pipe -fno-exceptions -fno-rtti"
cmake --build . -- help
mkdir /tmp/my_guitar

cmake --build . -- -B guitar-lib_autogen DESTDIR=/tmp/my_guitar
cmake --build . -- -B Guitar_autogen DESTDIR=/tmp/my_guitar
cmake --build . -- -B all DESTDIR=/tmp/my_guitar

compiled to my_build_dir   ... oh well, not sure why not DESTDIR=/tmp/my_guitar
sstrip ./Guitar

        ?? release.sh (commenting out the non-Linux builds)
    # not these usual rust methods
    # cargo build  (from dir with Cargo.toml)
    # cargo install --path .

find ./squashfs-root -exec touch -m --reference=./squashfs-root/usr/local/bin/guitar {} +

mksquashfs ./squashfs-root ./guitar.tcz -noappend -no-xattrs
mksquashfs ./squashfs-root ./guitar-doc.tcz -noappend -no-xattrs

test with
base norestore  

Runtime dependencies: guitar.tcz.dep
    qt-5.x-all.tcz
    git.tcz
    file.tcz

submitqc --color --libs --fix --strip ./guitar.tcz
submitqc --color --libs --fix --strip ./guitar-doc.tcz

# get the extension files dates the same as tcz
for file in guitar.tcz; do touch --no-create --reference=./squashfs-root/usr/local/bin/guitar $file; done
for file in guitar.tcz.*; do touch --no-create --reference=guitar.tcz $file; done
for file in guitar-doc.tcz.*; do touch --no-create --reference=guitar-doc.tcz $file; done

# set the permissions
for file in guitar.*; do chmod 666 $file; done
for file in guitar-doc.*; do chmod 666 $file; done

#tar all necessary and optional files, example:
tar cvzf ./guitar.tar.gz ./guitar/
tar cvzf ./guitar-doc.tar.gz ./guitar-doc/

save this file with name compile_guitar
