1
0
Fork 0
Browse Source

Fájlok feltöltése a következőre: 'tools'

master
Varga Pál 3 years ago
parent
commit
b55423156a
  1. 3
      tools/install.sh
  2. 31
      tools/sysroot-relativelinks.py
  3. 9
      tools/sysroot.sh

3
tools/install.sh

@ -0,0 +1,3 @@
#!/bin/bash
rsync -avzL --rsync-path="sudo rsync" --delete qt5.15.2 root@192.168.1.100:/usr/local

31
tools/sysroot-relativelinks.py

@ -0,0 +1,31 @@
#!/usr/bin/env python
import sys
import os
# Take a sysroot directory and turn all the abolute symlinks and turn them into
# relative ones such that the sysroot is usable within another system.
if len(sys.argv) != 2:
print("Usage is " + sys.argv[0] + "<directory>")
sys.exit(1)
topdir = sys.argv[1]
topdir = os.path.abspath(topdir)
def handlelink(filep, subdir):
link = os.readlink(filep)
if link[0] != "/":
return
if link.startswith(topdir):
return
#print("Replacing %s with %s for %s" % (link, topdir+link, filep))
print("Replacing %s with %s for %s" % (link, os.path.relpath(topdir+link, subdir), filep))
os.unlink(filep)
os.symlink(os.path.relpath(topdir+link, subdir), filep)
for subdir, dirs, files in os.walk(topdir):
for f in files:
filep = os.path.join(subdir, f)
if os.path.islink(filep):
#print("Considering %s" % filep)
handlelink(filep, subdir)

9
tools/sysroot.sh

@ -0,0 +1,9 @@
#!/bin/bash
USER=root
HOST=192.168.1.100
rsync -avz --rsync-path="sudo rsync" --delete $USER@$HOST:/lib sysroot
rsync -avz --rsync-path="sudo rsync" --delete $USER@$HOST:/usr/include sysroot/usr
rsync -avz --rsync-path="sudo rsync" --delete $USER@$HOST:/usr/lib sysroot/usr
rsync -avz --rsync-path="sudo rsync" --delete $USER@$HOST:/opt/vc sysroot/opt
Loading…
Cancel
Save