https://transfiles.ru/1by0sRusWolf:Рабочего VPN нет в системе?
[РЕШЕНО] tcl + tclx + linuxcnc-sim + bwidget
Засады на пути к успхеу нескончаемы. Теперь вот
Если поставить совсем настойчиво, как pacman -U -d --nodeps linuxcnc-sim-2.7.15-8-x86_64.pkg.tar, то при запуске падает со словами-
где действительно просят -
В моей системе такой пакет есть, а в Ауре уже отсутствует. Где найти?
pacman -U --nodeps linuxcnc-sim-2.7.15-8-x86_64.pkg.tar
загрузка пакетов...
разрешение зависимостей...
предупреждение: не удалось разрешить "python2-gtkglext", зависимость "linuxcnc-sim"
stepconf
Traceback (most recent call last):
File "/usr/bin/stepconf", line 27, in <module>
import gtk
ImportError: No module named gtk
import pygtk
pygtk.require("2.0")
import gtk
import gtk.glade
import sys
import os
Последний раз редактировалось lnx 06.08.2025 22:11, всего редактировалось 1 раз.
Продолжил битву, малодушно в душе и в дУше задумываясь на тему "а не залить ли к чертовой матери по rsync туда свой /var + /usr + /lib".
имея собранный linuxcnc 2.7. и установленные все зависимости при запуске получаю стартовое окно, создающее видимость работоспособности. Но при выборе любой конфигурации (стартовое окно предлагает именно это) из раздела sim, например axis or axis mm получаю падение с отчетом в файл (ничего не говорящим) и в консоли ImportError: No module named _tkinter-
Однако этот интер в системе есть, как на моей машине, так и на удаленой -
. Пересобрал tclx + bwidget, ничего не изменилось. По теме нагуглилось https://bbs.archlinux.org/viewtopic.php?id=252501, но к решению это не приблизило. На старом форуме тема была https://archlinux.org.ru/forum/post/262239, но вебархив тему не показывает.
export TCLLIBPATH=/usr/lib/tcltk/linuxcnc тоже дело не продвинуло.
Подскажете?
имея собранный linuxcnc 2.7. и установленные все зависимости при запуске получаю стартовое окно, создающее видимость работоспособности. Но при выборе любой конфигурации (стартовое окно предлагает именно это) из раздела sim, например axis or axis mm получаю падение с отчетом в файл (ничего не говорящим) и в консоли ImportError: No module named _tkinter-
HALCMD=halcmd
LINUXCNC_EMCSH=/usr/bin/wish8.6
INIFILE=/home/v/linuxcnc/configs/sim.axis/axis.ini
PARAMETER_FILE=sim.var
TASK=milltask
HALUI=halui
DISPLAY=axis
Starting LinuxCNC server program: linuxcncsvr
Loading Real Time OS, RTAPI, and HAL_LIB modules
Starting LinuxCNC IO program: io
Starting HAL User Interface program: halui
Starting TASK program: milltask
Starting DISPLAY program: axis
Removing HAL_LIB, RTAPI, and Real Time OS modules
Removing NML shared memory segments
linuxcnc
LINUXCNC - 2.7.15
Machine configuration directory is '/home/v/linuxcnc/configs/sim.axis'
Machine configuration file is 'axis.ini'
Starting LinuxCNC...
Found file(lib): /usr/share/linuxcnc/hallib/core_sim.hal
Note: Using POSIX non-realtime
Found file(lib): /usr/share/linuxcnc/hallib/sim_spindle_encoder.hal
Found file(lib): /usr/share/linuxcnc/hallib/axis_manualtoolchange.hal
Traceback (most recent call last):
File "/usr/bin/hal_manualtoolchange", line 60, in <module>
import Tkinter, nf, rs274.options
File "/usr/lib/python2.7/lib-tk/Tkinter.py", line 39, in <module>
import _tkinter # If this fails your Python may not be configured for Tk
ImportError: No module named _tkinter
Found file(lib): /usr/share/linuxcnc/hallib/simulated_home.hal
Found file(REL): ./check_constraints.hal
Traceback (most recent call last):
File "/usr/bin/axis", line 40, in <module>
import Tkinter
File "/usr/lib/python2.7/lib-tk/Tkinter.py", line 39, in <module>
import _tkinter # If this fails your Python may not be configured for Tk
ImportError: No module named _tkinter
Shutting down and cleaning up LinuxCNC...
Traceback (most recent call last):
File "/usr/bin/axis-remote", line 26, in <module>
import sys, getopt, Tkinter, os
File "/usr/lib/python2.7/lib-tk/Tkinter.py", line 39, in <module>
import _tkinter # If this fails your Python may not be configured for Tk
ImportError: No module named _tkinter
task: 121 cycles, min=0.000007, max=0.001148, avg=0.000936, 0 latency excursions (> 10x expected cycle time of 0.001000s)
Note: Using POSIX non-realtime
LinuxCNC terminated with an error. You can find more information in the log:
/home/v/linuxcnc_debug.txt
and
/home/v/linuxcnc_print.txt
as well as in the output of the shell command 'dmesg' and in the terminal
ls /usr/lib/python2.7/lib-tk/Tkinter.py
/usr/lib/python2.7/lib-tk/Tkinter.py
export TCLLIBPATH=/usr/lib/tcltk/linuxcnc тоже дело не продвинуло.
Подскажете?
на счет свежести не уверен, но можете попробоватьlnx: однако вопрос универсального скрипта, собирающего из рабочей системы установленный пакет, остается открытым.
https://archlinux.fr/repacman
https://aur.archlinux.org/packages/repacman
https://aur.archlinux.org/packages/repacman2
Ну почему я не догадался поискать по освершенно очевидным буковсочетаниям repacman ?! - все потому, что глаз ззамылен. Большое спасибо за наводку. И вот что интересно - я по очереди попробовал оба скрипта для пересборки linuxcnc-sim, результаты -Arhei:на счет свежести не уверен, но можете попробовать
оригинал пакета linuxcnc-sim-2.7.15-8-x86_64.pkg.tar весит 29.9мб
собранный repacman linuxcnc-sim-2.7.15-8.pkg.tar.gz весит 5.1мб
собранный силами repacman2 linuxcnc-sim-2.7.15-8-.pkg.tar.xz весит 3.4мб
Оба скрипта выдают в конце сообщение об ошибке вида -
a usr/share/man/man9/xhc_hb04_util.9.gz
a usr/share/man/man9/xor2.9.gz
a .INSTALL
a .PKGINFO
bsdtar: Error exit delayed from previous errors.
Ну если разницу между первым и вторым можно объяснить мерой компрессии, то с оригиналом?! Просмотрел архивы - состав файлов вцелом идентичен, разница в весе обусловлена числом файлов локалей, в рабочей системе лишние локали я удаляю, здесь оставлены только русская и английская.
И, к сожалению, это не решило проблему с с запуском на удаленной системе, с ImportError: No module named _tkinter. Предположу, что это как-то связано с недочтением переменных окружений, когда ввода export TCLLIBPATH=/usr/lib/tcltk/linuxcnc оказалось недостаточно.
Оба на! Это к разговору о пользе пакетов из работающей системы! Вот на "той" машине я из Ауры поставил python2 2.7.18-12, потому как в основных репозиториях python2 больше нет.
Вот так.
Вот ТАК! и это - ПОБЕДА!!! нашли причину и за задние лапки, да об косяк! Еще раз международное спасибо за помощь Arhei!!
find / -name _tkinter
/usr/lib/python2.7/lib-dynload/_tkinter.so
pacman -Qo /usr/lib/python2.7/lib-dynload/_tkinter.so
/usr/lib/python2.7/lib-dynload/_tkinter.so принадлежит python2 2.7.18-8
а на той машине в ответ на -
find / -name _tkinter.so
пустота!
Вот ТАК! и это - ПОБЕДА!!! нашли причину и за задние лапки, да об косяк! Еще раз международное спасибо за помощь Arhei!!
Следующий шаг - попытка собрать версию 2.8.4 dev с ядром реального времени под Arch linux для развертывания именно уже на боевой машине, непосредственно управляющей станком (вместо deb).
По инструкции https://www.linuxcnc.org/docs/devel/htm ... uxcnc.html делаю -
Тут явно проблема в том, что ищет Python3, когда нужен 2 - LinuxCNC версии 2.8 последний из работающих на питоне-2, 2.9 требует уже питона-3. Причина за борьбу именно за LCNC2.8 весомая, повторюсь - она уже умеет "много моторов на ось" и одновременно только для нее есть дополнительный вручную сделанный модуль ядра. Как заставить собираться с правильными питоном?
./configure --help ясности не внес -
В архиве такого пакета не нашлось https://archive.org/details/archlinuxar ... y=linuxcnc
По инструкции https://www.linuxcnc.org/docs/devel/htm ... uxcnc.html делаю -
git clone --branch=v2.8.4 https://github.com/LinuxCNC/linuxcnc.git linuxcnc-dev
cd куда надо
./autogen.sh
configure.ac:116: warning: The macro 'AC_CONFIG_HEADER' is obsolete.
configure.ac:116: You should run autoupdate.
./lib/autoconf/status.m4:719: AC_CONFIG_HEADER is expanded from...
configure.ac:116: the top level
configure.ac:464: warning: The macro 'AC_TRY_LINK' is obsolete.
configure.ac:464: You should run autoupdate.
./lib/autoconf/general.m4:2918: AC_TRY_LINK is expanded from...
configure.ac:464: the top level
configure.ac:484: warning: The macro 'AC_TRY_LINK' is obsolete.
configure.ac:484: You should run autoupdate.
./lib/autoconf/general.m4:2918: AC_TRY_LINK is expanded from...
configure.ac:484: the top level
configure.ac:1246: warning: The macro 'AC_HEADER_STDC' is obsolete.
configure.ac:1246: You should run autoupdate.
./lib/autoconf/headers.m4:663: AC_HEADER_STDC is expanded from...
configure.ac:1246: the top level
configure.ac:1251: warning: The macro 'AC_TRY_LINK' is obsolete.
configure.ac:1251: You should run autoupdate.
./lib/autoconf/general.m4:2918: AC_TRY_LINK is expanded from...
configure.ac:1251: the top level
configure.ac:1527: warning: The macro 'AC_TRY_COMPILE' is obsolete.
configure.ac:1527: You should run autoupdate.
./lib/autoconf/general.m4:2845: AC_TRY_COMPILE is expanded from...
configure.ac:1527: the top level
configure.ac:1705: warning: The macro 'AC_TRY_COMPILE' is obsolete.
configure.ac:1705: You should run autoupdate.
./lib/autoconf/general.m4:2845: AC_TRY_COMPILE is expanded from...
configure.ac:1705: the top level
./configure --enable-non-distributable=yes --disable-build-documentation-translation --disable-check-runtime-deps -without-libmodbus --prefix=/opt/LCNC
падает с ошибкой -
checking for xgettext... /usr/bin/xgettext
checking for msgfmt... /usr/bin/msgfmt
checking python version... OK
checking version of python libraries... python3.13
checking match between tk and Tkinter versions... 8.6
checking location of Python header files... /usr/include/python3.13
checking for Python headers... -I/usr/include/python3.13
checking for Python libraries... -ldl
checking whether the Boost::Python headers are available... yes
checking for boost::python shared library...
configure: error: boost::python is required to build LinuxCNC
./configure --help ясности не внес -
./configure --help
'configure' configures LinuxCNC 2.8.4 to adapt to many kinds of systems.
Usage: ./configure [OPTION]... [VAR=VALUE]...
To assign environment variables (e.g., CC, CFLAGS...), specify them as
VAR=VALUE. See below for descriptions of some of the useful variables.
Defaults for the options are specified in brackets.
Configuration:
-h, --help display this help and exit
--help=short display options specific to this package
--help=recursive display the short help of all the included packages
-V, --version display version information and exit
-q, --quiet, --silent do not print 'checking ...' messages
--cache-file=FILE cache test results in FILE [disabled]
-C, --config-cache alias for '--cache-file=config.cache'
-n, --no-create do not create output files
--srcdir=DIR find the sources in DIR [configure dir or '..']
Installation directories:
--prefix=PREFIX install architecture-independent files in PREFIX
[run-in-place]
--exec-prefix=EPREFIX install architecture-dependent files in EPREFIX
[PREFIX]
By default, 'make install' will install all the files in
'run-in-place/bin', 'run-in-place/lib' etc. You can specify
an installation prefix other than 'run-in-place' using '--prefix',
for instance '--prefix=$HOME'.
For better control, use the options below.
Fine tuning of the installation directories:
--bindir=DIR user executables [EPREFIX/bin]
--sbindir=DIR system admin executables [EPREFIX/sbin]
--libexecdir=DIR program executables [EPREFIX/libexec]
--sysconfdir=DIR read-only single-machine data [PREFIX/etc]
--sharedstatedir=DIR modifiable architecture-independent data [PREFIX/com]
--localstatedir=DIR modifiable single-machine data [PREFIX/var]
--runstatedir=DIR modifiable per-process data [LOCALSTATEDIR/run]
--libdir=DIR object code libraries [EPREFIX/lib]
--includedir=DIR C header files [PREFIX/include]
--oldincludedir=DIR C header files for non-gcc [/usr/include]
--datarootdir=DIR read-only arch.-independent data root [PREFIX/share]
--datadir=DIR read-only architecture-independent data [DATAROOTDIR]
--infodir=DIR info documentation [DATAROOTDIR/info]
--localedir=DIR locale-dependent data [DATAROOTDIR/locale]
--mandir=DIR man documentation [DATAROOTDIR/man]
--docdir=DIR documentation root [DATAROOTDIR/doc/linuxcnc]
--htmldir=DIR html documentation [DOCDIR]
--dvidir=DIR dvi documentation [DOCDIR]
--pdfdir=DIR pdf documentation [DOCDIR]
--psdir=DIR ps documentation [DOCDIR]
X features:
--x-includes=DIR X include files are in DIR
--x-libraries=DIR X library files are in DIR
Optional Features:
--disable-option-checking ignore unrecognized --enable/--with options
--disable-FEATURE do not include FEATURE (same as --enable-FEATURE=no)
--enable-FEATURE[=ARG] include FEATURE [ARG=yes]
--enable-non-distributable
To build LinuxCNC even if a license problem would
render the resulting binaries non-distributable
under the terms of the LinuxCNC license
--enable-simulator Deprecated! Use --with-realtime=uspace instead.
--disable-userspace-pci Disable userspace PCI access (use this if libudev is
unavailable).
--disable-gtk Disable the parts of LinuxCNC that depend on GTK.
--enable-build-documentation=FORMAT
Build documentation. FORMAT may be "Y" for both or
"pdf" or "html" if only one format is desired.
--disable-check-runtime-deps
Skip checks for runtime requirements not needed
during the build process.
--disable-nls Don't use NLS.
Optional Packages:
--with-PACKAGE[=ARG] use PACKAGE [ARG=yes]
--without-PACKAGE do not use PACKAGE (same as --with-PACKAGE=no)
--with-realtime=PATH Path where RTAI is installed, or "uspace" for POSIX
userspace.
--with-kernel-headers=PATH
Location for kernel headers.
--with-libmodbus Specify whether or not to build the drivers that use
libmodbus (defaults to "yes").
--with-libusb-1.0 Specify whether or not to build the drivers that use
libusb-1.0 (defaults to "yes").
--with-kbuild Specify if your kernel uses kbuild or not.
--with-module-dir=PATH Installation directory for kernel modules.
--with-rmmod=PATH Location of the rmmod program to use.
--with-insmod=PATH Location of the insmod program to use.
--with-python=PATH Specify the Python interpreter.
--with-tclConfig=PATH Specify the path to tclConfig.
--with-tkConfig=PATH Specify the path to tkConfig.
--with-x use the X Window System
--with-locale-dir=DIR Location of the locale file(s) [DATADIR/locale].
--with-boost-python Specify the boost python shared library to use. For
instance, --with-boost-python=boost_python-py25.
Defaults to boost-python. If you use this then you
should probably set PYTHON too, to avoid using
multiple python versions.
Some influential environment variables:
CXX C++ compiler command
CXXFLAGS C++ compiler flags
LDFLAGS linker flags, e.g. -L<lib dir> if you have libraries in a
nonstandard directory <lib dir>
LIBS libraries to pass to the linker, e.g. -l<library>
CPPFLAGS (Objective) C/C++ preprocessor flags, e.g. -I<include dir> if
you have headers in a nonstandard directory <include dir>
CC C compiler command
CFLAGS C compiler flags
CPP C preprocessor
XMKMF Path to xmkmf, Makefile generator for X Window System
Use these variables to override the choices made by 'configure' or to help
it to find libraries and programs with nonstandard names/locations.
Report bugs to <emc-developers@lists.sourceforge.net>.
Последний раз редактировалось lnx 08.08.2025 00:50, всего редактировалось 1 раз.
Я дважды перечитал, и все равно прошляпил! Мой стиль, со всей очевидностью, выборочное чтение :( И мы двинулись дальше к новым ошибкам, они не заставили себя долго ждать. .configure прошло без ошибок, make сперва ругнулось, как я ошибочно предположил, на желание яда реального времени - перезагрузился в него, компиляция упала со словами -indeviral:--with-python=PATH Specify the Python interpreter.
/usr/include/boost/lockfree/queue.hpp:612:44: ошибка: размер массива не является целочисленным константным выражением
612 | char padding2[ padding_size ];
| ^~~~~~~~~~~~
make: *** [Makefile:222: objects/rtapi/uspace_rtapi_app.o] Ошибка 1
uname -r
6.14.0-rt3-arch1-2-rt
Если же выполнить configure для НЕ реально времени компиляция как-бы не падает, ошибок не выдает, заканчивается примерно так -
In file included from /usr/include/glib-2.0/glib/galloca.h:34,
from /usr/include/glib-2.0/glib.h:32,
from /usr/include/glib-2.0/gobject/gbinding.h:30:
/usr/include/glib-2.0/glib/gtypes.h:580:8: замечание: объявлено здесь
580 | struct _GTimeVal
| ^~~~~~~~~
In file included from /usr/include/gtk-2.0/gtk/gtktoolitem.h:31,
from /usr/include/gtk-2.0/gtk/gtktoolbutton.h:30,
from /usr/include/gtk-2.0/gtk/gtkmenutoolbutton.h:30,
from /usr/include/gtk-2.0/gtk/gtk.h:126:
/usr/include/gtk-2.0/gtk/gtktooltips.h:73:3: предупреждение: «GTimeVal» устаревшее: Use 'GDateTime' instead [-Wdeprecated-declarations]
73 | GTimeVal last_popdown;
| ^~~~~~~~
In file included from /usr/include/glib-2.0/glib/galloca.h:34,
from /usr/include/glib-2.0/glib.h:32,
from /usr/include/glib-2.0/gobject/gbinding.h:30:
/usr/include/glib-2.0/glib/gtypes.h:580:8: замечание: объявлено здесь
580 | struct _GTimeVal
| ^~~~~~~~~
Makefile:1133: предупреждение: неопределённая переменная «opto_ac5-objs»
'make install' is only supported for building packages,
and it doesn't look like that is what is going on because
you have not set DESTDIR.
make: *** [Makefile:555: install] Ошибка 99