相关疑难解决方法(0)

./configure:/ bin/sh ^ M:糟糕的翻译

我一直在尝试在我的12系统上安装lpng142.对我来说似乎是一个问题.我收到这个错误

[root@localhost lpng142]# ./configure
bash: ./configure: /bin/sh^M: bad interpreter: No such file or directory
[root@localhost lpng142]# 
Run Code Online (Sandbox Code Playgroud)

我该如何解决?该/etc/fstab文件中:

#
# /etc/fstab
# Created by anaconda on Wed May 26 18:12:05 2010
#
# Accessible filesystems, by reference, are maintained under '/dev/disk'
# See man pages fstab(5), findfs(8), mount(8) and/or blkid(8) for more info
#
/dev/mapper/VolGroup-lv_root /                       ext4    defaults        1 1
UUID=ce67cf79-22c3-45d4-8374-bd0075617cc8 /boot                   ext4    
defaults        1 2
/dev/mapper/VolGroup-lv_swap swap                    swap    defaults        0 0
tmpfs                   /dev/shm                tmpfs   defaults        0 0
devpts …
Run Code Online (Sandbox Code Playgroud)

linux bash shell newline

379
推荐指数
13
解决办法
49万
查看次数

127从$返回代码?

返回值127的含义是什么?在UNIX中.

unix process

269
推荐指数
5
解决办法
34万
查看次数

"没有这样的文件或目录"但它存在

我只是想从命令行运行一个可执行文件./arm-mingw32ce-g++,但后来我收到错误信息,

bash: ./arm-mingw32ce-g++: No such file or directory
Run Code Online (Sandbox Code Playgroud)

我正在运行Ubuntu Linux 10.10.ls -l名单

-rwxr-xr-x 1 root root  433308 2010-10-16 21:32 arm-mingw32ce-g++
Run Code Online (Sandbox Code Playgroud)

使用sudo(sudo ./arm-mingw32ce-g++)给出

sudo: unable to execute ./arm-mingw32ce-g++: No such file or directory
Run Code Online (Sandbox Code Playgroud)

我不知道为什么操作系统甚至无法看到文件.有什么想法吗?

shell executable command-line

77
推荐指数
8
解决办法
20万
查看次数

shell脚本是否对编码和行结尾敏感?

我正在Mac上制作NW.js应用程序,并希望通过双击图标以开发模式运行应用程序.第一步,我正在尝试使我的shell脚本工作.

在Windows上使用VSCode(我想获得时间),我run-nw在项目的根目录创建了一个文件,其中包含:

#!/bin/bash

cd "src"
npm install

cd ..
./tools/nwjs-sdk-v0.17.3-osx-x64/nwjs.app/Contents/MacOS/nwjs "src" &
Run Code Online (Sandbox Code Playgroud)

但我得到这个输出:

$ sh ./run-nw

: command not found  
: No such file or directory  
: command not found  
: No such file or directory  

Usage: npm <command>

where <command> is one of:  (snip commands list)

(snip npm help)

npm@3.10.3 /usr/local/lib/node_modules/npm  
: command not found  
: No such file or directory  
: command not found
Run Code Online (Sandbox Code Playgroud)

我真的不明白:

  • 似乎它需要空行作为命令.在我的编辑器(VSCode)我试图替换\r\n\n(以防\r造成了问题),但它改变不了什么.
  • 它似乎找不到文件夹(有或没有dirname指令),或者它可能不知道cd …

bash shell sh

37
推荐指数
4
解决办法
1万
查看次数

标签 统计

shell ×3

bash ×2

command-line ×1

executable ×1

linux ×1

newline ×1

process ×1

sh ×1

unix ×1