同步主线2.2.3.5-0k0.4版本
This commit is contained in:
parent
ce02980987
commit
0dd58ddf2d
|
@ -1,3 +1,20 @@
|
|||
libkysdk-system (2.2.3.5-0k0.4) yangtze; urgency=medium
|
||||
|
||||
*Bug号:180900 181529 180559 180720 180431 180097 180715 182069
|
||||
*需求号:
|
||||
*其他修改:删除shlibs自动补全依赖
|
||||
pc文件添加kysdk-base路径
|
||||
|
||||
-- szm-min <shaozhimin@kylinos.cn> Tue, 11 Jul 2023 17:33:13 +0800
|
||||
|
||||
libkysdk-system (2.2.3.5-0k0.3) yangtze; urgency=medium
|
||||
|
||||
*Bug号:
|
||||
*需求号:
|
||||
*其他修改:159242 子 【蒙古文版本】蒙古文版本翻译未生效问题 / kysdk-system 蒙古文版本翻译未生效问题
|
||||
|
||||
-- szm-min <shaozhimin@kylinos.cn> Wed, 28 Jun 2023 11:36:40 +0800
|
||||
|
||||
libkysdk-system (2.2.3.5-0k0.2) yangtze; urgency=medium
|
||||
|
||||
*Bug号:
|
||||
|
|
|
@ -38,250 +38,246 @@ Homepage: http://gitlab2.kylin.com/kysdk/kysdk-system
|
|||
Package: libkysdk-system
|
||||
Architecture: any
|
||||
Section: utils
|
||||
Depends: ${shlibs:Depends},
|
||||
${misc:Depends},
|
||||
libkysdk-disk,
|
||||
libkysdk-sysinfo,
|
||||
libkysdk-systime,
|
||||
libkysdk-filesystem,
|
||||
libkysdk-proc,
|
||||
libkysdk-hardware,
|
||||
libkysdk-package,
|
||||
libkysdk-powermanagement,
|
||||
systemd,
|
||||
libglib2.0-0,
|
||||
libkysdk-systemcommon,
|
||||
libkysdk-location,
|
||||
libkysdk-net,
|
||||
libkysdk-realtime
|
||||
Depends: libkysdk-disk,
|
||||
libkysdk-sysinfo,
|
||||
libkysdk-systime,
|
||||
libkysdk-filesystem,
|
||||
libkysdk-proc,
|
||||
libkysdk-hardware,
|
||||
libkysdk-package,
|
||||
libkysdk-powermanagement,
|
||||
systemd,
|
||||
libglib2.0-0,
|
||||
libkysdk-systemcommon,
|
||||
libkysdk-location,
|
||||
libkysdk-net,
|
||||
libkysdk-realtime
|
||||
Multi-Arch: same
|
||||
Description: 麒麟开发者套件 - 系统层套件,提供系统信息、磁盘信息、系统时间等API与服务
|
||||
|
||||
Package: libkysdk-system-dev
|
||||
Architecture: all
|
||||
Section: utils
|
||||
Depends: ${shlibs:Depends},
|
||||
${misc:Depends},
|
||||
libkysdk-system,
|
||||
libkysdk-disk-dev,
|
||||
libkysdk-sysinfo-dev,
|
||||
libkysdk-systime-dev,
|
||||
libkysdk-sysinfo-dev,
|
||||
libkysdk-filesystem-dev,
|
||||
libkysdk-proc-dev,
|
||||
libkysdk-hardware-dev,
|
||||
libkysdk-package-dev,
|
||||
libkysdk-powermanagement-dev,
|
||||
libkysdk-location-dev,
|
||||
libkysdk-net-dev,
|
||||
libkysdk-realtime-dev
|
||||
Depends: libkysdk-system,
|
||||
libkysdk-disk-dev,
|
||||
libkysdk-sysinfo-dev,
|
||||
libkysdk-systime-dev,
|
||||
libkysdk-sysinfo-dev,
|
||||
libkysdk-filesystem-dev,
|
||||
libkysdk-proc-dev,
|
||||
libkysdk-hardware-dev,
|
||||
libkysdk-package-dev,
|
||||
libkysdk-powermanagement-dev,
|
||||
libkysdk-location-dev,
|
||||
libkysdk-net-dev,
|
||||
libkysdk-realtime-dev
|
||||
Multi-Arch: foreign
|
||||
Description: 麒麟开发者套件 - 系统层套件 - 开发库,提供系统信息、磁盘信息、系统时间等API与服务
|
||||
|
||||
Package: libkysdk-disk
|
||||
Architecture: any
|
||||
Section: utils
|
||||
Depends: ${shlibs:Depends},
|
||||
${misc:Depends},
|
||||
libkysdk-log(>=1.2.0),
|
||||
libkysdk-systemcommon,
|
||||
libhd21
|
||||
Depends: libkysdk-log(>=1.2.0),
|
||||
libkysdk-systemcommon,
|
||||
libhd21,
|
||||
libblkid1,
|
||||
libc6,
|
||||
libkysdk-config(>=1.2.0),
|
||||
libsystemd0,
|
||||
libudev1
|
||||
Multi-Arch: same
|
||||
Description: 系统磁盘信息获取库
|
||||
|
||||
Package: libkysdk-disk-dev
|
||||
Architecture: all
|
||||
Section: utils
|
||||
Depends: ${shlibs:Depends},
|
||||
${misc:Depends},
|
||||
libkysdk-disk,
|
||||
libkysdk-log-dev(>=1.2.0),
|
||||
libkysdk-utils-dev(>=1.2.0),
|
||||
libblkid-dev,
|
||||
libudev-dev
|
||||
Depends: libkysdk-disk,
|
||||
libkysdk-log-dev(>=1.2.0),
|
||||
libkysdk-utils-dev(>=1.2.0),
|
||||
libblkid-dev,
|
||||
libudev-dev
|
||||
Multi-Arch: foreign
|
||||
Description: 系统磁盘信息获取库 - 开发库
|
||||
|
||||
Package: libkysdk-systime
|
||||
Architecture: any
|
||||
Section: utils
|
||||
Depends: ${shlibs:Depends},
|
||||
${misc:Depends},
|
||||
libkysdk-log(>=1.2.0),
|
||||
dbus,
|
||||
systemd,
|
||||
libglib2.0-0,
|
||||
libkysdk-timer(>=1.2.0),
|
||||
libkysdk-config(>=1.2.0),
|
||||
libkysdk-systemcommon
|
||||
Depends: libkysdk-log(>=1.2.0),
|
||||
dbus,
|
||||
systemd,
|
||||
libglib2.0-0,
|
||||
libkysdk-timer(>=1.2.0),
|
||||
libkysdk-config(>=1.2.0),
|
||||
libkysdk-systemcommon,
|
||||
libc6,
|
||||
libdbus-1-3,
|
||||
libdbus-glib-1-2
|
||||
Multi-Arch: same
|
||||
Description: 系统时间相关操作库
|
||||
|
||||
Package: libkysdk-systime-dev
|
||||
Architecture: all
|
||||
Section: utils
|
||||
Depends: ${shlibs:Depends},
|
||||
${misc:Depends},
|
||||
libkysdk-systime,
|
||||
libglib2.0-dev,
|
||||
libkysdk-timer-dev(>=1.2.0),
|
||||
libkysdk-config-dev(>=1.2.0)
|
||||
Depends: libkysdk-systime,
|
||||
libglib2.0-dev,
|
||||
libkysdk-timer-dev(>=1.2.0),
|
||||
libkysdk-config-dev(>=1.2.0)
|
||||
Multi-Arch: foreign
|
||||
Description: 系统时间相关操作库 - 开发库
|
||||
|
||||
Package: libkysdk-sysinfo
|
||||
Architecture: any
|
||||
Section: utils
|
||||
Depends: ${shlibs:Depends},
|
||||
${misc:Depends},
|
||||
libkysdk-log(>=1.2.0),
|
||||
dbus,
|
||||
libglib2.0-0,
|
||||
systemd,
|
||||
libcjson1,
|
||||
libxrandr2,
|
||||
libpci3,
|
||||
libkmod2,
|
||||
libkysdk-systemcommon
|
||||
Depends: libkysdk-log(>=1.2.0),
|
||||
dbus,
|
||||
libglib2.0-0,
|
||||
systemd,
|
||||
libcjson1,
|
||||
libxrandr2,
|
||||
libpci3,
|
||||
libkmod2,
|
||||
libkysdk-systemcommon,
|
||||
libc6,
|
||||
libdbus-1-3,
|
||||
libdbus-glib-1-2,
|
||||
libgcc-s1,
|
||||
libkysdk-config(>=1.2.0),
|
||||
libstdc++6,
|
||||
libsystemd0,
|
||||
libx11-6
|
||||
Multi-Arch: same
|
||||
Description: 系统信息获取库
|
||||
|
||||
Package: libkysdk-sysinfo-dev
|
||||
Architecture: all
|
||||
Section: utils
|
||||
Depends: ${shlibs:Depends},
|
||||
${misc:Depends},
|
||||
libkysdk-sysinfo,
|
||||
libkysdk-log-dev(>=1.2.0),
|
||||
libkysdk-utils-dev(>=1.2.0),
|
||||
libsystemd-dev,
|
||||
libcjson-dev,
|
||||
libdbus-1-dev,
|
||||
libdbus-glib-1-dev,
|
||||
libglib2.0-dev,
|
||||
libxrandr-dev
|
||||
Depends: libkysdk-sysinfo,
|
||||
libkysdk-log-dev(>=1.2.0),
|
||||
libkysdk-utils-dev(>=1.2.0),
|
||||
libsystemd-dev,
|
||||
libcjson-dev,
|
||||
libdbus-1-dev,
|
||||
libdbus-glib-1-dev,
|
||||
libglib2.0-dev,
|
||||
libxrandr-dev
|
||||
Multi-Arch: foreign
|
||||
Description: 系统信息获取库 - 开发库
|
||||
|
||||
Package: libkysdk-filesystem
|
||||
Architecture: any
|
||||
Section: utils
|
||||
Depends: ${shlibs:Depends},
|
||||
${misc:Depends},
|
||||
libkysdk-log(>=1.2.0),
|
||||
libqt5core5a,
|
||||
libkysdk-config(>=1.2.0),
|
||||
systemd,
|
||||
libkysdk-systemcommon
|
||||
Depends: libkysdk-log(>=1.2.0),
|
||||
libqt5core5a,
|
||||
libkysdk-config(>=1.2.0),
|
||||
systemd,
|
||||
libkysdk-systemcommon,
|
||||
libc6,
|
||||
libgcc-s1,
|
||||
libstdc++6,
|
||||
libsystemd0
|
||||
Multi-Arch: same
|
||||
Description: 文件系统库
|
||||
|
||||
Package: libkysdk-filesystem-dev
|
||||
Architecture: all
|
||||
Section: utils
|
||||
Depends: ${shlibs:Depends},
|
||||
${misc:Depends},
|
||||
libkysdk-filesystem,
|
||||
libkysdk-log-dev(>=1.2.0),
|
||||
libkysdk-config-dev(>=1.2.0),
|
||||
libsystemd-dev,
|
||||
qtbase5-dev
|
||||
Depends: libkysdk-filesystem,
|
||||
libkysdk-log-dev(>=1.2.0),
|
||||
libkysdk-config-dev(>=1.2.0),
|
||||
libsystemd-dev,
|
||||
qtbase5-dev
|
||||
Multi-Arch: foreign
|
||||
Description: 文件系统库 - 开发库
|
||||
|
||||
Package: libkysdk-hardware
|
||||
Architecture: any
|
||||
Section: utils
|
||||
Depends: ${shlibs:Depends},
|
||||
${misc:Depends},
|
||||
libkysdk-log(>=1.2.0),
|
||||
libkysdk-config(>=1.2.0),
|
||||
systemd,
|
||||
libkysdk-systemcommon,
|
||||
libcups2,
|
||||
libcurl4,
|
||||
libudev1,
|
||||
libhd21,
|
||||
libpci3,
|
||||
libxrandr2,
|
||||
libbluetooth3,
|
||||
libsensors5,
|
||||
libglib2.0-0,
|
||||
libdbus-glib-1-2
|
||||
Depends: libkysdk-log(>=1.2.0),
|
||||
libkysdk-config(>=1.2.0),
|
||||
systemd,
|
||||
libkysdk-systemcommon,
|
||||
libcups2,
|
||||
libcurl4,
|
||||
libudev1,
|
||||
libhd21,
|
||||
libpci3,
|
||||
libxrandr2,
|
||||
libbluetooth3,
|
||||
libsensors5,
|
||||
libglib2.0-0,
|
||||
libdbus-glib-1-2,
|
||||
libc6,
|
||||
libsystemd0,
|
||||
libx11-6
|
||||
Multi-Arch: same
|
||||
Description: 硬件信息获取库
|
||||
|
||||
Package: libkysdk-hardware-dev
|
||||
Architecture: all
|
||||
Section: utils
|
||||
Depends: ${shlibs:Depends},
|
||||
${misc:Depends},
|
||||
libkysdk-hardware,
|
||||
libkysdk-log-dev(>=1.2.0),
|
||||
libkysdk-config-dev(>=1.2.0),
|
||||
libsystemd-dev,
|
||||
libcups2-dev,
|
||||
libcurl4-openssl-dev,
|
||||
libudev-dev,
|
||||
libxrandr-dev
|
||||
Depends: libkysdk-hardware,
|
||||
libkysdk-log-dev(>=1.2.0),
|
||||
libkysdk-config-dev(>=1.2.0),
|
||||
libsystemd-dev,
|
||||
libcups2-dev,
|
||||
libcurl4-openssl-dev,
|
||||
libudev-dev,
|
||||
libxrandr-dev
|
||||
Multi-Arch: foreign
|
||||
Description: 硬件信息获取库 - 开发库
|
||||
|
||||
Package: libkysdk-package
|
||||
Architecture: any
|
||||
Section: utils
|
||||
Depends: ${shlibs:Depends},
|
||||
${misc:Depends},
|
||||
libkysdk-systemcommon
|
||||
Depends: libkysdk-systemcommon,
|
||||
libc6
|
||||
Multi-Arch: same
|
||||
Description: 包管理库
|
||||
|
||||
Package: libkysdk-package-dev
|
||||
Architecture: all
|
||||
Section: utils
|
||||
Depends: ${shlibs:Depends},
|
||||
${misc:Depends},
|
||||
libkysdk-package
|
||||
Depends: libkysdk-package
|
||||
Multi-Arch: foreign
|
||||
Description: 包管理库 - 开发库
|
||||
|
||||
Package: libkysdk-proc
|
||||
Architecture: any
|
||||
Section: utils
|
||||
Depends: ${shlibs:Depends},
|
||||
${misc:Depends},
|
||||
libkysdk-log(>=1.2.0),
|
||||
libkysdk-systemcommon
|
||||
Depends: libkysdk-log(>=1.2.0),
|
||||
libkysdk-systemcommon,
|
||||
libc6
|
||||
Multi-Arch: same
|
||||
Description: 运行时信息获取库
|
||||
|
||||
Package: libkysdk-proc-dev
|
||||
Architecture: all
|
||||
Section: utils
|
||||
Depends: ${shlibs:Depends},
|
||||
${misc:Depends},
|
||||
libkysdk-log-dev(>=1.2.0),
|
||||
libkysdk-utils-dev(>=1.2.0),
|
||||
libkysdk-proc
|
||||
Depends: libkysdk-log-dev(>=1.2.0),
|
||||
libkysdk-utils-dev(>=1.2.0),
|
||||
libkysdk-proc
|
||||
Multi-Arch: foreign
|
||||
Description: 运行时信息获取库 - 开发库
|
||||
|
||||
Package: libkysdk-powermanagement
|
||||
Architecture: any
|
||||
Section: utils
|
||||
Depends: ${shlibs:Depends},
|
||||
${misc:Depends},
|
||||
libkysdk-log(>=1.2.0),
|
||||
libkysdk-systemcommon
|
||||
Depends: libkysdk-log(>=1.2.0),
|
||||
libkysdk-systemcommon,
|
||||
libc6,
|
||||
libdbus-1-3,
|
||||
libgcc-s1,
|
||||
libkysdk-config(>=1.2.0),
|
||||
libkysdk-utils(>=1.2.0),
|
||||
libstdc++6,
|
||||
libsystemd0
|
||||
Multi-Arch: same
|
||||
Description: 电源管理库
|
||||
|
||||
Package: libkysdk-powermanagement-dev
|
||||
Architecture: all
|
||||
Section: utils
|
||||
Depends: ${shlibs:Depends},
|
||||
${misc:Depends},
|
||||
libkysdk-log-dev(>=1.2.0),
|
||||
Depends: libkysdk-log-dev(>=1.2.0),
|
||||
libkysdk-powermanagement
|
||||
Multi-Arch: foreign
|
||||
Description: 电源管理 - 开发库
|
||||
|
@ -289,151 +285,177 @@ Description: 电源管理 - 开发库
|
|||
Package: libkysdk-ocr
|
||||
Architecture: any
|
||||
Multi-Arch: same
|
||||
Depends: ${shlibs:Depends},
|
||||
${misc:Depends},
|
||||
libopencv-core4.2,
|
||||
Depends: libopencv-core4.2,
|
||||
libopencv-highgui4.2,
|
||||
libopencv-imgproc4.2,
|
||||
libopencv-imgcodecs4.2,
|
||||
liblept5,
|
||||
libarchive13,
|
||||
libtesseract4,
|
||||
libkysdk-systemcommon
|
||||
libkysdk-systemcommon,
|
||||
libc6,
|
||||
libgcc-s1,
|
||||
libstdc++6
|
||||
Description: AI文字识别功能
|
||||
|
||||
Package: libkysdk-ocr-dev
|
||||
Architecture: all
|
||||
Multi-Arch: foreign
|
||||
Depends: ${shlibs:Depends}, ${misc:Depends},libkysdk-ocr,libleptonica-dev,libopencv-dev,libarchive-dev,libtesseract-dev
|
||||
Depends: libkysdk-ocr,
|
||||
libleptonica-dev,
|
||||
libopencv-dev,
|
||||
libarchive-dev,
|
||||
libtesseract-dev
|
||||
Description: AI文字识别功能-开发库
|
||||
|
||||
Package: libkysdk-systemcommon
|
||||
Architecture: any
|
||||
Section: utils
|
||||
Depends: ${shlibs:Depends},
|
||||
${misc:Depends}
|
||||
Depends:
|
||||
Multi-Arch: same
|
||||
Description: kysdk-system层公用数据包
|
||||
|
||||
Package: libkysdk-location
|
||||
Architecture: any
|
||||
Section: utils
|
||||
Depends: ${shlibs:Depends},
|
||||
${misc:Depends},
|
||||
libkysdk-systemcommon,
|
||||
libglib2.0-0
|
||||
Depends: libkysdk-systemcommon,
|
||||
libglib2.0-0,
|
||||
libc6
|
||||
Multi-Arch: same
|
||||
Description: 地理位置库
|
||||
|
||||
Package: libkysdk-location-dev
|
||||
Architecture: all
|
||||
Section: utils
|
||||
Depends: ${shlibs:Depends},
|
||||
${misc:Depends},
|
||||
libkysdk-location
|
||||
Depends: libkysdk-location
|
||||
Multi-Arch: foreign
|
||||
Description: 地理位置库 - 开发库
|
||||
|
||||
Package: libkysdk-net
|
||||
Architecture: any
|
||||
Section: utils
|
||||
Depends: ${shlibs:Depends},
|
||||
${misc:Depends},
|
||||
libkysdk-systemcommon
|
||||
Depends: libkysdk-systemcommon,
|
||||
libc6
|
||||
Multi-Arch: same
|
||||
Description: 网络信息库
|
||||
|
||||
Package: libkysdk-net-dev
|
||||
Architecture: all
|
||||
Section: utils
|
||||
Depends: ${shlibs:Depends},
|
||||
${misc:Depends},
|
||||
libkysdk-net
|
||||
Depends: libkysdk-net
|
||||
Multi-Arch: foreign
|
||||
Description: 网络信息库 - 开发库
|
||||
|
||||
Package: libkysdk-realtime
|
||||
Architecture: any
|
||||
Section: utils
|
||||
Depends: ${shlibs:Depends},
|
||||
${misc:Depends},
|
||||
libkysdk-systemcommon
|
||||
Depends: libkysdk-systemcommon,
|
||||
libc6
|
||||
Multi-Arch: same
|
||||
Description: 运行时信息库
|
||||
|
||||
Package: libkysdk-realtime-dev
|
||||
Architecture: all
|
||||
Section: utils
|
||||
Depends: ${shlibs:Depends},
|
||||
${misc:Depends},
|
||||
libkysdk-realtime
|
||||
Depends: libkysdk-realtime
|
||||
Multi-Arch: foreign
|
||||
Description: 运行时信息库 - 开发库
|
||||
|
||||
Package: libkysdk-system-java
|
||||
Architecture: any
|
||||
Section: utils
|
||||
Depends: ${shlibs:Depends},
|
||||
${misc:Depends},
|
||||
libkysdk-system-dbus
|
||||
Depends: libkysdk-system-dbus
|
||||
Multi-Arch: same
|
||||
Description: 多语言支持 - java
|
||||
|
||||
Package: libkysdk-system-python
|
||||
Architecture: any
|
||||
Depends: ${shlibs:Depends}, ${misc:Depends}, python3-dbus, libkysdk-system-dbus
|
||||
Depends: python3-dbus,
|
||||
libkysdk-system-dbus
|
||||
Multi-Arch: same
|
||||
Description: 多语言支持 - python
|
||||
|
||||
Package: libkysdk-system-dbus
|
||||
Architecture: any
|
||||
Section: utils
|
||||
Depends: ${shlibs:Depends},
|
||||
${misc:Depends},
|
||||
libqt5dbus5,
|
||||
libkysdk-disk,
|
||||
libkysdk-hardware,
|
||||
libkysdk-location,
|
||||
libkysdk-net,
|
||||
libkysdk-package,
|
||||
libkysdk-proc,
|
||||
libkysdk-realtime,
|
||||
libkysdk-sysinfo
|
||||
Depends: libqt5dbus5,
|
||||
libkysdk-disk,
|
||||
libkysdk-hardware,
|
||||
libkysdk-location,
|
||||
libkysdk-net,
|
||||
libkysdk-package,
|
||||
libkysdk-proc,
|
||||
libkysdk-realtime,
|
||||
libkysdk-sysinfo,
|
||||
libblkid1,
|
||||
libbluetooth3,
|
||||
libc6,
|
||||
libcjson1,
|
||||
libcups2,
|
||||
libcurl4,
|
||||
libdbus-1-3,
|
||||
libdbus-glib-1-2,
|
||||
libgcc-s1,
|
||||
libglib2.0-0,
|
||||
libhd21,
|
||||
libkmod2,
|
||||
libkysdk-config(>=1.2.0),
|
||||
libkysdk-log(>=1.2.0),
|
||||
libpci3,
|
||||
libqt5core5a,
|
||||
libsensors5,
|
||||
libstdc++6,
|
||||
libsystemd0,
|
||||
libudev1,
|
||||
libx11-6,
|
||||
libxrandr2
|
||||
Multi-Arch: same
|
||||
Description: sdk dbus
|
||||
|
||||
Package: libkysdk-system-javascript-http
|
||||
Architecture: any
|
||||
Depends: ${shlibs:Depends}, ${misc:Depends},libqt5widgets5,libqt5gui5,libqt5dbus5,libqt5core5a,libkysdk-system-dbus
|
||||
Depends: libqt5widgets5,
|
||||
libqt5gui5 | libqt5gui5-gles,
|
||||
libqt5dbus5,
|
||||
libqt5core5a,
|
||||
libkysdk-system-dbus,
|
||||
libc6,
|
||||
libgcc-s1,
|
||||
libqt5concurrent5,
|
||||
libqt5network5,
|
||||
libstdc++6
|
||||
Multi-Arch: same
|
||||
Description:多语言支持 - javascript
|
||||
|
||||
Package: libkysdk-system-javascript-websocket
|
||||
Architecture: any
|
||||
Depends: ${shlibs:Depends}, ${misc:Depends},libqt5webchannel5,libqt5websockets5,libkysdk-system-dbus
|
||||
Depends: libqt5webchannel5,
|
||||
libqt5websockets5,
|
||||
libkysdk-system-dbus,
|
||||
libc6,
|
||||
libgcc-s1,
|
||||
libqt5concurrent5,
|
||||
libqt5core5a,
|
||||
libqt5dbus5,
|
||||
libqt5gui5 | libqt5gui5-gles,
|
||||
libqt5network5,
|
||||
libqt5qml5,
|
||||
libqt5widgets5,
|
||||
libstdc++6
|
||||
Multi-Arch: same
|
||||
Description: 多语言支持 - javascript
|
||||
|
||||
Package: libkysdk-logrotate
|
||||
Architecture: any
|
||||
Section: utils
|
||||
Depends: ${shlibs:Depends},
|
||||
${misc:Depends},
|
||||
libkysdk-systemcommon,
|
||||
libqt5core5a,
|
||||
libqt5dbus5,
|
||||
libkysdk-log,
|
||||
logrotate
|
||||
Depends: libkysdk-systemcommon,
|
||||
libqt5core5a,
|
||||
libqt5dbus5,
|
||||
libkysdk-log(>=1.2.0),
|
||||
logrotate,
|
||||
libc6,
|
||||
libgcc-s1,
|
||||
libstdc++6
|
||||
Multi-Arch: same
|
||||
Description: 日志转储服务
|
||||
|
||||
Package: libkysdk-processmanage
|
||||
Architecture: any
|
||||
Depends: ${misc:Depends},
|
||||
${shlibs:Depends},
|
||||
libdbus-1-3,
|
||||
libkysdk-log,
|
||||
libkysdk-config,
|
||||
libkysdk-utils
|
||||
Description: 进程管理
|
||||
|
||||
|
|
|
@ -2,5 +2,5 @@ Name: libkysdk-disk
|
|||
Description: kysdk system layer disk component
|
||||
Requires: kysdk-log kysdk-utils libudev blkid
|
||||
Version: 2.0.0
|
||||
Libs: -L/usr/lib/kysdk/kysdk-system/ -lkydiskinfo -Wl,-rpath=/usr/lib/kysdk/kysdk-system/
|
||||
Cflags: -I/usr/include/kysdk/kysdk-system/
|
||||
Libs: -L/usr/lib/kysdk/kysdk-system/ -L/usr/lib/kysdk/kysdk-base -lkydiskinfo -Wl,-rpath=/usr/lib/kysdk/kysdk-system/
|
||||
Cflags: -I/usr/include/kysdk/kysdk-system/
|
||||
|
|
|
@ -2,5 +2,5 @@ Name: libkysdk-filesystem
|
|||
Description: kysdk system layer filesystem component
|
||||
Requires: kysdk-log kysdk-config libsystemd Qt5Core
|
||||
Version: 2.0.0
|
||||
Libs: -L/usr/lib/kysdk/kysdk-system/ -lkyfilewatcher -Wl,-rpath=/usr/lib/kysdk/kysdk-system/
|
||||
Cflags: -I/usr/include/kysdk/kysdk-system/
|
||||
Libs: -L/usr/lib/kysdk/kysdk-system/ -L/usr/lib/kysdk/kysdk-base -lkyfilewatcher -Wl,-rpath=/usr/lib/kysdk/kysdk-system/
|
||||
Cflags: -I/usr/include/kysdk/kysdk-system/
|
||||
|
|
|
@ -2,5 +2,5 @@ Name: libkysdk-hardware
|
|||
Description: kysdk system layer hardware component
|
||||
Requires: kysdk-log kysdk-config libsystemd libudev
|
||||
Version: 2.0.0
|
||||
Libs: -L/usr/lib/kysdk/kysdk-system/ -lkyhw -Wl,-rpath=/usr/lib/kysdk/kysdk-system/
|
||||
Cflags: -I/usr/include/kysdk/kysdk-system/
|
||||
Libs: -L/usr/lib/kysdk/kysdk-system/ -L/usr/lib/kysdk/kysdk-base -lkyhw -Wl,-rpath=/usr/lib/kysdk/kysdk-system/
|
||||
Cflags: -I/usr/include/kysdk/kysdk-system/
|
||||
|
|
|
@ -2,5 +2,5 @@ Name: libkysdk-location
|
|||
Description: kysdk system layer location
|
||||
Requires:glib-2.0
|
||||
Version: 2.0.0
|
||||
Libs: -L/usr/lib/kysdk/kysdk-system/ -lkylocation -Wl,-rpath=/usr/lib/kysdk/kysdk-system/
|
||||
Cflags: -I/usr/include/kysdk/kysdk-system/
|
||||
Libs: -L/usr/lib/kysdk/kysdk-system/ -L/usr/lib/kysdk/kysdk-base -lkylocation -Wl,-rpath=/usr/lib/kysdk/kysdk-system/
|
||||
Cflags: -I/usr/include/kysdk/kysdk-system/
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
Name: libkysdk-net
|
||||
Description: kysdk system layer netinfo
|
||||
Version: 2.0.0
|
||||
Libs: -L/usr/lib/kysdk/kysdk-system/ -lkynetinfo -Wl,-rpath=/usr/lib/kysdk/kysdk-system/
|
||||
Cflags: -I/usr/include/kysdk/kysdk-system/
|
||||
Libs: -L/usr/lib/kysdk/kysdk-system/ -L/usr/lib/kysdk/kysdk-base -lkynetinfo -Wl,-rpath=/usr/lib/kysdk/kysdk-system/
|
||||
Cflags: -I/usr/include/kysdk/kysdk-system/
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
Name: libkysdk-ocr
|
||||
Description: kysdk system ocr package component
|
||||
Version: 2.0.0
|
||||
Libs: -L/usr/lib/kysdk/kysdk-system/ -lkyocr -Wl,-rpath=/usr/lib/kysdk/kysdk-system/
|
||||
Cflags: -I/usr/include/kysdk/kysdk-system/
|
||||
Libs: -L/usr/lib/kysdk/kysdk-system/ -L/usr/lib/kysdk/kysdk-base -lkyocr -Wl,-rpath=/usr/lib/kysdk/kysdk-system/
|
||||
Cflags: -I/usr/include/kysdk/kysdk-system/
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
Name: libkysdk-package
|
||||
Description: kysdk system layer package component
|
||||
Version: 2.0.0
|
||||
Libs: -L/usr/lib/kysdk/kysdk-system/ -lkypackage -Wl,-rpath=/usr/lib/kysdk/kysdk-system/
|
||||
Cflags: -I/usr/include/kysdk/kysdk-system/
|
||||
Libs: -L/usr/lib/kysdk/kysdk-system/ -L/usr/lib/kysdk/kysdk-base -lkypackage -Wl,-rpath=/usr/lib/kysdk/kysdk-system/
|
||||
Cflags: -I/usr/include/kysdk/kysdk-system/
|
||||
|
|
|
@ -2,5 +2,5 @@ Name: libkysdk-powermanagement
|
|||
Description: kysdk system layer powermanagement component
|
||||
Requires: kysdk-log
|
||||
Version: 2.0.0
|
||||
Libs: -L/usr/lib/kysdk/kysdk-system/ -lkypowermanagement -Wl,-rpath=/usr/lib/kysdk/kysdk-system/
|
||||
Cflags: -I/usr/include/kysdk/kysdk-system/
|
||||
Libs: -L/usr/lib/kysdk/kysdk-system/ -L/usr/lib/kysdk/kysdk-base -lkypowermanagement -Wl,-rpath=/usr/lib/kysdk/kysdk-system/
|
||||
Cflags: -I/usr/include/kysdk/kysdk-system/
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
Name: libkysdk-proc
|
||||
Description: kysdk system layer process component
|
||||
Version: 2.0.0
|
||||
Libs: -L/usr/lib/kysdk/kysdk-system/ -lkyrtinfo -Wl,-rpath=/usr/lib/kysdk/kysdk-system/
|
||||
Libs: -L/usr/lib/kysdk/kysdk-system/ -L/usr/lib/kysdk/kysdk-base -lkyrtinfo -Wl,-rpath=/usr/lib/kysdk/kysdk-system/
|
||||
Cflags: -I/usr/include/kysdk/kysdk-system/
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
Name: libkysdk-realtime
|
||||
Description: kysdk system layer realtime
|
||||
Version: 2.0.0
|
||||
Libs: -L/usr/lib/kysdk/kysdk-system/ -lkyrealtimeinfo -Wl,-rpath=/usr/lib/kysdk/kysdk-system/
|
||||
Cflags: -I/usr/include/kysdk/kysdk-system/
|
||||
Libs: -L/usr/lib/kysdk/kysdk-system/ -L/usr/lib/kysdk/kysdk-base -lkyrealtimeinfo -Wl,-rpath=/usr/lib/kysdk/kysdk-system/
|
||||
Cflags: -I/usr/include/kysdk/kysdk-system/
|
||||
|
|
|
@ -2,5 +2,5 @@ Name: libkysdk-sysinfo
|
|||
Description: kysdk system layer sysinfo component
|
||||
Requires: kysdk-log kysdk-utils libsystemd dbus-1 dbus-glib-1 gio-2.0 gio-unix-2.0 glib-2.0 gmodule-2.0 gmodule-export-2.0 gmodule-no-export-2.0 gobject-2.0 gthread-2.0
|
||||
Version: 2.0.0
|
||||
Libs: -L/usr/lib/kysdk/kysdk-system/ -lkysysinfo -Wl,-rpath=/usr/lib/kysdk/kysdk-system/
|
||||
Libs: -L/usr/lib/kysdk/kysdk-system/ -L/usr/lib/kysdk/kysdk-base -lkysysinfo -Wl,-rpath=/usr/lib/kysdk/kysdk-system/
|
||||
Cflags: -I/usr/include/kysdk/kysdk-system/
|
||||
|
|
|
@ -2,5 +2,5 @@ Name: libkysdk-system
|
|||
Description: kysdk system layer
|
||||
Requires: kysdk-disk kysdk-filesystem kysdk-hardware kysdk-package kysdk-proc kysdk-sysinfo kysdk-location kysdk-net kysdk-realtime
|
||||
Version: 2.0.0
|
||||
Libs: -L/usr/lib/kysdk/kysdk-system/ -lkydiskinfo -lkyfilewatcher -lkyhw -lkypackage -lkysysinfo -lkyrtinfo -lkylocation -lkynetinfo -lkyrealtime -Wl,-rpath=/usr/lib/kysdk/kysdk-system/
|
||||
Cflags: -I/usr/include/kysdk/kysdk-system/
|
||||
Libs: -L/usr/lib/kysdk/kysdk-system/ -L/usr/lib/kysdk/kysdk-base -lkydiskinfo -lkyfilewatcher -lkyhw -lkypackage -lkysysinfo -lkyrtinfo -lkylocation -lkynetinfo -lkyrealtime -Wl,-rpath=/usr/lib/kysdk/kysdk-system/
|
||||
Cflags: -I/usr/include/kysdk/kysdk-system/
|
||||
|
|
|
@ -2,5 +2,5 @@ Name: libkysdk-systime
|
|||
Description: kysdk system layer date component
|
||||
Requires: kysdk-config glib-2.0
|
||||
Version: 2.0.0
|
||||
Libs: -L/usr/lib/kysdk/kysdk-system/ -lkydate -Wl,-rpath=/usr/lib/kysdk/kysdk-system/
|
||||
Cflags: -I/usr/include/kysdk/kysdk-system/
|
||||
Libs: -L/usr/lib/kysdk/kysdk-system/ -L/usr/lib/kysdk/kysdk-base -lkydate -Wl,-rpath=/usr/lib/kysdk/kysdk-system/
|
||||
Cflags: -I/usr/include/kysdk/kysdk-system/
|
||||
|
|
|
@ -21,4 +21,4 @@ add_subdirectory(realtime)
|
|||
add_subdirectory(kysdkdbus)
|
||||
add_subdirectory(libkysdk-system-javascript-http)
|
||||
add_subdirectory(libkysdk-system-javascript-websocket)
|
||||
add_subdirectory(processmanage)
|
||||
#add_subdirectory(processmanage)
|
||||
|
|
|
@ -260,7 +260,7 @@ static int get_disk_type(kdk_diskinfo *di)
|
|||
if(0 != access(syspath,0))
|
||||
{
|
||||
di->disk_type = DISK_TYPE_NONE;
|
||||
goto out;
|
||||
return 0;
|
||||
}
|
||||
int tfd = open(syspath, O_RDONLY);
|
||||
if (! tfd)
|
||||
|
@ -719,6 +719,14 @@ char* kdk_get_hard_model(const char *hardname)
|
|||
str = tmp + tmp_pos;
|
||||
break;
|
||||
}
|
||||
else if(0 == strncmp(tmp, "Device Model:", 13))
|
||||
{
|
||||
int tmp_pos = strlastof(tmp, ':');
|
||||
if (tmp_pos <= 0)
|
||||
tmp_pos = 0;
|
||||
str = tmp + tmp_pos;
|
||||
break;
|
||||
}
|
||||
}
|
||||
pclose(fd);
|
||||
if (str)
|
||||
|
@ -726,6 +734,9 @@ char* kdk_get_hard_model(const char *hardname)
|
|||
strcpy(hard_model, str);
|
||||
strstripspace(hard_model);
|
||||
}
|
||||
else{
|
||||
return NULL;
|
||||
}
|
||||
return hard_model;
|
||||
}
|
||||
|
||||
|
|
|
@ -702,7 +702,7 @@ char *kdk_edid_get_max_resolution(char *name)
|
|||
continue;
|
||||
}
|
||||
}
|
||||
if(strstr(edid_text, "*+"))
|
||||
if(strstr(edid_text, "+"))
|
||||
{
|
||||
strcpy(tmp, edid_text);
|
||||
}
|
||||
|
@ -1555,8 +1555,9 @@ char* kdk_edid_get_ratio(char *name)
|
|||
XRRCrtcInfo *crtc_info;
|
||||
int iscres;
|
||||
int icrtc;
|
||||
char *tmp = (char *)malloc(sizeof(char) * 20);
|
||||
if(!tmp)
|
||||
char tmp[32] = "\0";
|
||||
char *ratio = (char *)malloc(sizeof(char) * 32);
|
||||
if(!ratio)
|
||||
{
|
||||
return NULL;
|
||||
}
|
||||
|
@ -1596,7 +1597,13 @@ char* kdk_edid_get_ratio(char *name)
|
|||
XRRFreeOutputInfo(info);
|
||||
}
|
||||
XRRFreeScreenResources(screen);
|
||||
return tmp;
|
||||
if(tmp[0] == "\0")
|
||||
{
|
||||
free(ratio);
|
||||
return NULL;
|
||||
}
|
||||
strcpy(ratio, tmp);
|
||||
return ratio;
|
||||
}
|
||||
|
||||
char* kdk_edid_get_character(char *name)
|
||||
|
|
|
@ -16,6 +16,7 @@ extern char** kdk_edid_get_interface();
|
|||
/**
|
||||
* @brief 获取显示器的伽马值
|
||||
*
|
||||
* @param name 显示器的当前接口
|
||||
* @return float 显示器的伽马值
|
||||
*/
|
||||
extern float kdk_edid_get_gamma(char *name);
|
||||
|
@ -23,6 +24,7 @@ extern float kdk_edid_get_gamma(char *name);
|
|||
/**
|
||||
* @brief 获取显示器的屏幕尺寸(英寸)
|
||||
*
|
||||
* @param name 显示器的当前接口
|
||||
* @return float 显示器的屏幕尺寸(英寸)
|
||||
*/
|
||||
extern float kdk_edid_get_size(char *name);
|
||||
|
@ -30,6 +32,7 @@ extern float kdk_edid_get_size(char *name);
|
|||
/**
|
||||
* @brief 获取显示器的最大分辨率
|
||||
*
|
||||
* @param name 显示器的当前接口
|
||||
* @return char* 显示器的最大分辨率
|
||||
*/
|
||||
extern char* kdk_edid_get_max_resolution(char *name);
|
||||
|
@ -37,6 +40,7 @@ extern char* kdk_edid_get_max_resolution(char *name);
|
|||
/**
|
||||
* @brief 获取显示器的显示器型号
|
||||
*
|
||||
* @param name 显示器的当前接口
|
||||
* @return char* 显示器的显示器型号
|
||||
*/
|
||||
extern char* kdk_edid_get_model(char *name);
|
||||
|
@ -44,6 +48,7 @@ extern char* kdk_edid_get_model(char *name);
|
|||
/**
|
||||
* @brief 获取显示器的可视面积
|
||||
*
|
||||
* @param name 显示器的当前接口
|
||||
* @return char* 显示器的可视面积
|
||||
*/
|
||||
extern char* kdk_edid_get_visible_area(char *name);
|
||||
|
@ -51,6 +56,7 @@ extern char* kdk_edid_get_visible_area(char *name);
|
|||
/**
|
||||
* @brief 获取显示器的厂商
|
||||
*
|
||||
* @param name 显示器的当前接口
|
||||
* @return char* 显示器的厂商
|
||||
*/
|
||||
extern char* kdk_edid_get_manufacturer(char *name);
|
||||
|
@ -58,6 +64,7 @@ extern char* kdk_edid_get_manufacturer(char *name);
|
|||
/**
|
||||
* @brief 获取显示器的生产日期/周
|
||||
*
|
||||
* @param name 显示器的当前接口
|
||||
* @return char* 显示器的生产日期/周
|
||||
*/
|
||||
extern int kdk_edid_get_week(char *name);
|
||||
|
@ -65,6 +72,7 @@ extern int kdk_edid_get_week(char *name);
|
|||
/**
|
||||
* @brief 获取显示器的生产日期/年
|
||||
*
|
||||
* @param name 显示器的当前接口
|
||||
* @return char* 显示器的生产日期/年
|
||||
*/
|
||||
extern int kdk_edid_get_year(char *name);
|
||||
|
@ -72,6 +80,7 @@ extern int kdk_edid_get_year(char *name);
|
|||
/**
|
||||
* @brief 获取是否是主显示器(是/否)
|
||||
*
|
||||
* @param name 显示器的当前接口
|
||||
* @return int 是否是主显示器,1为是,0为否
|
||||
*/
|
||||
extern int kdk_edid_get_primary(char *name);
|
||||
|
@ -79,6 +88,7 @@ extern int kdk_edid_get_primary(char *name);
|
|||
/**
|
||||
* @brief 获取分辨率
|
||||
*
|
||||
* @param name 显示器的当前接口
|
||||
* @return char* 分辨率
|
||||
*/
|
||||
extern char* kdk_edid_get_resolution(char *name);
|
||||
|
@ -86,6 +96,7 @@ extern char* kdk_edid_get_resolution(char *name);
|
|||
/**
|
||||
* @brief 获取图像高宽比
|
||||
*
|
||||
* @param name 显示器的当前接口
|
||||
* @return char* 图像高宽比
|
||||
*/
|
||||
extern char* kdk_edid_get_ratio(char *name);
|
||||
|
@ -93,6 +104,7 @@ extern char* kdk_edid_get_ratio(char *name);
|
|||
/**
|
||||
* @brief 获取显示器edid未解析的字符串
|
||||
*
|
||||
* @param name 显示器的当前接口
|
||||
* @return char* edid未解析的字符串
|
||||
*/
|
||||
extern char* kdk_edid_get_character(char *name);
|
||||
|
@ -109,4 +121,4 @@ extern inline void kdk_edid_freeall(char **ptr);
|
|||
}
|
||||
#endif
|
||||
|
||||
#endif
|
||||
#endif
|
||||
|
|
|
@ -32,7 +32,7 @@ static struct prg_node
|
|||
unsigned long inode;
|
||||
char name[PROGNAME_WIDTH];
|
||||
char scon[SELINUX_WIDTH];
|
||||
} * prg_hash[PRG_HASH_SIZE];
|
||||
} *prg_hash[PRG_HASH_SIZE];
|
||||
|
||||
static char prg_cache_loaded = 0;
|
||||
|
||||
|
@ -160,11 +160,11 @@ static void parse_port_state(int *st, int port, FILE *fp)
|
|||
struct sockaddr_in *localaddr = (struct sockaddr_in *)&localsas;
|
||||
struct sockaddr_in *remaddr = (struct sockaddr_in *)&remsas;
|
||||
|
||||
// #if HAVE_AFINET6
|
||||
// char addr6[INET6_ADDRSTRLEN];
|
||||
// struct in6_addr in6;
|
||||
// extern struct aftype inet6_aftype;
|
||||
// #endif
|
||||
// #if HAVE_AFINET6
|
||||
// char addr6[INET6_ADDRSTRLEN];
|
||||
// struct in6_addr in6;
|
||||
// extern struct aftype inet6_aftype;
|
||||
// #endif
|
||||
|
||||
while (fgets(line, 1024, fp))
|
||||
{
|
||||
|
@ -180,31 +180,31 @@ static void parse_port_state(int *st, int port, FILE *fp)
|
|||
break;
|
||||
}
|
||||
}
|
||||
// if (strlen(local_addr) > 8)
|
||||
// {
|
||||
// #if HAVE_AFINET6
|
||||
// /* Demangle what the kernel gives us */
|
||||
// sscanf(local_addr, "%08X%08X%08X%08X",
|
||||
// &in6.s6_addr32[0], &in6.s6_addr32[1],
|
||||
// &in6.s6_addr32[2], &in6.s6_addr32[3]);
|
||||
// inet_ntop(AF_INET6, &in6, addr6, sizeof(addr6));
|
||||
// inet6_aftype.input(1, addr6, &localsas);
|
||||
// sscanf(rem_addr, "%08X%08X%08X%08X",
|
||||
// &in6.s6_addr32[0], &in6.s6_addr32[1],
|
||||
// &in6.s6_addr32[2], &in6.s6_addr32[3]);
|
||||
// inet_ntop(AF_INET6, &in6, addr6, sizeof(addr6));
|
||||
// inet6_aftype.input(1, addr6, &remsas);
|
||||
// localsas.ss_family = AF_INET6;
|
||||
// remsas.ss_family = AF_INET6;
|
||||
// #endif
|
||||
// }
|
||||
// else
|
||||
// {
|
||||
// sscanf(local_addr, "%X", &localaddr->sin_addr.s_addr);
|
||||
// sscanf(rem_addr, "%X", &remaddr->sin_addr.s_addr);
|
||||
// localsas.ss_family = AF_INET;
|
||||
// remsas.ss_family = AF_INET;
|
||||
// }
|
||||
// if (strlen(local_addr) > 8)
|
||||
// {
|
||||
// #if HAVE_AFINET6
|
||||
// /* Demangle what the kernel gives us */
|
||||
// sscanf(local_addr, "%08X%08X%08X%08X",
|
||||
// &in6.s6_addr32[0], &in6.s6_addr32[1],
|
||||
// &in6.s6_addr32[2], &in6.s6_addr32[3]);
|
||||
// inet_ntop(AF_INET6, &in6, addr6, sizeof(addr6));
|
||||
// inet6_aftype.input(1, addr6, &localsas);
|
||||
// sscanf(rem_addr, "%08X%08X%08X%08X",
|
||||
// &in6.s6_addr32[0], &in6.s6_addr32[1],
|
||||
// &in6.s6_addr32[2], &in6.s6_addr32[3]);
|
||||
// inet_ntop(AF_INET6, &in6, addr6, sizeof(addr6));
|
||||
// inet6_aftype.input(1, addr6, &remsas);
|
||||
// localsas.ss_family = AF_INET6;
|
||||
// remsas.ss_family = AF_INET6;
|
||||
// #endif
|
||||
// }
|
||||
// else
|
||||
// {
|
||||
// sscanf(local_addr, "%X", &localaddr->sin_addr.s_addr);
|
||||
// sscanf(rem_addr, "%X", &remaddr->sin_addr.s_addr);
|
||||
// localsas.ss_family = AF_INET;
|
||||
// remsas.ss_family = AF_INET;
|
||||
// }
|
||||
}
|
||||
|
||||
int kdk_net_get_port_stat(int port)
|
||||
|
@ -227,7 +227,7 @@ int kdk_net_get_port_stat(int port)
|
|||
|
||||
int kdk_net_get_multiple_port_stat(int start, int end, int *result)
|
||||
{
|
||||
if(end < start)
|
||||
if (end < start)
|
||||
return -1;
|
||||
for (int i = start; i <= end; i++)
|
||||
{
|
||||
|
@ -282,7 +282,7 @@ prouteMapList kdk_net_get_route()
|
|||
* 默认网关的特性: dst为0,netmask为0, Gateway不为0
|
||||
*/
|
||||
if ((flgs & (RTF_GATEWAY | RTF_UP)) &&
|
||||
g != 0 && d == 0 && m == 0)
|
||||
g != 0 && d == 0 && m == 0)
|
||||
{
|
||||
currnode = (prouteMapList)calloc(1, sizeof(routeMapList));
|
||||
if (!currnode)
|
||||
|
@ -354,7 +354,7 @@ pChain kdk_net_get_iptable_rules()
|
|||
continue;
|
||||
}
|
||||
|
||||
if(!tmp)
|
||||
if (!tmp)
|
||||
continue;
|
||||
|
||||
if (strstr(line, "target prot opt source destination"))
|
||||
|
@ -441,11 +441,11 @@ static enum cardstat _get_card_stat(const char *nc)
|
|||
// close(sfd);
|
||||
if (stIf.ifr_ifru.ifru_flags & IFF_RUNNING)
|
||||
return NCSTAT_LINK_UP;
|
||||
|
||||
|
||||
return NCSTAT_LINK_DOWN;
|
||||
}
|
||||
|
||||
void kdk_net_get_netmask(IN const char* nc, OUT char *mask)
|
||||
void kdk_net_get_netmask(IN const char *nc, OUT char *mask)
|
||||
{
|
||||
struct ifreq ifr;
|
||||
int fd = socket(AF_INET, SOCK_DGRAM, 0);
|
||||
|
@ -457,10 +457,10 @@ void kdk_net_get_netmask(IN const char* nc, OUT char *mask)
|
|||
return;
|
||||
}
|
||||
struct sockaddr_in sin_addr;
|
||||
if(NCSTAT_LINK_UP == _get_card_stat(nc))
|
||||
if (NCSTAT_LINK_UP == _get_card_stat(nc))
|
||||
strcpy(mask, (char *)inet_ntoa(((struct sockaddr_in *)(&ifr.ifr_netmask))->sin_addr));
|
||||
else
|
||||
strcpy(mask,"-");
|
||||
strcpy(mask, "-");
|
||||
}
|
||||
|
||||
static const char *prg_cache_get(unsigned long inode)
|
||||
|
@ -518,7 +518,7 @@ static void prg_cache_load(void)
|
|||
errno = 0;
|
||||
char canonical_filename[4096] = {"\0"};
|
||||
char filename[4096] = {"\0"};
|
||||
if(!realpath(line, canonical_filename) || !verify_file(canonical_filename))
|
||||
if (!realpath(line, canonical_filename) || !verify_file(canonical_filename))
|
||||
{
|
||||
closedir(dirproc);
|
||||
return;
|
||||
|
@ -559,7 +559,7 @@ static void prg_cache_load(void)
|
|||
continue;
|
||||
safe_strncpy(canonical_filename + procfdlen - PATH_FD_SUFFl, PATH_CMDLINE,
|
||||
sizeof(canonical_filename) - procfdlen + PATH_FD_SUFFl);
|
||||
if(!realpath(canonical_filename, filename) || !verify_file(filename))
|
||||
if (!realpath(canonical_filename, filename) || !verify_file(filename))
|
||||
{
|
||||
closedir(dirfd);
|
||||
closedir(dirproc);
|
||||
|
@ -634,13 +634,13 @@ char **kdk_net_get_proc_port()
|
|||
&d, local_addr, &local_port, rem_addr, &rem_port, &state,
|
||||
&txq, &rxq, &timer_run, &time_len, &retr, &uid, &timeout, &inode);
|
||||
const char *proc = prg_cache_get(inode);
|
||||
if (0 == strcmp(proc,"-"))
|
||||
if (0 == strcmp(proc, "-"))
|
||||
continue;
|
||||
|
||||
index++;
|
||||
result = (char **)realloc(result, sizeof(char *) * (index + 1 + 1)); //以NULL结尾
|
||||
result = (char **)realloc(result, sizeof(char *) * (index + 1 + 1)); // 以NULL结尾
|
||||
result[index] = (char *)calloc(1, 64);
|
||||
sprintf(result[index], "%d/%s/%s", local_port,proc,"tcp");
|
||||
sprintf(result[index], "%d/%s/%s", local_port, proc, "tcp");
|
||||
}
|
||||
fclose(fp);
|
||||
|
||||
|
@ -692,7 +692,7 @@ char **kdk_net_get_proc_port()
|
|||
continue;
|
||||
|
||||
index++;
|
||||
result = (char **)realloc(result, sizeof(char *) * (index + 1 + 1)); //以NULL结尾
|
||||
result = (char **)realloc(result, sizeof(char *) * (index + 1 + 1)); // 以NULL结尾
|
||||
result[index] = (char *)calloc(1, 64);
|
||||
sprintf(result[index], "%d/%s/%s", local_port, proc, "udp");
|
||||
}
|
||||
|
@ -735,13 +735,15 @@ char **kdk_net_get_up_port()
|
|||
{
|
||||
char **result = NULL;
|
||||
int index = -1;
|
||||
FILE *fp = fopen("/proc/net/tcp", "r");
|
||||
if (!fp)
|
||||
return NULL;
|
||||
|
||||
char line[1024] = "\0";
|
||||
unsigned long rxq, txq, time_len, retr, inode;
|
||||
int num, local_port, rem_port, d, state, uid, timer_run, timeout;
|
||||
char rem_addr[128] = "0", local_addr[128] = "0";
|
||||
|
||||
FILE *fp = fopen("/proc/net/tcp", "r");
|
||||
if (!fp)
|
||||
return NULL;
|
||||
while (fgets(line, 1024, fp))
|
||||
{
|
||||
num = sscanf(line,
|
||||
|
@ -752,10 +754,10 @@ char **kdk_net_get_up_port()
|
|||
{
|
||||
int i = 0;
|
||||
int flag = 1;
|
||||
while (i <= index) //查重
|
||||
while (i <= index) // 查重
|
||||
{
|
||||
if (local_port == atoi(result[i++]))
|
||||
flag = 0; //有重复 flag置为1
|
||||
flag = 0; // 有重复 flag置为1
|
||||
}
|
||||
|
||||
if (flag)
|
||||
|
@ -771,10 +773,46 @@ char **kdk_net_get_up_port()
|
|||
}
|
||||
}
|
||||
}
|
||||
fclose(fp);
|
||||
|
||||
fp = fopen("/proc/net/tcp", "r");
|
||||
if (!fp)
|
||||
return NULL;
|
||||
while (fgets(line, 1024, fp))
|
||||
{
|
||||
num = sscanf(line,
|
||||
"%d: %64[0-9A-Fa-f]:%X %64[0-9A-Fa-f]:%X %X %lX:%lX %X:%lX %lX %d %d %lu %*s\n",
|
||||
&d, local_addr, &local_port, rem_addr, &rem_port, &state,
|
||||
&txq, &rxq, &timer_run, &time_len, &retr, &uid, &timeout, &inode);
|
||||
if (0x0a == state)
|
||||
{
|
||||
int i = 0;
|
||||
int flag = 1;
|
||||
while (i <= index) // 查重
|
||||
{
|
||||
if (local_port == atoi(result[i++]))
|
||||
flag = 0; // 有重复 flag置为1
|
||||
}
|
||||
|
||||
if (flag)
|
||||
{
|
||||
index++;
|
||||
result = (char **)realloc(result, sizeof(char *) * (index + 1 + 1)); // 以NULL结尾
|
||||
if (!result)
|
||||
goto error;
|
||||
result[index] = (char *)calloc(1, 8);
|
||||
if (!result[index])
|
||||
goto error;
|
||||
sprintf(result[index], "%d", local_port);
|
||||
}
|
||||
}
|
||||
}
|
||||
fclose(fp);
|
||||
result[index + 1] = NULL;
|
||||
|
||||
return result;
|
||||
error:
|
||||
for(int i = 0; result[i]; i++)
|
||||
for (int i = 0; result[i]; i++)
|
||||
{
|
||||
free(result[i]);
|
||||
}
|
||||
|
@ -783,7 +821,7 @@ error:
|
|||
return result;
|
||||
}
|
||||
|
||||
char* kdk_net_get_hosts()
|
||||
char *kdk_net_get_hosts()
|
||||
{
|
||||
FILE *fp = fopen("/etc/hosts", "r");
|
||||
if (fp == NULL)
|
||||
|
@ -802,7 +840,7 @@ char* kdk_net_get_hosts()
|
|||
while (fgets(line, sizeof(line), fp))
|
||||
{
|
||||
strcat(hosts, line);
|
||||
if(line[0] == '\n')
|
||||
if (line[0] == '\n')
|
||||
{
|
||||
break;
|
||||
}
|
||||
|
@ -812,7 +850,7 @@ char* kdk_net_get_hosts()
|
|||
return hosts;
|
||||
}
|
||||
|
||||
char* kdk_net_get_hosts_domain()
|
||||
char *kdk_net_get_hosts_domain()
|
||||
{
|
||||
FILE *fp = fopen("/etc/hosts", "r");
|
||||
if (fp == NULL)
|
||||
|
@ -831,16 +869,16 @@ char* kdk_net_get_hosts_domain()
|
|||
int i = 0;
|
||||
while (fgets(line, sizeof(line), fp))
|
||||
{
|
||||
if(2 == i && '\n' == line[0] )
|
||||
if (2 == i && '\n' == line[0])
|
||||
continue;
|
||||
|
||||
if(line[0] == '\n')
|
||||
if (line[0] == '\n')
|
||||
{
|
||||
i++;
|
||||
continue;
|
||||
}
|
||||
// strcat(hosts, line);
|
||||
if(i == 2)
|
||||
if (i == 2)
|
||||
{
|
||||
strcat(hosts, line);
|
||||
}
|
||||
|
@ -850,13 +888,13 @@ char* kdk_net_get_hosts_domain()
|
|||
return hosts;
|
||||
}
|
||||
|
||||
char** kdk_net_get_resolv_conf()
|
||||
{
|
||||
char **kdk_net_get_resolv_conf()
|
||||
{
|
||||
char nserver[16] = "\0";
|
||||
char addr[16] = "\0";
|
||||
char **result = NULL;
|
||||
result = (char **)realloc(result, sizeof(char *) * 128); //以NULL结尾
|
||||
if(!result)
|
||||
result = (char **)realloc(result, sizeof(char *) * 128); // 以NULL结尾
|
||||
if (!result)
|
||||
{
|
||||
return NULL;
|
||||
}
|
||||
|
@ -871,10 +909,10 @@ char** kdk_net_get_resolv_conf()
|
|||
char line[4096] = "\0";
|
||||
while (fgets(line, sizeof(line), fp))
|
||||
{
|
||||
if(strstr(line,"nameserver"))
|
||||
if (strstr(line, "nameserver"))
|
||||
{
|
||||
result[index] = (char *)malloc(sizeof(char) * 128);
|
||||
if(!result[index])
|
||||
if (!result[index])
|
||||
{
|
||||
fclose(fp);
|
||||
free(result);
|
||||
|
|
|
@ -261,7 +261,7 @@ extern struct KPci *kdk_hw_get_pci_info();
|
|||
/**
|
||||
* @brief 释放由kdk_hw_get_pci_info返回的pci总线信息结构体
|
||||
*
|
||||
* @param disk 由kdk_hw_get_pci_info返回的结构体指针
|
||||
* @param info 由kdk_hw_get_pci_info返回的结构体指针
|
||||
*/
|
||||
extern void kdk_hw_free_pci_info(struct KPci *info);
|
||||
|
||||
|
|
|
@ -280,13 +280,25 @@ int strtok_date(char *tmp, char *str, int mark)
|
|||
i++;
|
||||
p = strtok(NULL,str);
|
||||
}
|
||||
if(mark == 1)
|
||||
|
||||
len = strlen(buf[0]);
|
||||
return len;
|
||||
}
|
||||
|
||||
int strtok_short_date(char *tmp, char *str)
|
||||
{
|
||||
int i = 0;
|
||||
int len = 0;
|
||||
char *buf[3], *p = NULL;
|
||||
p = strtok(tmp, str);
|
||||
while(p)
|
||||
{
|
||||
len = strlen(buf[2]);
|
||||
}
|
||||
else{
|
||||
len = strlen(buf[0]);
|
||||
buf[i] = p;
|
||||
i++;
|
||||
p = strtok(NULL,str);
|
||||
}
|
||||
|
||||
len = strlen(buf[0]);
|
||||
return len;
|
||||
}
|
||||
|
||||
|
@ -446,8 +458,29 @@ err:
|
|||
int kdk_system_set_24_timeformat()
|
||||
{
|
||||
char *homeDir = NULL;
|
||||
int status = 0;
|
||||
|
||||
// homeDir = getenv("HOME");
|
||||
// sprintf(path, "%s/.config/kydate/dateformat.conf", homeDir);
|
||||
|
||||
char canonical_filename[PATH_MAX] = "\0";
|
||||
|
||||
homeDir = getenv("HOME");
|
||||
sprintf(path, "%s/.config/kydate/", homeDir);
|
||||
|
||||
if (!realpath(path, canonical_filename))
|
||||
{
|
||||
if(!verify_file(canonical_filename))
|
||||
{
|
||||
return -1;
|
||||
}
|
||||
status = mkdir(canonical_filename, S_IRWXU | S_IRWXG | S_IROTH | S_IXOTH);
|
||||
if (status != 0) {
|
||||
return -1;
|
||||
}
|
||||
}
|
||||
|
||||
memset(path, 0, sizeof(path));
|
||||
sprintf(path, "%s/.config/kydate/dateformat.conf", homeDir);
|
||||
|
||||
GKeyFile *config = g_key_file_new();
|
||||
|
@ -458,7 +491,7 @@ int kdk_system_set_24_timeformat()
|
|||
|
||||
sprintf(tpath, "/var/lib/lightdm-data/%s/dateformat.conf", home);
|
||||
|
||||
g_key_file_load_from_file(config, path, 0, NULL);
|
||||
g_key_file_load_from_file(config, path, 0, NULL);
|
||||
g_key_file_set_value(config, DATEFORMAT, "TIME_FORMAT", "24小时制");
|
||||
g_key_file_save_to_file(config, path, &gerr);
|
||||
g_key_file_save_to_file(config, tpath, &gerr);
|
||||
|
@ -471,10 +504,30 @@ int kdk_system_set_12_timeformat()
|
|||
{
|
||||
char *homeDir = NULL;
|
||||
GError *gerr = NULL;
|
||||
int status = 0;
|
||||
|
||||
// homeDir = getenv("HOME");
|
||||
// sprintf(path, "%s/.config/kydate/dateformat.conf", homeDir);
|
||||
|
||||
char canonical_filename[PATH_MAX] = "\0";
|
||||
|
||||
homeDir = getenv("HOME");
|
||||
sprintf(path, "%s/.config/kydate/dateformat.conf", homeDir);
|
||||
sprintf(path, "%s/.config/kydate/", homeDir);
|
||||
|
||||
if (!realpath(path, canonical_filename))
|
||||
{
|
||||
if(!verify_file(canonical_filename))
|
||||
{
|
||||
return -1;
|
||||
}
|
||||
status = mkdir(canonical_filename, S_IRWXU | S_IRWXG | S_IROTH | S_IXOTH);
|
||||
if (status != 0) {
|
||||
return -1;
|
||||
}
|
||||
}
|
||||
|
||||
memset(path, 0, sizeof(path));
|
||||
sprintf(path, "%s/.config/kydate/dateformat.conf", homeDir);
|
||||
GKeyFile *config = g_key_file_new();
|
||||
char tpath[100] = {0};
|
||||
|
||||
|
@ -1795,6 +1848,8 @@ int kdk_system_set_short_dateformat(char *format)
|
|||
int status = 0;
|
||||
int mark = 0;
|
||||
char canonical_filename[PATH_MAX] = "\0";
|
||||
int sdate = 0;
|
||||
int len = 0;
|
||||
|
||||
char *env_time = getenv("LC_TIME");
|
||||
if(!env_time)
|
||||
|
@ -1846,71 +1901,135 @@ int kdk_system_set_short_dateformat(char *format)
|
|||
g_key_file_load_from_file(config, path, 0, NULL);
|
||||
if(strstr(tmp, "/"))
|
||||
{
|
||||
int len = strtok_date(tmp, "/", mark);
|
||||
if(len == 4)
|
||||
len = strlen(tmp);
|
||||
sdate = strtok_short_date(tmp, "/");
|
||||
printf("len = %d, sdate = %d\n", len, sdate);
|
||||
if(len == 10)
|
||||
{
|
||||
if(mark == 1)
|
||||
{
|
||||
g_key_file_set_value(config, DATEFORMAT, "SHORT_DATE_FORMAT", "MM/dd/yyyy");
|
||||
}
|
||||
else{
|
||||
g_key_file_set_value(config, DATEFORMAT, "SHORT_DATE_FORMAT", "yyyy/MM/dd");
|
||||
}
|
||||
// if(mark == 1)
|
||||
// {
|
||||
// if(sdate == 4)
|
||||
// {
|
||||
// g_key_file_set_value(config, DATEFORMAT, "SHORT_DATE_FORMAT", "yyyy/MM/dd");
|
||||
// }else{
|
||||
// g_key_file_set_value(config, DATEFORMAT, "SHORT_DATE_FORMAT", "MM/dd/yyyy");
|
||||
// }
|
||||
// }
|
||||
// else{
|
||||
if(sdate == 4)
|
||||
{
|
||||
g_key_file_set_value(config, DATEFORMAT, "SHORT_DATE_FORMAT", "yyyy/MM/dd");
|
||||
}else{
|
||||
g_key_file_set_value(config, DATEFORMAT, "SHORT_DATE_FORMAT", "MM/dd/yyyy");
|
||||
}
|
||||
// }
|
||||
}
|
||||
else if(len == 2){
|
||||
if(mark == 1)
|
||||
{
|
||||
g_key_file_set_value(config, DATEFORMAT, "SHORT_DATE_FORMAT", "M/d/yy");
|
||||
}
|
||||
else{
|
||||
g_key_file_set_value(config, DATEFORMAT, "SHORT_DATE_FORMAT", "yy/M/d");
|
||||
}
|
||||
else {
|
||||
// if(mark == 1)
|
||||
// {
|
||||
// if(sdate == 2)
|
||||
// {
|
||||
// g_key_file_set_value(config, DATEFORMAT, "SHORT_DATE_FORMAT", "yy/M/d");
|
||||
// }else{
|
||||
// g_key_file_set_value(config, DATEFORMAT, "SHORT_DATE_FORMAT", "M/d/yy");
|
||||
// }
|
||||
// }
|
||||
// else{
|
||||
if(sdate == 2)
|
||||
{
|
||||
g_key_file_set_value(config, DATEFORMAT, "SHORT_DATE_FORMAT", "yy/M/d");
|
||||
}else{
|
||||
g_key_file_set_value(config, DATEFORMAT, "SHORT_DATE_FORMAT", "M/d/yy");
|
||||
}
|
||||
// }
|
||||
}
|
||||
}
|
||||
else if(strstr(tmp, "-"))
|
||||
{
|
||||
int len = strtok_date(tmp, "-", mark);
|
||||
if(len == 4)
|
||||
len = strlen(tmp);
|
||||
sdate = strtok_short_date(tmp, "-");
|
||||
if(len == 10)
|
||||
{
|
||||
if(mark == 1)
|
||||
{
|
||||
g_key_file_set_value(config, DATEFORMAT, "SHORT_DATE_FORMAT", "MM-dd-yyyy");
|
||||
}
|
||||
else{
|
||||
g_key_file_set_value(config, DATEFORMAT, "SHORT_DATE_FORMAT", "yyyy-MM-dd");
|
||||
}
|
||||
// if(mark == 1)
|
||||
// {
|
||||
// if(sdate == 4)
|
||||
// {
|
||||
// g_key_file_set_value(config, DATEFORMAT, "SHORT_DATE_FORMAT", "yyyy-MM-dd");
|
||||
// }else{
|
||||
// g_key_file_set_value(config, DATEFORMAT, "SHORT_DATE_FORMAT", "MM-dd-yyyy");
|
||||
// }
|
||||
// }
|
||||
// else{
|
||||
if(sdate == 4)
|
||||
{
|
||||
g_key_file_set_value(config, DATEFORMAT, "SHORT_DATE_FORMAT", "yyyy-MM-dd");
|
||||
}else{
|
||||
g_key_file_set_value(config, DATEFORMAT, "SHORT_DATE_FORMAT", "MM-dd-yyyy");
|
||||
}
|
||||
// }
|
||||
}
|
||||
else if(len == 2){
|
||||
if(mark == 1)
|
||||
{
|
||||
g_key_file_set_value(config, DATEFORMAT, "SHORT_DATE_FORMAT", "M-d-yy");
|
||||
}
|
||||
else{
|
||||
g_key_file_set_value(config, DATEFORMAT, "SHORT_DATE_FORMAT", "yy-M-d");
|
||||
}
|
||||
else {
|
||||
// if(mark == 1)
|
||||
// {
|
||||
// if(sdate == 2)
|
||||
// {
|
||||
// g_key_file_set_value(config, DATEFORMAT, "SHORT_DATE_FORMAT", "yy-M-d");
|
||||
// }else{
|
||||
// g_key_file_set_value(config, DATEFORMAT, "SHORT_DATE_FORMAT", "M-d-yy");
|
||||
// }
|
||||
// }
|
||||
// else{
|
||||
if(sdate == 2)
|
||||
{
|
||||
g_key_file_set_value(config, DATEFORMAT, "SHORT_DATE_FORMAT", "yy-M-d");
|
||||
}else{
|
||||
g_key_file_set_value(config, DATEFORMAT, "SHORT_DATE_FORMAT", "M-d-yy");
|
||||
}
|
||||
// }
|
||||
}
|
||||
}
|
||||
else if(strstr(tmp, "."))
|
||||
{
|
||||
int len = strtok_date(tmp, ".", mark);
|
||||
if(len == 4)
|
||||
len = strlen(tmp);
|
||||
sdate = strtok_short_date(tmp, ".");
|
||||
if(len == 10)
|
||||
{
|
||||
if(mark == 1)
|
||||
{
|
||||
g_key_file_set_value(config, DATEFORMAT, "SHORT_DATE_FORMAT", "MM.dd.yyyy");
|
||||
}
|
||||
else{
|
||||
g_key_file_set_value(config, DATEFORMAT, "SHORT_DATE_FORMAT", "yyyy.MM.dd");
|
||||
}
|
||||
// if(mark == 1)
|
||||
// {
|
||||
// if(sdate == 4)
|
||||
// {
|
||||
// g_key_file_set_value(config, DATEFORMAT, "SHORT_DATE_FORMAT", "yyyy.MM.dd");
|
||||
// }else{
|
||||
// g_key_file_set_value(config, DATEFORMAT, "SHORT_DATE_FORMAT", "MM.dd.yyyy");
|
||||
// }
|
||||
// }
|
||||
// else{
|
||||
if(sdate == 4)
|
||||
{
|
||||
g_key_file_set_value(config, DATEFORMAT, "SHORT_DATE_FORMAT", "yyyy.MM.dd");
|
||||
}else{
|
||||
g_key_file_set_value(config, DATEFORMAT, "SHORT_DATE_FORMAT", "MM.dd.yyyy");
|
||||
}
|
||||
// }
|
||||
}
|
||||
else if(len == 2){
|
||||
if(mark == 1)
|
||||
{
|
||||
g_key_file_set_value(config, DATEFORMAT, "SHORT_DATE_FORMAT", "M.d.yy");
|
||||
}
|
||||
else{
|
||||
g_key_file_set_value(config, DATEFORMAT, "SHORT_DATE_FORMAT", "yy.M.d");
|
||||
}
|
||||
else {
|
||||
// if(mark == 1)
|
||||
// {
|
||||
// if(sdate == 2)
|
||||
// {
|
||||
// g_key_file_set_value(config, DATEFORMAT, "SHORT_DATE_FORMAT", "yy.M.d");
|
||||
// }else{
|
||||
// g_key_file_set_value(config, DATEFORMAT, "SHORT_DATE_FORMAT", "M.d.yy");
|
||||
// }
|
||||
// }
|
||||
// else{
|
||||
if(sdate == 2)
|
||||
{
|
||||
g_key_file_set_value(config, DATEFORMAT, "SHORT_DATE_FORMAT", "yy.M.d");
|
||||
}else{
|
||||
g_key_file_set_value(config, DATEFORMAT, "SHORT_DATE_FORMAT", "M.d.yy");
|
||||
}
|
||||
// }
|
||||
}
|
||||
}
|
||||
g_key_file_save_to_file(config, path, &gerr);
|
||||
|
|
Loading…
Reference in New Issue