parent
b3768ea470
commit
e79536abc0
@ -0,0 +1,35 @@
|
||||
# Copyright 1999-2012 Gentoo Foundation
|
||||
# Distributed under the terms of the GNU General Public License v2
|
||||
# $Header: $
|
||||
|
||||
EAPI="3"
|
||||
|
||||
SUPPORT_PYTHON_ABIS="1"
|
||||
PYTHON_DEPEND="2:2.7"
|
||||
RESTRICT_PYTHON_ABIS="2.4 2.5 2.6 3.*"
|
||||
|
||||
inherit distutils eutils
|
||||
|
||||
SRC_URI="ftp://ftp.calculate.ru/pub/calculate/calculate3/${PN}/${P}.tar.bz2"
|
||||
|
||||
DESCRIPTION="The program of the desktop configuration Calculate Linux"
|
||||
HOMEPAGE="http://www.calculate-linux.org/main/en/calculate2"
|
||||
LICENSE="Apache-2.0"
|
||||
SLOT="3"
|
||||
KEYWORDS="amd64 x86"
|
||||
IUSE=""
|
||||
|
||||
DEPEND="~sys-apps/calculate-core-3.1.3_beta1
|
||||
>=dev-python/python-ldap-2.0[ssl]
|
||||
media-gfx/feh
|
||||
x11-apps/xmessage
|
||||
!<sys-apps/calculate-desktop-3.1.0_alpha1"
|
||||
|
||||
RDEPEND="${DEPEND}"
|
||||
src_unpack() {
|
||||
unpack "${A}"
|
||||
cd "${S}"
|
||||
|
||||
# apply revision changes
|
||||
epatch "${FILESDIR}/calculate-desktop-3.1.3_beta1-r1.patch"
|
||||
}
|
@ -0,0 +1,115 @@
|
||||
commit f748341b0aab706baf73e9d6ee119e79c119bc86
|
||||
Author: Хирецкий Михаил <mh@calculate.ru>
|
||||
Date: Mon Feb 11 16:42:46 2013 +0400
|
||||
|
||||
Fix background for gdm
|
||||
|
||||
diff --git data/setbg data/setbg
|
||||
new file mode 100755
|
||||
index 0000000..86b411a
|
||||
--- /dev/null
|
||||
+++ data/setbg
|
||||
@@ -0,0 +1,63 @@
|
||||
+#!/usr/bin/env python
|
||||
+
|
||||
+# Copyright 2008-2012 Calculate Ltd. http://www.calculate-linux.org
|
||||
+#
|
||||
+# Licensed under the Apache License, Version 2.0 (the "License");
|
||||
+# you may not use this file except in compliance with the License.
|
||||
+# You may obtain a copy of the License at
|
||||
+#
|
||||
+# http://www.apache.org/licenses/LICENSE-2.0
|
||||
+#
|
||||
+# Unless required by applicable law or agreed to in writing, software
|
||||
+# distributed under the License is distributed on an "AS IS" BASIS,
|
||||
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
+# See the License for the specific language governing permissions and
|
||||
+# limitations under the License.
|
||||
+
|
||||
+from PySide import QtCore, QtGui
|
||||
+import os,sys
|
||||
+
|
||||
+class ImageViewer(QtGui.QMainWindow):
|
||||
+ def __init__(self):
|
||||
+ super(ImageViewer, self).__init__()
|
||||
+
|
||||
+ self.setWindowFlags(QtCore.Qt.X11BypassWindowManagerHint)
|
||||
+ self.imageLabel = QtGui.QLabel()
|
||||
+ self.imageLabel.setScaledContents(True)
|
||||
+ self.setCentralWidget(self.imageLabel)
|
||||
+
|
||||
+ screen = QtGui.QDesktopWidget().screenGeometry()
|
||||
+ self.setGeometry(screen)
|
||||
+ self.open('/usr/share/wallpapers/dm-background.png') or \
|
||||
+ self.open('/usr/share/apps/ksplash/Themes/CalculateSplashEn/'
|
||||
+ '400x300/background.png') or \
|
||||
+ self.setBackground()
|
||||
+
|
||||
+ def selectColor(self):
|
||||
+ try:
|
||||
+ if filter(re.compile(r"(cld|cldx|cldg|cmc|cls)-themes-12").search,
|
||||
+ os.listdir('/var/db/pkg/media-gfx')):
|
||||
+ return "#73a363"
|
||||
+ except:
|
||||
+ pass
|
||||
+ return '#30648b'
|
||||
+
|
||||
+ def setBackground(self):
|
||||
+ self.setStyleSheet("background-color: %s"%self.selectColor())
|
||||
+
|
||||
+ def open(self,fileName):
|
||||
+ image = QtGui.QImage(fileName)
|
||||
+ if image.isNull():
|
||||
+ return False
|
||||
+
|
||||
+ self.imageLabel.setPixmap(QtGui.QPixmap.fromImage(image))
|
||||
+
|
||||
+ self.imageLabel.adjustSize()
|
||||
+ return True
|
||||
+
|
||||
+if __name__ == '__main__':
|
||||
+ import sys
|
||||
+ app = QtGui.QApplication(sys.argv)
|
||||
+ imageViewer = ImageViewer()
|
||||
+ imageViewer.show()
|
||||
+ sys.exit(app.exec_())
|
||||
diff --git data/xdm data/xdm
|
||||
index 3f764c2..cfe5033 100755
|
||||
--- data/xdm
|
||||
+++ data/xdm
|
||||
@@ -83,6 +83,13 @@ umount_user_res(){
|
||||
fi
|
||||
}
|
||||
|
||||
+gtk_background(){
|
||||
+ if [[ -n $(env | grep RUNNING_UNDER_GDM=true) ]] && ls /var/db/pkg/gnome-base/gdm-2* &>/dev/null;
|
||||
+ then
|
||||
+ /usr/bin/env HOME=/root python2 /usr/share/calculate/xdm/setbg &
|
||||
+ BG_PID=$(ps ax | sed -nr "s/^\s*([0-9]+)\s.*setbg$/\1/p")
|
||||
+ fi
|
||||
+}
|
||||
|
||||
OPTS=$(getopt -o $SHORTOPTS --long $LONGOPTS -n "$progname" -- "$@")
|
||||
|
||||
@@ -138,6 +145,7 @@ fi
|
||||
FILELIST=$(find ${EXECDIR} -type f | sort)
|
||||
[[ $FILELIST ]] || warning "${EXECDIR} hasn't scripts"
|
||||
|
||||
+gtk_background
|
||||
DOMAIN_USER="`desktop_variable_value desktop.ur_domain_set`"
|
||||
for script in $FILELIST
|
||||
do
|
||||
diff --git setup.py setup.py
|
||||
index 3179831..1247341 100755
|
||||
--- setup.py
|
||||
+++ setup.py
|
||||
@@ -34,7 +34,8 @@ data_files = []
|
||||
|
||||
data_files += [('/usr/share/calculate/xdm', ['data/cmd_login',
|
||||
'data/functions',
|
||||
- 'data/xdm'])] + \
|
||||
+ 'data/xdm',
|
||||
+ 'data/setbg'])] + \
|
||||
[('/usr/share/calculate/xdm/login.d',
|
||||
['data/login.d/00init',
|
||||
'data/login.d/20desktop',
|
@ -0,0 +1,45 @@
|
||||
# Copyright 1999-2012 Gentoo Foundation
|
||||
# Distributed under the terms of the GNU General Public License v2
|
||||
# $Header: $
|
||||
|
||||
EAPI="3"
|
||||
SUPPORT_PYTHON_ABIS="1"
|
||||
PYTHON_DEPEND="2:2.7"
|
||||
RESTRICT_PYTHON_ABIS="2.4 2.5 2.6 3.*"
|
||||
|
||||
inherit distutils eutils
|
||||
|
||||
SRC_URI="ftp://ftp.calculate.ru/pub/calculate/calculate3/${PN}/${P}.tar.bz2"
|
||||
|
||||
DESCRIPTION="The program of installation Calculate Linux"
|
||||
HOMEPAGE="http://www.calculate-linux.org/main/en/calculate2"
|
||||
LICENSE="Apache-2.0"
|
||||
SLOT="3"
|
||||
KEYWORDS="amd64 x86"
|
||||
IUSE="pxe minimal"
|
||||
|
||||
DEPEND="~sys-apps/calculate-core-3.1.3_beta1
|
||||
!<sys-apps/calculate-install-2.2.29
|
||||
app-portage/layman
|
||||
>=sys-fs/udev-197
|
||||
!app-misc/livecd-tools
|
||||
sys-apps/iproute2[-minimal]
|
||||
!minimal? ( sys-boot/grub
|
||||
sys-apps/gptfdisk
|
||||
>=sys-apps/util-linux-2.19.1
|
||||
sys-fs/dosfstools
|
||||
sys-fs/squashfs-tools
|
||||
sys-block/parted )
|
||||
pxe? ( sys-apps/calculate-server
|
||||
net-ftp/tftp-hpa
|
||||
net-misc/dhcp
|
||||
net-fs/nfs-utils )"
|
||||
|
||||
RDEPEND="${DEPEND}"
|
||||
src_unpack() {
|
||||
unpack "${A}"
|
||||
cd "${S}"
|
||||
|
||||
# apply revision changes
|
||||
epatch "${FILESDIR}/calculate-install-3.1.3_beta1-r2.patch"
|
||||
}
|
@ -0,0 +1,50 @@
|
||||
diff --git install/cl_distr.py install/cl_distr.py
|
||||
index 2dd8c6c..92ce419 100644
|
||||
--- install/cl_distr.py
|
||||
+++ install/cl_distr.py
|
||||
@@ -454,6 +454,8 @@ class Distributive(object):
|
||||
extname = mapExtName.get(distr.__class__,"")
|
||||
image = distr.convertToDirectory()
|
||||
except Exception,e:
|
||||
+ if distr:
|
||||
+ distr.close()
|
||||
return {}.copy()
|
||||
d = self.getInfoFromDirectory(image.directory)
|
||||
d['ext'] = extname
|
||||
diff --git install/variables/X11.py install/variables/X11.py
|
||||
index 6dfc97e..ebd8f6e 100644
|
||||
--- install/variables/X11.py
|
||||
+++ install/variables/X11.py
|
||||
@@ -255,10 +255,13 @@ class VariableOsInstallX11ServerSet(ReadonlyVariable):
|
||||
type = "bool"
|
||||
|
||||
def get(self):
|
||||
- image = self.Get('cl_image')
|
||||
- if image:
|
||||
- with image as distr:
|
||||
- distrPath = image.getDirectory()
|
||||
- if isPkgInstalled('xorg-server',prefix=distrPath):
|
||||
- return "yes"
|
||||
+ try:
|
||||
+ image = self.Get('cl_image')
|
||||
+ if image:
|
||||
+ with image as distr:
|
||||
+ distrPath = image.getDirectory()
|
||||
+ if isPkgInstalled('xorg-server',prefix=distrPath):
|
||||
+ return "yes"
|
||||
+ except:
|
||||
+ pass
|
||||
return "no"
|
||||
diff --git install/variables/net.py install/variables/net.py
|
||||
index 438745d..c8801c4 100644
|
||||
--- install/variables/net.py
|
||||
+++ install/variables/net.py
|
||||
@@ -263,7 +263,7 @@ class VariableOsInstallNetStatus(NetHelper,Variable):
|
||||
if getOperState(iface) == 'down':
|
||||
return "off"
|
||||
else:
|
||||
- "dhcp"
|
||||
+ return "dhcp"
|
||||
rootDevNfs = self.Get('os_root_dev') == '/dev/nfs'
|
||||
return statusValue(getIp(iface),"on" \
|
||||
if rootDevNfs or isDhcpIp(iface) else "off")
|
@ -0,0 +1,26 @@
|
||||
# Copyright 1999-2011 Gentoo Foundation
|
||||
# Distributed under the terms of the GNU General Public License v2
|
||||
# $Header: $
|
||||
|
||||
EAPI=4
|
||||
|
||||
DESCRIPTION="Calculate Utilities meta package"
|
||||
HOMEPAGE="http://www.calculate-linux.org/main/en/calculate2"
|
||||
SRC_URI=""
|
||||
|
||||
LICENSE="Apache-2.0"
|
||||
SLOT="3"
|
||||
KEYWORDS="amd64 x86"
|
||||
IUSE="cl_consolegui cl_client cl_desktop cl_console"
|
||||
|
||||
RDEPEND="${RDEPEND}
|
||||
=sys-apps/calculate-install-3.1.3_beta1-r2
|
||||
=sys-apps/calculate-i18n-3.1.3_beta1
|
||||
=sys-apps/calculate-lib-3.1.3_beta1-r1
|
||||
=sys-apps/calculate-core-3.1.3_beta1-r1
|
||||
=sys-apps/calculate-update-3.1.3_beta1
|
||||
cl_client? ( =sys-apps/calculate-client-3.1.3_beta1 )
|
||||
cl_desktop? ( =sys-apps/calculate-desktop-3.1.3_beta1-r1 )
|
||||
cl_consolegui? ( =sys-apps/calculate-console-gui-3.1.3_beta1 )
|
||||
cl_console? ( =sys-apps/calculate-console-3.1.3_beta1 )
|
||||
"
|
Loading…
Reference in new issue