Page 1 of 3

Compiling Gargoyle for PC Engines Wrap, Alix and Ath5k

Posted: Thu Dec 08, 2022 5:52 am
by errikos
Hello,

I have a PC Engines Alix routerboard, a PC Engines Wrap routerboard and several Winstron CM9 and CM6 boards (Main Chipset Atheros AR5212, AR5111, AR2111)
I managed to install and boot gargoyle_1.13.0-x86-geode-combined-squashfs
root@Gargoyle:~# uname -a
Linux Gargoyle 4.14.261 #0 Thu Jan 6 14:31:19 2022 i586 GNU/Linux
but the wifi cards are not recognized and kmod-ath5k package is not available for installation.

When I installed latest OpenWRT and package kmod-ath5k they were recognized, however I prefer Gargoyle interface.

What is the easiest way to make these cards and the routerboard work with gargoyle?

1)Download the packages?
2)Download newest Gargoyle?
3)Compile and install newest gargoyle?
4)Compile and install all packages needed to recognize the cards?

For 1 and 2 I have not found anything ready made for x86 geode.

For 3 and 4 while I am comfortable with console I need a bit of assistance / how to compile.

Thank you!!

Re: Compiling Gargoyle for PC Engines Wrap, Alix and Ath5k

Posted: Thu Dec 08, 2022 9:33 am
by Lantis
Combination of 3 & 4. Compile with the required packages pre installed.
Start with an unmodified x86 build
https://github.com/ericpaulbishop/gargo ... /README.md

Re: Compiling Gargoyle for PC Engines Wrap, Alix and Ath5k

Posted: Fri Dec 09, 2022 10:47 am
by errikos
Compiling in Debian 11:

There are some errors :

Code: Select all

 /usr/bin/install -c -m 644 'patch.man' '/home/compiler/gargoyle/x86-src/staging_dir/host/share/man/man1/patch.1'
make[8]: Leaving directory '/home/compiler/gargoyle/x86-src/build_dir/host/patch-2.7.6'
make[7]: Leaving directory '/home/compiler/gargoyle/x86-src/build_dir/host/patch-2.7.6'
make[6]: Leaving directory '/home/compiler/gargoyle/x86-src/build_dir/host/patch-2.7.6'
make[5]: Leaving directory '/home/compiler/gargoyle/x86-src/build_dir/host/patch-2.7.6'
mkdir -p /home/compiler/gargoyle/x86-src/staging_dir/host/stamp
touch /home/compiler/gargoyle/x86-src/build_dir/host/patch-2.7.6/.built
touch /home/compiler/gargoyle/x86-src/staging_dir/host/stamp/.patch_installed
make[4]: Leaving directory '/home/compiler/gargoyle/x86-src/tools/patch'
time: tools/patch/compile#73.29#46.95#102.25
make[3]: Leaving directory '/home/compiler/gargoyle/x86-src'
make[2]: *** [tools/Makefile:155: /home/compiler/gargoyle/x86-src/staging_dir/target-i386_pentium4_musl/stamp/.tools_compile_yynyynnyyynyyyyynyynnyyyynyyyyyyyyyyyyyyyyyynynnyyynnyyy] Error 2
make[2]: Leaving directory '/home/compiler/gargoyle/x86-src'
make[1]: *** [/home/compiler/gargoyle/x86-src/include/toplevel . mk:227: world] Error 2
make[1]: Leaving directory '/home/compiler/gargoyle/x86-src'
find: ‘bin/packages/i386_pentium4’: No such file or directory
find: ‘’: No such file or directory
find: ‘’: No such file or directory
find: ‘bin/targets/x86/generic’: No such file or directory
find: ‘’: No such file or directory
find: ‘’: No such file or directory
ls: cannot access 'bin/targets': No such file or directory

root@DebianCompileVM:/home/compiler/gargoyle# make x86 FULL_BUILD=true > output.txt
Collecting target info: doneWARNING: Makefile 'package/utils/busybox/Makefile' has a dependency on 'libpam', which does not exist
WARNING: Makefile 'package/utils/busybox/Makefile' has a build dependency on 'libpam', which does not exist
WARNING: Makefile 'package/network/utils/curl/Makefile' has a dependency on 'libgnutls', which does not exist
WARNING: Makefile 'package/network/utils/curl/Makefile' has a dependency on 'libopenldap', which does not exist
WARNING: Makefile 'package/network/utils/curl/Makefile' has a dependency on 'libidn2', which does not exist
WARNING: Makefile 'package/network/utils/curl/Makefile' has a dependency on 'libssh2', which does not exist
WARNING: Makefile 'package/boot/kexec-tools/Makefile' has a dependency on 'liblzma', which does not exist
WARNING: Makefile 'package/network/services/lldpd/Makefile' has a dependency on 'libnetsnmp', which does not exist
WARNING: Makefile 'package/network/utils/nftables/Makefile' has a dependency on 'jansson', which does not exist
WARNING: Makefile 'package/sqlite3/Makefile' has a dependency on 'libedit', which does not exist
+ mkdir -p /home/compiler/gargoyle/x86-src/staging_dir/host
+ cd /home/compiler/gargoyle/x86-src/staging_dir/host
+ mkdir -p bin lib include stamp usr/include usr/lib
+ mkdir -p /home/compiler/gargoyle/x86-src/staging_dir/target-i386_pentium4_musl
+ cd /home/compiler/gargoyle/x86-src/staging_dir/target-i386_pentium4_musl
+ mkdir -p bin lib include stamp usr/include usr/lib
message.c: In function 'progress_speed.part.0':
message.c:378:35: warning: '%s' directive output may be truncated writing up to 23 bytes into a region of size between 0 and 14 [-Wformat-truncation=]
378 | snprintf(buf, sizeof(buf), "%.*f %s",
| ^~
message.c:378:2: note: 'snprintf' output between 3 and 337 bytes into a destination of size 16
378 | snprintf(buf, sizeof(buf), "%.*f %s",
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
379 | speed > 9.9 ? 0 : 1, speed, unit[unit_index]);
| ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~









configure: error: in `/home/compiler/gargoyle/x86-src/build_dir/host/tar-1.32':
configure: error: you should not run configure as root (set FORCE_UNSAFE_CONFIGURE=1 in environment to bypass this check)
See `config.log' for more details
make[4]: *** [Makefile:32: /home/compiler/gargoyle/x86-src/build_dir/host/tar-1.32/.configured] Error 1
make[3]: *** [tools/Makefile:159: tools/tar/compile] Error 2
make[3]: *** Waiting for unfinished jobs....
configure: WARNING: libattr development library was not found or not usable.
configure: WARNING: GNU patch will be built without xattr support.
make[2]: *** [tools/Makefile:155: /home/compiler/gargoyle/x86-src/staging_dir/target-i386_pentium4_musl/stamp/.tools_compile_yynyynnyyynyyyyynyynnyyyynyyyyyyyyyyyyyyyyyynynnyyynnyyy] Error 2
make[1]: *** [/home/compiler/gargoyle/x86-src/include/toplevel . mk:227: world] Error 2
find: ‘bin/packages/i386_pentium4’: No such file or directory
find: ‘’: No such file or directory
find: ‘’: No such file or directory
find: ‘bin/targets/x86/generic’: No such file or directory
find: ‘’: No such file or directory
find: ‘’: No such file or directory
ls: cannot access 'bin/targets': No such file or directory
root@DebianCompileVM:/home/compiler/gargoyle#

Re: Compiling Gargoyle for PC Engines Wrap, Alix and Ath5k

Posted: Fri Dec 09, 2022 7:24 pm
by Lantis
You can’t build as root.
Kill your build environment and start again as a non root user is a folder that the regular user has permissions for.

Re: Compiling Gargoyle for PC Engines Wrap, Alix and Ath5k

Posted: Wed Dec 21, 2022 8:43 am
by errikos
Ok! Compilation is running severa hours now.

What are the next steps when it is finished?!

EDIT: Compile output error:

touch /home/comp/gargoyle/x86-src/staging_dir/target-x86_64_musl/root-x86/stamp/.openssl-util_installed
echo "openssl-util" >> /home/comp/gargoyle/x86-src/staging_dir/target-x86_64_musl/pkginfo/openssl.default.install
make[4]: Leaving directory '/home/comp/gargoyle/x86-src/package/libs/openssl'
time: package/libs/openssl/compile#90.00#7.35#158.29
make[3]: Leaving directory '/home/comp/gargoyle/x86-src'
make[2]: *** [package/Makefile:107: /home/comp/gargoyle/x86-src/staging_dir/target-x86_64_musl/stamp/.package_compile] Error 2
make[2]: Leaving directory '/home/comp/gargoyle/x86-src'
make[1]: *** [/home/comp/gargoyle/x86-src/include/toplevel. mk:227: world] Error 2
make[1]: Leaving directory '/home/comp/gargoyle/x86-src'
comp@debiancomp:~/gargoyle$

Compiling on Debian 11
comp@debiancomp:~$ uname -a
Linux debiancomp 5.10.0-20-686-pae #1 SMP Debian 5.10.158-2 (2022-12-13) i686 GNU/Linux

Re: Compiling Gargoyle for PC Engines Wrap, Alix and Ath5k

Posted: Thu Dec 22, 2022 7:07 am
by Lantis
That doesn't show enough of the error.
Please run

Code: Select all

make FULL_BUILD=true x86.alix BUILD_THREADS=1

Re: Compiling Gargoyle for PC Engines Wrap, Alix and Ath5k

Posted: Fri Dec 30, 2022 4:24 am
by errikos
Built completed successfully!!
So excited!

Code: Select all

Generating index for package ./webmon-gargoyle_1.13.0-1_i386_pentium.ipk
Generating index for package ./wireguard-tools_1.0.20191226-1_i386_pentium.ipk
Generating index for package ./wireguard_1.0.20200611-2_i386_pentium.ipk
Generating index for package ./wwan_2014-07-17-1_i386_pentium.ipk
Generating index for package ./zip_3.0-4_i386_pentium.ipk
Generating index for package ./zlib_1.2.11-4_i386_pentium.ipk
Signing package index...
make[3]: Leaving directory '/home/comp/gargoyle/x86-src'
export MAKEFLAGS= ;make -w -r json_overview_image_info
make[3]: Entering directory '/home/comp/gargoyle/x86-src'
make[3]: Nothing to be done for 'json_overview_image_info'.
make[3]: Leaving directory '/home/comp/gargoyle/x86-src'
export MAKEFLAGS= ;make -w -r checksum
make[3]: Entering directory '/home/comp/gargoyle/x86-src'
make[3]: Leaving directory '/home/comp/gargoyle/x86-src'
make[2]: Leaving directory '/home/comp/gargoyle/x86-src'
make[1]: Leaving directory '/home/comp/gargoyle/x86-src'
comp@comp:~/gargoyle$
comp@comp:~/gargoyle$
comp@comp:~/gargoyle$
comp@comp:~/gargoyle$
next steps?!

Re: Compiling Gargoyle for PC Engines Wrap, Alix and Ath5k

Posted: Fri Dec 30, 2022 4:40 am
by Lantis
The successfully compiled images are in the "images" folder in the gargoyle folder.

Re: Compiling Gargoyle for PC Engines Wrap, Alix and Ath5k

Posted: Fri Dec 30, 2022 5:57 am
by errikos
so, these images contain the packages that are required by CM6 and CM9 ? (I think its kmod-ath5k)

Re: Compiling Gargoyle for PC Engines Wrap, Alix and Ath5k

Posted: Fri Dec 30, 2022 7:23 am
by Lantis
Well what step are you up to? Did you just do a compile of the default x86.alix to test that your build environment is good?

The next step is to customise it to include the necessary drivers, then build it again.