mirror of
https://abf.rosa.ru/djam/italc3.git
synced 2025-02-23 16:23:01 +00:00
Imported from SRPM
This commit is contained in:
commit
b02f9f9411
6 changed files with 689 additions and 0 deletions
2
.abf.yml
Normal file
2
.abf.yml
Normal file
|
@ -0,0 +1,2 @@
|
|||
sources:
|
||||
italc-3.0.0.tar.gz: 936fd8bdaf30c34b6ed5e63ab11aa8775de39b27
|
9
ica-autostart.desktop
Normal file
9
ica-autostart.desktop
Normal file
|
@ -0,0 +1,9 @@
|
|||
[Desktop Entry]
|
||||
Type=Application
|
||||
Exec=ica-start
|
||||
Terminal=false
|
||||
Name=ICA iTALC application
|
||||
|
||||
X-KDE-StartupNotify=false
|
||||
X-KDE-autostart-after=panel
|
||||
X-GNOME-Autostart-enabled=true
|
274
italc-launcher
Normal file
274
italc-launcher
Normal file
|
@ -0,0 +1,274 @@
|
|||
#!/usr/bin/python
|
||||
# -*- coding: utf-8 -*-
|
||||
# coding=UTF-8
|
||||
|
||||
# iTalc master launcher using avahi
|
||||
# Written by Stéphane Graber <stgraber@ubuntu.com>
|
||||
|
||||
from xml.dom import minidom
|
||||
import subprocess, re, socket, os, sys
|
||||
# The md5 module is deprecated in Python 2.5
|
||||
try:
|
||||
from hashlib import md5
|
||||
except ImportError:
|
||||
from md5 import md5
|
||||
|
||||
def getValueFromConfigFile(filename,key,default):
|
||||
file=open(filename)
|
||||
for line in file:
|
||||
if line.startswith(key):
|
||||
try:
|
||||
param=line.split("=")[1]
|
||||
param=param.strip()
|
||||
if not param.isdigit():
|
||||
param=param.strip('"')
|
||||
except:
|
||||
param=default
|
||||
file.close()
|
||||
return param
|
||||
|
||||
def getLocalIPs():
|
||||
"Scan ifconfig output for local IPV4 addresses"
|
||||
# Saving current LANG
|
||||
SYSTEM_LANG=os.environ["LANG"]
|
||||
# Apparently ifconfig has localizations according to the following line,
|
||||
# but with LANG=es_ES.UTF-8 the output looks the same as LANG=C
|
||||
os.environ["LANG"]="C" # Set environ LANG to C
|
||||
ip=[]
|
||||
output=subprocess.Popen("/sbin/ifconfig",stdout=subprocess.PIPE)
|
||||
output.wait()
|
||||
for line in output.stdout.readlines():
|
||||
line=line.strip()
|
||||
if line.startswith("inet addr"):
|
||||
ip.append(line.split(" ")[1].split(":")[1])
|
||||
# Restoring LANG
|
||||
os.environ["LANG"]=SYSTEM_LANG
|
||||
return ip
|
||||
|
||||
def getHostPort():
|
||||
isdhost="127.0.0.1"
|
||||
isdport=getValueFromConfigFile(configfile,"ICA_ISDPORT","5800")
|
||||
if "LTSP_CLIENT" in os.environ:
|
||||
xprop=subprocess.Popen(["/usr/bin/xprop","-root","ica_ltsp"],stdout=subprocess.PIPE)
|
||||
xprop.wait()
|
||||
if xprop.stdout.read().split(" ")[2].strip() == "1":
|
||||
isdhost=os.environ["LTSP_CLIENT"]
|
||||
else:
|
||||
isdport=str(int(os.environ["LTSP_CLIENT"].split(".")[3])+11000)
|
||||
return [isdhost,isdport]
|
||||
|
||||
def getSettings():
|
||||
"Find settings file and read paths"
|
||||
global section_keypathsprivate
|
||||
global section_keypathspublic
|
||||
global section_paths
|
||||
global path_adminprivatekey
|
||||
global path_adminpublickey
|
||||
global path_globalconfig
|
||||
global path_supporterprivatekey
|
||||
global path_supporterpublickey
|
||||
global path_teacherprivatekey
|
||||
global path_teacherpublickey
|
||||
global settingsfile
|
||||
file=open(settingsfile)
|
||||
mode=""
|
||||
for line in file:
|
||||
line = line.strip()
|
||||
if line == section_keypathsprivate:
|
||||
mode=section_keypathsprivate
|
||||
elif line == section_keypathspublic:
|
||||
mode=section_keypathspublic
|
||||
elif line == section_paths:
|
||||
mode=section_paths
|
||||
else:
|
||||
if mode==section_keypathsprivate:
|
||||
if line.startswith("admin"):
|
||||
try:
|
||||
path_adminprivatekey=line.split("=")[1]
|
||||
path_adminprivatekey=path_adminprivatekey.strip()
|
||||
except:
|
||||
path_adminprivatekey="/etc/italc/keys/private/admin/key"
|
||||
elif line.startswith("teacher"):
|
||||
try:
|
||||
path_teacherprivatekey=line.split("=")[1]
|
||||
path_teacherprivatekey=path_teacherprivatekey.strip()
|
||||
except:
|
||||
path_teacherprivatekey="/etc/italc/keys/private/teacher/key"
|
||||
elif line.startswith("supporter"):
|
||||
try:
|
||||
path_supporterprivatekey=line.split("=")[1]
|
||||
path_supporterprivatekey=path_supporterprivatekey.strip()
|
||||
except:
|
||||
path_supporterprivatekey="/etc/italc/keys/private/supporter/key"
|
||||
elif mode==section_keypathspublic:
|
||||
if line.startswith("admin"):
|
||||
try:
|
||||
path_adminpublickey=line.split("=")[1]
|
||||
path_adminpublickey=path_adminpublickey.strip()
|
||||
except:
|
||||
path_adminpublickey="/etc/italc/keys/public/admin/key"
|
||||
elif line.startswith("teacher"):
|
||||
try:
|
||||
path_teacherpublickey=line.split("=")[1]
|
||||
path_teacherpublickey=path_teacherpublickey.strip()
|
||||
except:
|
||||
path_teacherpublickey="/etc/italc/keys/public/teacher/key"
|
||||
elif line.startswith("supporter"):
|
||||
try:
|
||||
path_supporterpublickey=line.split("=")[1]
|
||||
path_supporterpublickey=path_supporterpublickey.strip()
|
||||
except:
|
||||
path_supporterpublickey="/etc/italc/keys/public/supporter/key"
|
||||
elif mode==section_paths:
|
||||
if line.startswith("globalconfig"):
|
||||
try:
|
||||
path_globalconfig=line.split("=")[1]
|
||||
path_globalconfig=path_globalconfig.strip()
|
||||
except:
|
||||
path_globalconfig="/etc/italc/globalconfig.xml"
|
||||
file.close()
|
||||
return
|
||||
|
||||
# openSUSE uses /etc/sysconfig/ica to define the ports
|
||||
configfile="/etc/sysconfig/ica"
|
||||
# Empty config file to use if it doesn't already exist
|
||||
skeleton="""<?xml version="1.0"?>
|
||||
<!DOCTYPE italc-config-file>
|
||||
<globalclientconfig version="1.0.7" >
|
||||
<body>
|
||||
</body>
|
||||
</globalclientconfig>"""
|
||||
|
||||
settingsfile="/etc/settings/iTALC Solutions/iTALC.conf"
|
||||
section_keypathsprivate="[keypathsprivate]"
|
||||
section_keypathspublic="[keypathspublic]"
|
||||
section_paths="[paths]"
|
||||
path_teacherpublickey="/etc/italc/keys/public/teacher/key"
|
||||
path_adminpublickey="/etc/italc/keys/public/admin/key"
|
||||
path_supporterpublickey="/etc/italc/keys/public/supporter/key"
|
||||
path_teacherprivatekey="/etc/italc/keys/private/teacher/key"
|
||||
path_adminprivatekey="/etc/italc/keys/private/admin/key"
|
||||
path_supporterprivatekey="/etc/italc/keys/private/supporter/key"
|
||||
path_globalconfig="/etc/italc/globalconfig.xml"
|
||||
|
||||
try:
|
||||
getSettings()
|
||||
except:
|
||||
print "Settings not found in "+settingsfile+", using defaults."
|
||||
|
||||
try:
|
||||
confdir=os.environ.get("HOME")+"/.italc/"
|
||||
except:
|
||||
sys.exit('Invalid or undefined env variable \"HOME\"')
|
||||
|
||||
try:
|
||||
file=open(path_teacherpublickey,"r")
|
||||
md5_1=md5(file.read()).hexdigest()
|
||||
file.close()
|
||||
|
||||
file=open(path_adminpublickey,"r")
|
||||
md5_2=md5(file.read()).hexdigest()
|
||||
file.close()
|
||||
|
||||
file=open(path_supporterpublickey,"r")
|
||||
md5_3=md5(file.read()).hexdigest()
|
||||
file.close()
|
||||
except:
|
||||
sys.exit('iTalc keys not correctly installed ('+path_teacherpublickey+')('+path_adminpublickey+')('+path_supporterpublickey)
|
||||
|
||||
if not os.access(path_teacherprivatekey,os.R_OK):
|
||||
md5_1="0"
|
||||
if not os.access(path_adminprivatekey,os.R_OK):
|
||||
md5_2="0"
|
||||
if not os.access(path_supporterprivatekey,os.R_OK):
|
||||
md5_3="0"
|
||||
access="none"
|
||||
else:
|
||||
access="supporter"
|
||||
else:
|
||||
access="admin"
|
||||
else:
|
||||
access="teacher"
|
||||
|
||||
try:
|
||||
xmldoc=minidom.parse(confdir+"globalconfig.xml")
|
||||
body=xmldoc.getElementsByTagName("globalclientconfig")[0].getElementsByTagName("body")[0]
|
||||
classrooms=body.getElementsByTagName("classroom")
|
||||
except:
|
||||
mkdir=subprocess.Popen(["/bin/mkdir","-p",confdir])
|
||||
mkdir.wait()
|
||||
try:
|
||||
config=open(confdir+"globalconfig.xml","w+")
|
||||
try:
|
||||
file=open(path_globalconfig)
|
||||
for line in file:
|
||||
config.write(line)
|
||||
except:
|
||||
print("Globalconfig in "+path_globalconfig+" not found, using skeleton.")
|
||||
config.write(skeleton)
|
||||
config.close()
|
||||
except:
|
||||
sys.exit('Unable to write to config file')
|
||||
xmldoc=minidom.parse(confdir+"globalconfig.xml")
|
||||
body=xmldoc.getElementsByTagName("globalclientconfig")[0].getElementsByTagName("body")[0]
|
||||
classrooms=body.getElementsByTagName("classroom")
|
||||
|
||||
# Scan for an existing classroom and delete it
|
||||
for classroom in classrooms:
|
||||
if classroom.getAttribute("name") == "Auto-detected computers":
|
||||
body.removeChild(classroom)
|
||||
|
||||
# Create the Auto-detected computers classroom
|
||||
avahi=xmldoc.createElement("classroom")
|
||||
avahi.setAttribute("name","Auto-detected computers")
|
||||
avahi.setAttribute("forcevisible","yes")
|
||||
body.appendChild(avahi)
|
||||
|
||||
# Add computers to the classroom
|
||||
client_list=subprocess.Popen(["/usr/bin/avahi-browse","-trp","_italc._tcp"],stdout=subprocess.PIPE)
|
||||
client_list.wait()
|
||||
count=0
|
||||
|
||||
local_addr=getLocalIPs()
|
||||
isdhost,isdport=getHostPort()
|
||||
if isdhost not in local_addr:
|
||||
local_addr=[isdhost]
|
||||
|
||||
for line in client_list.stdout.readlines():
|
||||
if line.startswith("="):
|
||||
try:
|
||||
param=line.split(";")
|
||||
comment=re.findall('"(.*)" "(.*)" "(.*)" "(.*)"\n',param[9])[0]
|
||||
if (comment[1] == md5_1 or comment[2] == md5_2 or comment[3] == md5_3) and (param[7] not in local_addr or str(int(isdport)+100) != param[8]):
|
||||
# Make sure we have a running VNC server
|
||||
connection=socket.socket(socket.AF_INET,socket.SOCK_STREAM)
|
||||
connection.connect((param[7],int(param[8])))
|
||||
connection.close()
|
||||
|
||||
# Get MAC address
|
||||
mac=subprocess.Popen(("/sbin/arp", param[7], "-n", "-a"),stdout=subprocess.PIPE)
|
||||
mac.wait()
|
||||
mac=mac.stdout.read().strip().split(" ")[3]
|
||||
if not re.match("^..:..:..:..:..:..$",mac):
|
||||
mac=""
|
||||
|
||||
# Generate the new node
|
||||
client=xmldoc.createElement("client")
|
||||
client.setAttribute("id",str(count))
|
||||
client.setAttribute("localip",param[7]+":"+param[8])
|
||||
client.setAttribute("mac",mac)
|
||||
client.setAttribute("name",comment[0])
|
||||
client.setAttribute("type","0")
|
||||
avahi.appendChild(client)
|
||||
count+=1
|
||||
except:
|
||||
print 'Ignoring a client, invalid data received'
|
||||
|
||||
try:
|
||||
file=open(confdir+"globalconfig.xml","w")
|
||||
xmldoc.writexml(file)
|
||||
file.close()
|
||||
except:
|
||||
exit('Failed to save updated config')
|
||||
#print "Starting italc as "+access+" ("+isdhost+":"+isdport+")"
|
||||
subprocess.Popen(["/usr/bin/italc","-isdport",isdport,"-isdhost",isdhost,"-role",access])
|
145
italc-start_ica
Normal file
145
italc-start_ica
Normal file
|
@ -0,0 +1,145 @@
|
|||
#!/bin/sh
|
||||
#
|
||||
# a perl script was written by Patrick Winnertz 11.12.05
|
||||
# and modified by Giovanni Gimelli - Osservatorio Tecnologico Italy
|
||||
# it has been re-written by Valerio Pachera (www.linuxludus.it) as
|
||||
# simple bash script
|
||||
# licensed under GPL2+
|
||||
# version 2.0 (21/12/2007)
|
||||
|
||||
# SCOPE
|
||||
# The script scope is to start a ica session on different port for
|
||||
# each thin client and on default ports for diskless workstation
|
||||
# and the server.
|
||||
# The port number used for the thinclient will be the last part of the
|
||||
# thinclient IP
|
||||
|
||||
# The initial script was modified by Lars Vogdt for openSUSE-Education
|
||||
# at Fr 6. Jun 2008.
|
||||
|
||||
ICA_LTSP=$(xprop -root ica_ltsp | sed 's/^.* //' 2> /dev/null)
|
||||
if [ "$ICA_LTSP" = "1" ]
|
||||
then
|
||||
echo "ICA already running on the thin client."
|
||||
exit 0
|
||||
fi
|
||||
|
||||
PATH=/usr/bin:/bin
|
||||
ICA_CONFIG="/etc/sysconfig/ica"
|
||||
ITALC_CONFIG="/etc/settings/iTALC Solutions/iTALC.conf"
|
||||
ICA_BIN="/usr/bin/ica"
|
||||
|
||||
# Check for existence of needed config file and read it
|
||||
if [ ! -r $ICA_CONFIG ]; then
|
||||
echo "$ICA_CONFIG does not exist" >&2
|
||||
exit 6
|
||||
fi
|
||||
|
||||
# set default values
|
||||
ICA_IVSPORT="5900"
|
||||
ICA_ISDPORT="5800"
|
||||
ICA_USESHM="no"
|
||||
ICA_USEONETYLE="no"
|
||||
|
||||
# Read config
|
||||
. $ICA_CONFIG
|
||||
|
||||
ICA_OPTIONS=""
|
||||
|
||||
if [ "$ICA_USESHM" != "yes" ]; then
|
||||
ICA_OPTIONS="$ICA_OPTIONS -noshm"
|
||||
fi
|
||||
if [ "$ICA_USEONETYLE" != "yes" ]; then
|
||||
ICA_OPTIONS="$ICA_OPTIONS -onetile"
|
||||
fi
|
||||
if [ -n "$ICA_PARAMS" ]; then
|
||||
ICA_OPTIONS="$ICA_OPTIONS $ICA_PARAMS"
|
||||
fi
|
||||
if [ -n "$DISPLAY" ]; then
|
||||
DISPLAYOPT="-display $DISPLAY"
|
||||
fi
|
||||
|
||||
function parse_ini () {
|
||||
IFS=$'\n' && ini=( $(<"$1") ) # convert to line-array
|
||||
ini=( ${ini[*]//;*/} ) # remove comments ‘;’
|
||||
ini=( ${ini[*]//\#*/} ) # remove comments ‘#’
|
||||
ini=( ${ini[*]/\ =\ /=} ) # remove anything with a space around ‘ = ‘
|
||||
ini=( ${ini[*]/#[/\}$'\n'cfg_section_} ) # set section prefix
|
||||
ini=( ${ini[*]/%]/ \(} ) # convert text2function (1)
|
||||
ini=( ${ini[*]/=/=\( } ) # convert item to array
|
||||
ini=( ${ini[*]/%/ \)} ) # close array parenthesis
|
||||
ini=( ${ini[*]/%\( \)/\(\) \{} ) # convert text2function (2)
|
||||
ini=( ${ini[*]/%\} \)/\}} ) # remove extra parenthesis
|
||||
ini=( ${ini[*]/#\ */} ) # remove blank lines
|
||||
ini=( ${ini[*]/#\ */} ) # remove blank lines with tabs
|
||||
ini[0]='' # remove first element
|
||||
ini[${#ini[*]} + 1]='}' # add the last brace
|
||||
# printf "%s\n" ${ini[*]}
|
||||
eval "$(echo "${ini[*]}")" # eval the result
|
||||
}
|
||||
|
||||
function get_md5sums () {
|
||||
md5sum $1 | awk '" " { print $1}'
|
||||
}
|
||||
|
||||
function avahi_announce () {
|
||||
IVSPORT=$1
|
||||
MD5SUMS=""
|
||||
HOST_NAME=$2
|
||||
parse_ini "$ITALC_CONFIG"
|
||||
cfg_section_keypathspublic
|
||||
MD5SUM_1="$(get_md5sums "$admin")"
|
||||
MD5SUM_2="$(get_md5sums "$supporter")"
|
||||
MD5SUM_3="$(get_md5sums "$teacher")"
|
||||
avahi-publish-service "italc $HOST_NAME" _italc._tcp $IVSPORT $MD5SUM_1 $MD5SUM_2 $MD5SUM_3 "$HOST_NAME" >/dev/null &
|
||||
}
|
||||
|
||||
function avahi_stop () {
|
||||
kill $(ps ux | grep avahi-publish-service | grep italc | grep $IVSPORT | grep $HOSTNAME | awk '" " { print $2 }')
|
||||
}
|
||||
|
||||
|
||||
if [ -x "$ICA_BIN" ]; then
|
||||
if [ -f /etc/ltsp_chroot ]; then
|
||||
IP=$(ip addr show | grep " inet " | grep -v 127.0.0 | head -n1 | awk '{print \$2}' | sed "s/\/.*//")
|
||||
HOST_NAME=$(hostname)
|
||||
fi
|
||||
# ends any previous ica session of the user that is running the script
|
||||
# FIXME: killall --user $(whoami) ica 2>/dev/null; <<- better?
|
||||
RUNNING_ICA=$(ps ux | awk '" " { print $2" "$11 }' | grep -E "^[0-9].*ica" | awk '" " { print $1 }')
|
||||
if [ -n "$RUNNING_ICA" ]; then
|
||||
for process in $RUNNING_ICA; do
|
||||
kill $process
|
||||
done
|
||||
sleep 1
|
||||
fi
|
||||
|
||||
if [ x"$ICA_ENABLE" = x"yes" ]; then
|
||||
# $LTSP_CLIENT is empty if the script is called on the server or a
|
||||
# Diskless Workstation.
|
||||
# That's true only if the script is executed after logged in the
|
||||
# desktop manager.
|
||||
if [ "$LTSP_CLIENT" ]; then
|
||||
PORT=$(echo $LTSP_CLIENT | awk -F . '{print $4}')
|
||||
ICA_IVSPORT=$((10000 + $PORT))
|
||||
ICA_ISDPORT=$((11000 + $PORT))
|
||||
|
||||
IP="$LTSP_CLIENT"
|
||||
HOST_NAME="$IP ($USER)"
|
||||
else
|
||||
HOST_NAME=$(hostname)
|
||||
fi
|
||||
#start ICA service
|
||||
$ICA_BIN $ICA_OPTIONS -ivsport $ICA_IVSPORT -isdport $ICA_ISDPORT $DISPLAYOPT &
|
||||
|
||||
if [ -x /usr/bin/avahi-publish-service ]; then
|
||||
if [ -f /var/run/avahi-daemon/pid ]; then
|
||||
avahi_stop
|
||||
avahi_announce $ICA_IVSPORT $HOST_NAME
|
||||
fi
|
||||
fi
|
||||
fi
|
||||
else
|
||||
echo "$ICA_BIN doesn't exist or is not executable" >&2
|
||||
exit 1
|
||||
fi
|
56
italc.sysconfig
Normal file
56
italc.sysconfig
Normal file
|
@ -0,0 +1,56 @@
|
|||
## Path: Applications/iTALC
|
||||
## Description: ICA remote monitoring startup parameters
|
||||
|
||||
## Type: yesno
|
||||
## Default: yes
|
||||
#
|
||||
# Enable or disable ICA, the iTALC application running on
|
||||
# a client to allow connections from iTALC
|
||||
#
|
||||
ICA_ENABLE="yes"
|
||||
|
||||
## Type: integer
|
||||
## Default: 5900
|
||||
#
|
||||
# Set port at which the iTALC-VNC-server should listen.
|
||||
# Please remember to adapt the firewall settings, too.
|
||||
# Default: 5900
|
||||
#
|
||||
ICA_IVSPORT="5900"
|
||||
|
||||
## Type: integer
|
||||
## Default: 0
|
||||
#
|
||||
# Set port at which ICA should listen.
|
||||
# Please remember to adapt the firewall settings, too.
|
||||
# Default: 5800
|
||||
#
|
||||
ICA_ISDPORT="5800"
|
||||
|
||||
## Type: yesno
|
||||
## Default: no
|
||||
#
|
||||
# Use the MIT-SHM extension for the polling.
|
||||
# Remote displays can be polled this way: be careful this
|
||||
# can use large amounts of network bandwidth.
|
||||
# This is of use if the local machine has a limited number of
|
||||
# shm segments and -onetile is not sufficient.
|
||||
#
|
||||
ICA_USESHM="no"
|
||||
|
||||
## Type: yesno
|
||||
## Default: no
|
||||
#
|
||||
# Use the new copy_tiles() framebuffer mechanism.
|
||||
# Disabling limits shm segments used to 3.
|
||||
#
|
||||
ICA_USEONETYLE="no"
|
||||
|
||||
## Type: string
|
||||
## Default: ""
|
||||
#
|
||||
# Additional parameters for ICA like "--quiet"
|
||||
# Please refer to the iTALC wiki for details
|
||||
#
|
||||
ICA_PARAMS=""
|
||||
|
203
italc3.spec
Normal file
203
italc3.spec
Normal file
|
@ -0,0 +1,203 @@
|
|||
%define debug_package %{nil}
|
||||
%define libname %mklibname italc
|
||||
%define italcgrp italc
|
||||
%define oname italc
|
||||
|
||||
Name: italc3
|
||||
Summary: Intelligent Teaching And Learning with Computers - software for teachers
|
||||
Version: 3.0.0
|
||||
Release: 1
|
||||
License: GPLv2+
|
||||
Group: Networking/Remote access
|
||||
Url: http://italc.sourceforge.net/
|
||||
Source0: %{oname}-%{version}.tar.gz
|
||||
Source2: italc-start_ica
|
||||
Source3: italc.sysconfig
|
||||
Source5: ica-autostart.desktop
|
||||
Source6: italc-launcher
|
||||
BuildRequires: cmake
|
||||
BuildRequires: qt5-linguist
|
||||
BuildRequires: pam-devel
|
||||
BuildRequires: pkgconfig(libopenjpeg1)
|
||||
BuildRequires: pkgconfig(Qt5Core)
|
||||
BuildRequires: pkgconfig(Qt5Gui)
|
||||
BuildRequires: pkgconfig(Qt5Widgets)
|
||||
BuildRequires: pkgconfig(Qt5Xml)
|
||||
BuildRequires: pkgconfig(Qt5Network)
|
||||
BuildRequires: pkgconfig(libopenjpeg1)
|
||||
BuildRequires: pkgconfig(openssl)
|
||||
BuildRequires: pkgconfig(xtst)
|
||||
BuildRequires: pkgconfig(zlib)
|
||||
|
||||
%description
|
||||
iTALC is a use- and powerful didactical tool for teachers. It lets you view
|
||||
and control other computers in your network in several ways. It supports Linux
|
||||
and Windows 2000/XP/Vista.
|
||||
|
||||
Features:
|
||||
|
||||
* see what's going on in computer-labs by using overview mode and
|
||||
make snapshots
|
||||
* remote-control computers to support and help other people
|
||||
* show a demo (either in fullscreen or in a window) - the teacher's screen
|
||||
is shown on all student's computers in realtime
|
||||
* lock workstations for moving undivided attention to teacher
|
||||
* send text-messages to students
|
||||
* powering on/off and rebooting computers per remote
|
||||
* remote logon and logoff and remote execution of arbitrary commands/scripts
|
||||
* home-schooling - iTALC's network-technology is not restricted to a subnet
|
||||
and therefore students at home can join lessons via VPN-connections just
|
||||
by installing iTALC client
|
||||
|
||||
Furthermore iTALC is optimized for usage on multi-core systems (by making
|
||||
heavy use of threads). No matter how many cores you have, iTALC can make use
|
||||
of all of them.
|
||||
|
||||
%package client
|
||||
Summary: Software for iTALC-clients
|
||||
Group: Networking/Remote access
|
||||
|
||||
%description client
|
||||
This package contains the software, needed by iTALC-clients.
|
||||
|
||||
See /usr/share/italc/doc/INSTALL for details on how to install and setup iTALC
|
||||
in your network.
|
||||
|
||||
%package master
|
||||
Summary: iTALC master software
|
||||
Group: Networking/Remote access
|
||||
Requires: %{libname} = %{EVRD}
|
||||
Requires: %{name}-client = %{EVRD}
|
||||
Requires(post): %{name}-client = %{EVRD}
|
||||
|
||||
%description master
|
||||
This package contains the actual master-software for accessing clients.
|
||||
|
||||
See /usr/share/italc/doc/INSTALL for details on how to install and setup iTALC
|
||||
in your network.
|
||||
|
||||
%package -n %{libname}
|
||||
Summary: Library used by ITALC
|
||||
Group: Networking/Remote access
|
||||
|
||||
%description -n %{libname}
|
||||
iTALC is a use- and powerful didactical tool for teachers. It lets you
|
||||
view and control other computers in your network in several ways. It
|
||||
supports Linux and Windows 2000/XP/Vista and it even can be used
|
||||
transparently in mixed environments!
|
||||
|
||||
This is a library used by %{name}-master and %{name}-client.
|
||||
|
||||
%pre client
|
||||
%{_sbindir}/groupadd -r -f %{italcgrp} 2>/dev/null ||:
|
||||
|
||||
%post client
|
||||
if
|
||||
getent group %{italcgrp} >/dev/null
|
||||
then
|
||||
: OK group %{italcgrp} already present
|
||||
else
|
||||
groupadd -r %{italcgrp} 2>/dev/null || :
|
||||
fi
|
||||
|
||||
|
||||
%post master
|
||||
if
|
||||
getent group %{italcgrp} >/dev/null
|
||||
then
|
||||
: OK group %{italcgrp} already present
|
||||
else
|
||||
groupadd -r %{italcgrp} 2>/dev/null || :
|
||||
fi
|
||||
|
||||
# dont run scripts on update
|
||||
if [ ${1:-0} -lt 2 ]; then
|
||||
for role in admin supporter teacher; do
|
||||
if [ ! -f "%{_sysconfdir}/italc/keys/private/$role/key" ]; then
|
||||
/usr/bin/ica -role $role -createkeypair 1>/dev/null
|
||||
chgrp %{italcgrp} "%{_sysconfdir}/italc/keys/private/$role/key"
|
||||
chmod 0440 "%{_sysconfdir}/italc/keys/private/$role/key"
|
||||
fi
|
||||
done
|
||||
fi
|
||||
|
||||
|
||||
%prep
|
||||
%setup -qn %{oname}-%{version}
|
||||
|
||||
%build
|
||||
%cmake_qt5 -DWANT_QT5=ON
|
||||
%make
|
||||
|
||||
%install
|
||||
mkdir -p %{buildroot}%{_defaultdocdir}/%{name}
|
||||
|
||||
%makeinstall_std -C build
|
||||
# create the directories containing the auth-keys
|
||||
mkdir -p %{buildroot}%{_sysconfdir}/italc/keys/{private,public}/{teacher,admin,supporter,other}
|
||||
# create pseudo key files so RPM can own them (ghost files)
|
||||
for role in admin supporter teacher; do
|
||||
touch %{buildroot}%{_sysconfdir}/italc/keys/{private,public}/$role/key
|
||||
done
|
||||
# create the initial config
|
||||
mkdir -p "%{buildroot}/%{_sysconfdir}/settings/iTALC Solutions"
|
||||
cat > "%{buildroot}/%{_sysconfdir}/settings/iTALC Solutions/iTALC.conf" << EOF
|
||||
[keypathsprivate]
|
||||
admin=%{_sysconfdir}/italc/keys/private/admin/key
|
||||
supporter=%{_sysconfdir}/italc/keys/private/supporter/key
|
||||
teacher=%{_sysconfdir}/italc/keys/private/teacher/key
|
||||
|
||||
[keypathspublic]
|
||||
admin=%{_sysconfdir}/italc/keys/public/admin/key
|
||||
supporter=%{_sysconfdir}/italc/keys/public/supporter/key
|
||||
teacher=%{_sysconfdir}/italc/keys/public/teacher/key
|
||||
EOF
|
||||
# install start script for ica client
|
||||
install -D -m755 %{SOURCE2} %{buildroot}/%{_bindir}/start-ica
|
||||
install -D -m644 %{SOURCE5} %{buildroot}/%{_sysconfdir}/xdg/autostart/ica-autostart.desktop
|
||||
install -D -m755 %{SOURCE6} %{buildroot}/%{_bindir}/italc-launcher
|
||||
# icon for the desktop file
|
||||
install -Dm644 ima/data/italc.png %{buildroot}/%{_datadir}/pixmaps/italc.png
|
||||
#
|
||||
# Distribution specific
|
||||
#
|
||||
# configuration for ica
|
||||
|
||||
install -D -m644 %{SOURCE3} %{buildroot}/%{_sysconfdir}/sysconfig/ica
|
||||
|
||||
%files client
|
||||
%{_bindir}/ica
|
||||
%{_bindir}/start-ica
|
||||
%{_bindir}/italc_auth_helper
|
||||
%config %{_sysconfdir}/xdg/autostart/ica-autostart.desktop
|
||||
%config(noreplace) %{_sysconfdir}/sysconfig/ica
|
||||
%dir %{_sysconfdir}/settings
|
||||
%dir "%{_sysconfdir}/settings/iTALC Solutions"
|
||||
%config(missingok,noreplace) "%{_sysconfdir}/settings/iTALC Solutions/iTALC.conf"
|
||||
%dir %{_sysconfdir}/italc/keys/private
|
||||
%defattr(0440,root,%{italcgrp},0750)
|
||||
%dir %{_sysconfdir}/italc/keys/private/teacher
|
||||
%dir %{_sysconfdir}/italc/keys/private/admin
|
||||
%dir %{_sysconfdir}/italc/keys/private/supporter
|
||||
%dir %{_sysconfdir}/italc/keys/private/other
|
||||
%ghost %attr(0440,root,%{italcgrp}) %config(noreplace) %{_sysconfdir}/italc/keys/private/teacher/key
|
||||
%ghost %attr(0440,root,%{italcgrp}) %config(noreplace) %{_sysconfdir}/italc/keys/private/admin/key
|
||||
%ghost %attr(0440,root,%{italcgrp}) %config(noreplace) %{_sysconfdir}/italc/keys/private/supporter/key
|
||||
%ghost %attr(0444,root,%{italcgrp}) %config(noreplace) %{_sysconfdir}/italc/keys/public/teacher/key
|
||||
%ghost %attr(0444,root,%{italcgrp}) %config(noreplace) %{_sysconfdir}/italc/keys/public/admin/key
|
||||
%ghost %attr(0444,root,%{italcgrp}) %config(noreplace) %{_sysconfdir}/italc/keys/public/supporter/key
|
||||
|
||||
|
||||
%files -n %{libname}
|
||||
%doc AUTHORS COPYING ChangeLog INSTALL README TODO
|
||||
%{_libdir}/*
|
||||
|
||||
|
||||
%files master
|
||||
%doc AUTHORS COPYING ChangeLog INSTALL README TODO
|
||||
%{_bindir}/italc
|
||||
%{_bindir}/italc-launcher
|
||||
%{_bindir}/imc
|
||||
%{_datadir}/pixmaps/*
|
||||
%{_datadir}/italc/JavaViewer/VncViewer.jar
|
||||
%{_datadir}/italc/JavaViewer/index.vnc
|
Loading…
Add table
Reference in a new issue