loongson & MySQL 如何处理 /etc/lsb-base-logging.sh: line 72: RUNLEVEL: unbound variable

本文介绍了一种在龙芯电脑上安装MySQL过程中遇到的RUNLEVEL变量未定义的问题及其解决方案。通过手动初始化RUNLEVEL变量,解决了安装过程中出现的错误。
 

在龙芯电脑上安装mysql的时候, 出现错误, 而且使用了编译源码方式也没能成功.

后在网上查到,原来是启动脚本里面的变量没定义而造成的.

 

&&&&&&&&&&&&提示如下&&&&&&&&&&&&

  解压缩后会消耗掉 0B 的额外空间。
  正在设置 mysql-server-5.0 (5.0.51a-24) ...
  /etc/lsb-base-logging.sh: line 72: RUNLEVEL: unbound variable
  invoke-rc.d: init script mysql, action "stop" failed.
&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&

 

 

I had this problem today, I don't believe it's mysql related, and there was no need to do anything with mysql to work around it.

I encountered this today on dist-upgrade of debian sid, in sidux [ http://sidux.com ] run sid.

 

apt-get install -f did not resolve it, dist-upgrade halted on errors no matter what I did.

 

The same exact error, so after poking around a little, and realizing that maybe the error message actually meant what it said, that the RUNLEVEL variable on line 42 was in fact not set.

 

Because I needed the upgrade to finish, I just did a simple hack, like this:

<br />

#<br />

# The first piece is just what it is /lib/lsb/init-functions<br />

# for debian. We probably should supply something else for<br />

# ubuntu.<br />

#<br />

# TODO we need to know whats the next step in the progress<br />

# file and send exit to Splashy before X starts (after setting<br />

# the percentage to the right amount)<br />

#### NOTE: I ADDED THIS RUNLEVEL VARIABLE INITIALIZATION HERE:<br />

RUNLEVEL=''<br />

# int log_end_message (int exitstatus)<br />

log_end_msg () {<br />

# If no arguments were passed, return<br />

[ -z "${1:-}" ] && return 1<br />

 

Adding that RUNLEVEL initiatialization fixed the halt, allowed mysql to finish installing. I want to stress though, this looks like an error in this config file by the, I assume, ubuntu, developer.

I'm not sure what the consequences to this hack are, but since I don't use splashy it's probably not going to be that bad.

Sorry about the extra junk that's a bug with this blog software, not my fault.

 

 

w@w-virtual-machine:~/桌面/cmk/Main/build$ make -- Configuring done (0.0s) -- Generating done (0.0s) -- Build files have been written to: /home/w/桌面/cmk/Main/build [ 50%] Linking CXX executable main /opt/loongson-gnu-toolchain-8.3-x86_64-loongarch64-linux-gnu-rc1.3-1/bin/../lib/gcc/loongarch64-linux-gnu/8.3.0/../../../../loongarch64-linux-gnu/bin/ld: CMakeFiles/main.dir/main.cpp.o: in function `main&#39;: main.cpp:(.text+0x10): undefined reference to `TM1650_Init()&#39; /opt/loongson-gnu-toolchain-8.3-x86_64-loongarch64-linux-gnu-rc1.3-1/bin/../lib/gcc/loongarch64-linux-gnu/8.3.0/../../../../loongarch64-linux-gnu/bin/ld: main.cpp:(.text+0x14): undefined reference to `Display_Init()&#39; /opt/loongson-gnu-toolchain-8.3-x86_64-loongarch64-linux-gnu-rc1.3-1/bin/../lib/gcc/loongarch64-linux-gnu/8.3.0/../../../../loongarch64-linux-gnu/bin/ld: main.cpp:(.text+0x1c): undefined reference to `Display_Change_Brightness(unsigned char)&#39; /opt/loongson-gnu-toolchain-8.3-x86_64-loongarch64-linux-gnu-rc1.3-1/bin/../lib/gcc/loongarch64-linux-gnu/8.3.0/../../../../loongarch64-linux-gnu/bin/ld: main.cpp:(.text+0x60): undefined reference to `uart_init(char const*, int)&#39; /opt/loongson-gnu-toolchain-8.3-x86_64-loongarch64-linux-gnu-rc1.3-1/bin/../lib/gcc/loongarch64-linux-gnu/8.3.0/../../../../loongarch64-linux-gnu/bin/ld: main.cpp:(.text+0xfc): undefined reference to `Show_Num(unsigned short, unsigned char)&#39; /opt/loongson-gnu-toolchain-8.3-x86_64-loongarch64-linux-gnu-rc1.3-1/bin/../lib/gcc/loongarch64-linux-gnu/8.3.0/../../../../loongarch64-linux-gnu/bin/ld: main.cpp:(.text+0x118): undefined reference to `uart_send_time_hex(int, rtc_time*)&#39; collect2: error: ld returned 1 exit status make[2]: *** [CMakeFiles/main.dir/build.make:100:main] 错误 1 make[1]: *** [CMakeFiles/Makefile2:87:CMakeFiles/main.dir/all] 错误 2 make: *** [Makefile:91:all] 错误 2
最新发布
07-23
/opt/loongson-gnu-toolchain-8.3-x86_64-loongarch64-linux-gnu-rc1.3-1/bin/../lib/gcc/loongarch64-linux-gnu/8.3.0/../../../../loongarch64-linux-gnu/bin/ld: cannot find -lgtk-x11-2.0 /opt/loongson-gnu-toolchain-8.3-x86_64-loongarch64-linux-gnu-rc1.3-1/bin/../lib/gcc/loongarch64-linux-gnu/8.3.0/../../../../loongarch64-linux-gnu/bin/ld: cannot find -lgdk-x11-2.0 /opt/loongson-gnu-toolchain-8.3-x86_64-loongarch64-linux-gnu-rc1.3-1/bin/../lib/gcc/loongarch64-linux-gnu/8.3.0/../../../../loongarch64-linux-gnu/bin/ld: cannot find -lpangocairo-1.0 /opt/loongson-gnu-toolchain-8.3-x86_64-loongarch64-linux-gnu-rc1.3-1/bin/../lib/gcc/loongarch64-linux-gnu/8.3.0/../../../../loongarch64-linux-gnu/bin/ld: cannot find -latk-1.0 /opt/loongson-gnu-toolchain-8.3-x86_64-loongarch64-linux-gnu-rc1.3-1/bin/../lib/gcc/loongarch64-linux-gnu/8.3.0/../../../../loongarch64-linux-gnu/bin/ld: cannot find -lcairo /opt/loongson-gnu-toolchain-8.3-x86_64-loongarch64-linux-gnu-rc1.3-1/bin/../lib/gcc/loongarch64-linux-gnu/8.3.0/../../../../loongarch64-linux-gnu/bin/ld: cannot find -lgdk_pixbuf-2.0 /opt/loongson-gnu-toolchain-8.3-x86_64-loongarch64-linux-gnu-rc1.3-1/bin/../lib/gcc/loongarch64-linux-gnu/8.3.0/../../../../loongarch64-linux-gnu/bin/ld: cannot find -lgio-2.0 /opt/loongson-gnu-toolchain-8.3-x86_64-loongarch64-linux-gnu-rc1.3-1/bin/../lib/gcc/loongarch64-linux-gnu/8.3.0/../../../../loongarch64-linux-gnu/bin/ld: cannot find -lpangoft2-1.0 /opt/loongson-gnu-toolchain-8.3-x86_64-loongarch64-linux-gnu-rc1.3-1/bin/../lib/gcc/loongarch64-linux-gnu/8.3.0/../../../../loongarch64-linux-gnu/bin/ld: cannot find -lpango-1.0 /opt/loongson-gnu-toolchain-8.3-x86_64-loongarch64-linux-gnu-rc1.3-1/bin/../lib/gcc/loongarch64-linux-gnu/8.3.0/../../../../loongarch64-linux-gnu/bin/ld: cannot find -lgobject-2.0 /opt/loongson-gnu-toolchain-8.3-x86_64-loongarch64-linux-gnu-rc1.3-1/bin/../lib/gcc/loongarch64-linux-gnu/8.3.0/../../../../loongarch64-linux-gnu/bin/ld: cannot find -lharfbuzz /opt/loongson-gnu-toolchain-8.3-x86_64-loongarch64-linux-gnu-rc1.3-1/bin/../lib/gcc/loongarch64-linux-gnu/8.3.0/../../../../loongarch64-linux-gnu/bin/ld: cannot find -lfontconfig /opt/loongson-gnu-toolchain-8.3-x86_64-loongarch64-linux-gnu-rc1.3-1/bin/../lib/gcc/loongarch64-linux-gnu/8.3.0/../../../../loongarch64-linux-gnu/bin/ld: cannot find -lfreetype /opt/loongson-gnu-toolchain-8.3-x86_64-loongarch64-linux-gnu-rc1.3-1/bin/../lib/gcc/loongarch64-linux-gnu/8.3.0/../../../../loongarch64-linux-gnu/bin/ld: cannot find -lgthread-2.0 /opt/loongson-gnu-toolchain-8.3-x86_64-loongarch64-linux-gnu-rc1.3-1/bin/../lib/gcc/loongarch64-linux-gnu/8.3.0/../../../../loongarch64-linux-gnu/bin/ld: cannot find -lglib-2.0 collect2: error: ld returned 1 exit status make[2]: *** [modules/highgui/CMakeFiles/opencv_highgui.dir/build.make:133:lib/libopencv_highgui.so.4.10.0] 错误 1 make[1]: *** [CMakeFiles/Makefile2:2983:modules/highgui/CMakeFiles/opencv_highgui.dir/all] 错误 2
03-29
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值