Zum Inhalt

rephlex.de Posts

Workaround of the month: Fix broken n32 o32 virtalenv on Gentoo mips when emerging spidermonkey-52.9.1pre1

Virtualenv ist utterly broken when you run Gentoo on MIPS using n32.

This will lead to spidermonkey-52.9.1pre1 failing to emerge, because of „ImportError: No module named pkgutil“ or the like. Here’s how to fix it:

Step 1: as root, create a user patch directory and download my patch for virtualenv into it, so emerge applies it to the source as soon as you re-emerge the package

mkdir -p /etc/portage/patches/dev-python/virtualenv-16.0.0
wget -O /etc/portage/patches/dev-python/virtualenv-16.0.0/virtualenv-16.0.0-multilib.patch https://rephlex.de/blog/wp-content/uploads/2019/01/virtualenv-16.0.0-multilib.patch.txt

Step 2: and download multiarch.patch into the directory we just created

Step 3: as root, test if the patch executes:

cd /usr/portage/dev-python/virtualenv
ebuild virtualenc-16.0.0.ebuild clean prepare

Step 4: re-emerge dev-lang/python-exec and dev-python/virtualenv

emerge dev-lang/python-exec dev-python/virtualenv

Step 5: Create a necessary symlink

ln -s /usr/lib32/python2.7 /usr/lib/python2.7

You’re done!

Leave a Comment

Fix errors when compiling Linux Kernel 4.12 with GCC 8

Error:

In file included from arch/mips/kernel/syscall.c:17:
./include/linux/syscalls.h:196:18: Fehler: »sys_mips_mmap« Alias zwischen unverträglichen Funktionstypen »long int(long unsigned int, long unsigned int, long unsigned int, long unsigned int, long unsigned int, off_t)« {alias »long int(long unsigned int, long unsigned int, long unsigned int, long unsigned int, long unsigned int, long int)«} und »long int(long int, long int, long int, long int, long int, long int)« [-Werror=attribute-alias]

Solution:

echo „KBUILD_CFLAGS += -Wno-error=attribute-alias“ >> Makefile

Leave a Comment

Gentoo GNU/Linux on an SGI Octane

Finally!

More info will be coming soon. Just come teaser to get you interested 😉

I AM running Linux 4.12 in full 64 bits, gcc 8, a current glibc, and all the modern software. WITH audio. WITH accellerated graphics. And my root volume is on 3x147GB SCSI Software RAID-0 stripeset goodness. And yes, I do have multiple backups. Boom!

rephlex@octane ~ $ uname -a && cat /etc/*release && cat /proc/cpuinfo && df -h && free -m
Linux octane 4.12.0 #2 SMP Fri Dec 14 21:41:04 CET 2018 mips64 R12000 V2.3 FPU V0.0 SGI Octane GNU/Linux
Gentoo Base System release 2.2
NAME=Gentoo
ID=gentoo
PRETTY_NAME=“Gentoo/Linux“
ANSI_COLOR=“1;32″
HOME_URL=“http://www.gentoo.org/“
SUPPORT_URL=“http://www.gentoo.org/main/en/support.xml“
BUG_REPORT_URL=“https://bugs.gentoo.org/“
system type : SGI Octane
machine : Unknown
processor : 0
cpu model : R12000 V2.3 FPU V0.0
BogoMIPS : 449.02
wait instruction : no
microsecond timers : yes
tlb_entries : 64
extra interrupt vector : no
hardware watchpoint : yes, count: 0, address/irw mask: []
isa : mips1 mips2 mips3 mips4
ASEs implemented :
shadow register sets : 1
kscratch registers : 0
package : 0
core : 0
VCED exceptions : not available
VCEI exceptions : not available

processor : 1
cpu model : R12000 V2.3 FPU V0.0
BogoMIPS : 449.02
wait instruction : no
microsecond timers : yes
tlb_entries : 64
extra interrupt vector : no
hardware watchpoint : yes, count: 0, address/irw mask: []
isa : mips1 mips2 mips3 mips4
ASEs implemented :
shadow register sets : 1
kscratch registers : 0
package : 0
core : 0
VCED exceptions : not available
VCEI exceptions : not available

Dateisystem Größe Benutzt Verf. Verw% Eingehängt auf
/dev/root 133G 3,1G 123G 3% /
devtmpfs 10M 0 10M 0% /dev
tmpfs 62M 224K 62M 1% /run
shm 310M 0 310M 0% /dev/shm
/dev/md127 269G 7,9G 247G 4% /home
gesamt benutzt frei gemns. Puffer/Cache verfügbar
Speicher: 619 123 63 0 432 471
Swap: 7999 3 7996

1 Comment

I build a Y-6 FPV Hexacopter

Here it is: A Y6 hexacopter build from scrap parts and a self printed TPU frame.

Pardon the build quality. I really hacked it together in a total of 4 hours. It looks like sh*t, but it flies SO GOOD!

It’s running Betaflight 3.5. The motors are just some random Racerstars – two different sizes even! 2206 on top, 2205 on the bottom. The ESCs are two 20A and 4 30A (Racerstar and Makerfire).

Leave a Comment

Create a video clip from a set of images using ffmpeg

imagine your image folder looks like this:

rephlex@hera:[~/Schreibtisch/gna]: ls -1 * | head
G0037679.JPG
G0037680.JPG
G0037681.JPG
G0037682.JPG
G0037683.JPG
G0037684.JPG
G0037685.JPG
G0037686.JPG
G0037687.JPG
G0037688.JPG

[…]

This is the command you’re looking for:

ffmpeg -framerate 25 -start_number 37679 -i G00%05d.JPG -c:v libx264 -profile:v high -crf 20 -pix_fmt yuv420p output.mp4

Leave a Comment