Tiny Core Linux

Tiny Core Base => CorePlus => Topic started by: john110 on July 19, 2020, 02:23:04 AM

Title: Can someone ELI5 me how to create tcz extensions?
Post by: john110 on July 19, 2020, 02:23:04 AM
Hello,

I need to install several apps such as keepassxc https://github.com/keepassxreboot/keepassxc/ (https://github.com/keepassxreboot/keepassxc/), lbry.tv https://github.com/lbryio/lbrytv (https://github.com/lbryio/lbrytv) and so many other applications that aren't present in the repos.

I tried to google how to create tcz extensions, but I couldn't understand a damn thing, to be honest, the documentations seemed to skip a lot of steps and It seemed to be aimed towards experimented users...

So, I'm kindly asking for a nice and gentle soul to be able to Eli5 me and provides me step by step instructions on how to install an app that isn't present in the official repo  :)

Thank you a lot for your help
Title: Re: Can someone ELI5 me how to create tcz extensions?
Post by: Sashank999 on July 19, 2020, 02:32:14 AM
Hi john110,

First do `tce-load -i squashfs-tools findutils` then do this after you unpack the source and the ./configure or make or cmake steps :
You need to make squashfs extensions out of the installed apps:
Code: [Select]
...
$ touch mymarker
$ sudo make install
$ sudo find / -not -type 'd' -cnewer mymarker | grep -v "\/proc\/" | grep -v "^\/sys\/" | tee files
$ vi files [edit unneeded files]
$ sudo tar -T files --numeric-owner -zcvf extension.tce
$ mkdir /tmp/pkg
$ cp extension.tce /tmp/pkg
$ cd /tmp/pkg
$ sudo tar xf extension.tce
$ rm extension.tce
$ cd ..
$ sudo mksquashfs pkg/ extension.tcz

This is enough to create personal tcz. You can move it to your tce/optional directory and add it to your onboot.lst so that it can be loaded on every boot instead of typing tce-load every time.
Title: Re: Can someone ELI5 me how to create tcz extensions?
Post by: Juanito on July 19, 2020, 02:32:52 AM
Have you seen:

http://wiki.tinycorelinux.net/doku.php?id=wiki:creating_extensions

http://tinycorelinux.net/11.x/x86_64/tcz/src/keepassx/
Title: Re: Can someone ELI5 me how to create tcz extensions?
Post by: john110 on July 19, 2020, 03:17:15 AM
Hi john110,

First do `tce-load -i squashfs-tools findutils` then do this after you unpack the source and the ./configure or make or cmake steps :
You need to make squashfs extensions out of the installed apps:
Code: [Select]
...
$ touch mymarker
$ sudo make install
$ sudo find / -not -type 'd' -cnewer mymarker | grep -v "\/proc\/" | grep -v "^\/sys\/" | tee files
$ vi files [edit unneeded files]
$ sudo tar -T files --numeric-owner -zcvf extension.tce
$ mkdir /tmp/pkg
$ cp extension.tce /tmp/pkg
$ cd /tmp/pkg
$ sudo tar xf extension.tce
$ rm extension.tce
$ cd ..
$ sudo mksquashfs pkg/ extension.tcz

This is enough to create personal tcz. You can move it to your tce/optional directory and add it to your onboot.lst so that it can be loaded on every boot instead of typing tce-load every time.

After sudo make install, I get an error:

Quote
*** No rule to make target 'install'. Stop.



Have you seen:

http://wiki.tinycorelinux.net/doku.php?id=wiki:creating_extensions

http://tinycorelinux.net/11.x/x86_64/tcz/src/keepassx/

Yes, I already read both and they don't help me much...
Title: Re: Can someone ELI5 me how to create tcz extensions?
Post by: Juanito on July 19, 2020, 03:29:42 AM
Using: http://tinycorelinux.net/11.x/x86_64/tcz/src/keepassx/

You need to do this first:
Code: [Select]
$ tce-load -i compiletc cmake libgcrypt-dev qt-5.x-dev zlib_base-dev

$ cd keepassx*

$ mkdir build
$ cd build

$ cmake -DCMAKE_C_FLAGS_RELEASE="-flto -fuse-linker-plugin -march=i486 -mtune=i686 -Os -pipe" -DCMAKE_CXX_FLAGS_RELEASE="-flto -fuse-linker-plugin -march=i486 -mtune=i686 -Os -pipe -fno-exceptions -fno-rtti" -DCMAKE_INSTALL_PREFIX=/usr/local -DCMAKE_BUILD_TYPE=Release -DCMAKE_VERBOSE_MAKEFILE=TRUE -DWITH_GUI_TESTS=ON -DWITH_CXX11=ON ../

$ make
Title: Re: Can someone ELI5 me how to create tcz extensions?
Post by: john110 on July 19, 2020, 04:35:32 AM
Using: http://tinycorelinux.net/11.x/x86_64/tcz/src/keepassx/

You need to do this first:
Code: [Select]
$ tce-load -i compiletc cmake libgcrypt-dev qt-5.x-dev zlib_base-dev

$ cd keepassx*

$ mkdir build
$ cd build

$ cmake -DCMAKE_C_FLAGS_RELEASE="-flto -fuse-linker-plugin -march=i486 -mtune=i686 -Os -pipe" -DCMAKE_CXX_FLAGS_RELEASE="-flto -fuse-linker-plugin -march=i486 -mtune=i686 -Os -pipe -fno-exceptions -fno-rtti" -DCMAKE_INSTALL_PREFIX=/usr/local -DCMAKE_BUILD_TYPE=Release -DCMAKE_VERBOSE_MAKEFILE=TRUE -DWITH_GUI_TESTS=ON -DWITH_CXX11=ON ../

$ make

Quote
can't cd to keepassx*: No such file or directory
Title: Re: Can someone ELI5 me how to create tcz extensions?
Post by: Juanito on July 19, 2020, 04:37:39 AM
Code: [Select]
$ wget https://github.com/keepassxreboot/keepassxc/releases/download/2.6.0/keepassxc-2.6.0-src.tar.xz
$ tar xf keepassxc-2.6.0-src.tar.xz
$ cd keepassxc*
Title: Re: Can someone ELI5 me how to create tcz extensions?
Post by: john110 on July 19, 2020, 05:17:07 AM
Code: [Select]
$ wget https://github.com/keepassxreboot/keepassxc/releases/download/2.6.0/keepassxc-2.6.0-src.tar.xz
$ tar xf keepassxc-2.6.0-src.tar.xz
$ cd keepassxc*

I can't send all terminal logs unfortunately, because I don't know how to copy them (ctrl + c doesn't work and I can't drag and drop them).

I got errors:

Quote
-- Configuring incomplete, errors occured!

See also "/home/tc/keepassxc-2.6.0/build/CMakeFiles/CMakeOutput.log
See also "/home/tc/keepassxc-2.6.0/build/CMakeFiles/CMakeError.log

Pastebin link to: CMakeOutput.log -> https://pastebin.com/raw/JFFmRFWE (https://pastebin.com/raw/JFFmRFWE)
Pastebin link to: CMakeError.log -> https://pastebin.com/raw/MNxzKfWK (https://pastebin.com/raw/MNxzKfWK)
Title: Re: Can someone ELI5 me how to create tcz extensions?
Post by: Juanito on July 19, 2020, 05:37:07 AM
From CMakeLists.txt:
Code: [Select]
find_package(LibGPGError REQUIRED)
find_package(Gcrypt 1.7.0 REQUIRED)
find_package(Argon2 REQUIRED)
find_package(ZLIB REQUIRED)
find_package(QREncode REQUIRED)
find_package(sodium 1.0.12 REQUIRED)
..so it seems you'll need argon, qrencode and sodium.

You could also try an older version, which might not need those additional deps.
Title: Re: Can someone ELI5 me how to create tcz extensions?
Post by: john110 on July 19, 2020, 06:43:38 AM
From CMakeLists.txt:
Code: [Select]
find_package(LibGPGError REQUIRED)
find_package(Gcrypt 1.7.0 REQUIRED)
find_package(Argon2 REQUIRED)
find_package(ZLIB REQUIRED)
find_package(QREncode REQUIRED)
find_package(sodium 1.0.12 REQUIRED)
..so it seems you'll need argon, qrencode and sodium.


How can I get these, I can't find any of them in the repo...?
Title: Re: Can someone ELI5 me how to create tcz extensions?
Post by: Juanito on July 19, 2020, 07:05:49 AM
Things seem to work if you use this: http://tinycorelinux.net/11.x/x86_64/tcz/src/keepassx/keepassx-master-commit_1682ab9.zip
Title: Re: Can someone ELI5 me how to create tcz extensions?
Post by: john110 on July 19, 2020, 07:41:08 AM
Things seem to work if you use this: http://tinycorelinux.net/11.x/x86_64/tcz/src/keepassx/keepassx-master-commit_1682ab9.zip

I downloaded it, what should I do, now?
Title: Re: Can someone ELI5 me how to create tcz extensions?
Post by: Juanito on July 19, 2020, 07:49:38 AM
Unzip it, cd into it, then use the same instructions.
Title: Re: Can someone ELI5 me how to create tcz extensions?
Post by: john110 on July 19, 2020, 08:25:59 AM
Unzip it, cd into it, then use the same instructions.

Quote
CMakae Warning:
Manually-specified variables were not used by the project:

WITH_CXX11

-- Build files have been written to: /home/tc/Downloads/keepassx-master-commit_1682ab9/keepassx-master/build

What's up next? (I have a folder, but still no tcz extension)
Title: Re: Can someone ELI5 me how to create tcz extensions?
Post by: Juanito on July 19, 2020, 09:25:03 AM
The necessary commands are all listed in this thread, please take a moment to look through them to see what comes next.
Title: Re: Can someone ELI5 me how to create tcz extensions?
Post by: Juanito on July 20, 2020, 08:13:10 AM
keepassx posted
Title: Re: Can someone ELI5 me how to create tcz extensions?
Post by: Rich on July 20, 2020, 08:23:25 AM
Hi Juanito
I looks like john110 may have deleted his account.
Title: Re: Can someone ELI5 me how to create tcz extensions?
Post by: Juanito on July 20, 2020, 09:38:09 AM
hopefully somebody else will find it useful...
Title: Re: Can someone ELI5 me how to create tcz extensions?
Post by: Greg Erskine on July 20, 2020, 04:44:54 PM
I think john110 may have morphed into aneverydayhumanuser.  ;D
Title: Re: Can someone ELI5 me how to create tcz extensions?
Post by: PDP-8 on July 20, 2020, 05:52:28 PM
I find refreshers useful, and I also use KeePassx from time to time.

Thanks Juanito!
Title: Re: Can someone ELI5 me how to create tcz extensions?
Post by: PDP-8 on July 20, 2020, 10:43:34 PM
OK, I'll try to be a bit nicer this time around...

One of the few youtube videos that show how to make tcz's.  I found it useful a few years ago when making mine, even though it mimics what's in the core book.

https://www.youtube.com/watch?v=yRm-YRuLFio

HTH.