This question does not appear to be about a specific programming problem, a software algorithm, or software tools primarily used by programmers. If you believe the question would be on-topic on another Stack Exchange site, you can leave a comment to explain where the question may be able to be answered.
Closed 4 hours ago.
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
接受
或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
发布评论
评论(6)
2024年更新
甚至startxwin也不再存在。 但 XWin 是(请注意,当您尝试查找它时,大写字母对制表符补全不友好!)。
2024 update
Even startxwin is no longer present. But
XWin
is (note the uppercase which is not tab-completion friendly when you're trying to find it!).当您安装 Cygwin 时,您是否安装了完整的软件包集? 默认情况下仅安装可能不包含 X 的基准包。
再次运行 setup.exe 并确保安装了 X11 包。 我只需单击“全部”旁边的小双箭头,直到显示“安装”。 可能您选择了“默认”。
最好进行完整安装,因为我记得过去曾遇到过 Cygwin 依赖项的问题,现在,当我运行“开始”、“所有程序”、“CygWin-X”、“XWin Server”时,它运行良好,打开一个 shell,然后是 'xterm &' 打开另一个外壳。
所以我真的认为你需要安装很多。 您至少可以尝试整个 X11 组(不仅仅是 xinit),但您也可以做很多事情,特别是考虑到您获得的强大命令。
When you installed Cygwin, did you install the full package set? The default is to only install a baseline of packages which may not include X.
Run setup.exe again and ensure the X11 packages are installed. I just click on the little double arrows next to "All" until it says "Install". It may be you chose "Default" instead.
It's better to have a full install since I remember having problems with Cygwin dependencies in the past and now, when I run 'Start', 'All Programs', 'CygWin-X', 'XWin Server', it runs fine, opening up one shell, then 'xterm &' opens another shell.
So I really think you need to install the lot. You could try, at a bare minimum, the whole X11 group (not just xinit) but you may as well do the lot, especially given the powerful commands you get.
我总是运行 Cygwin install 两次...第一次,我只安装默认包,第二次,我安装所有内容。 下载需要很长时间,但通过这种方式,我几乎总是拥有我可能想要的一切。 (我喜欢在 Cygwin 上安装所有内容并且没有冲突,这与某些 Linux 发行版不同,在这些发行版中,有些软件包以不同的方式执行相同的操作,但无法同时安装。但当然 Cygwin 有一个更简单的方法这比完整的操作系统要复杂得多……例如,没有 Cygwin sendmail。)
我明天必须在新机器上安装 Cygwin,所以这个问题让我很害怕。 如果 startx 不工作我就会死。 我希望事实证明您只是丢失了一个包裹。 我强烈建议安装一切。
I always run Cygwin install twice ... the first time, I just install default packages, and the second time, I install EVERYTHING. The download takes forever, but in this way I always have almost everything I could possibly want. (I like how on Cygwin I can install everything and there are no conflicts, unlike some Linux distributions where there are packages that do the same thing in different ways which can't be installed at the same time. But of course Cygwin has an easier job of this than a full OS ... there's no Cygwin sendmail, for example.)
I have to install Cygwin on a new machine tomorrow, so this question freaks me out. I'm going to die if startx isn't working. I hope it turns out that you're just missing a package. I highly recommend installing everything.
谢谢,这对我有一点帮助(了解如何安装xinit)。 那个新的 startx 窗口真的很糟糕,一位朋友帮助我用另一种方式解决了这个问题:从: startxwin.sh 而不是 startx 开始。 然后它看起来就像“旧”的,而且工作得更好。
Thanks, this helped me a bit (finding out about installing xinit). That new startx window was really crappy, a friend helped me solve it in another way: by starting with: startxwin.sh instead of startx. Then it looked like the "old" one, and worked much better.
免责声明:我知道这个答案并不能直接回答您的问题,但它提供了一个很好的选择。
我使用 Cygwin + XMing 运行远程 X 应用程序:
启动我最喜欢的 Cygwin shell ( zsh)
运行 X 程序
就像一个魅力。 最好的部分是 XMing 可以巧妙地将 X 窗口集成到 Windows GUI 中,即每个 X 应用程序都有自己的全右窗口。
Disclaimer: I know this answer does not answer your question directly, but it offers a good alternative.
I use Cygwin + XMing to run remote X applications:
Start my favorite Cygwin shell (zsh)
Run X programs
Works like a charm. The best part is that XMing can neatly integrate X windows into the Windows GUI, i.e. each X app has its own full-right window.
好的,在做了更多研究并得到一位同事的帮助后,我找到了解决问题的方法。
所发生的情况是,虽然 startx 存在,但它现在默认以全屏模式而不是多窗口模式启动 X 服务器。 回想起来,我可能可以将 /etc/X11/xinit/xinitrc 复制到 ~/.xinitrc 并对其进行自定义。 然而,事实证明,X 服务器还有其他更容易修改的启动脚本。 (参见http://x.cygwin.com/docs/ug/using.html.)
在本例中,我使用了脚本 startxwin.bat。 然后,我对 startxwin.bat 进行了一些更改:
有趣的是,通过转到开始 → 程序 → Cygwin-X → Xwin Server,我可以打开 GUI Cygwin X 窗口,而无需打开标准 Cygwin 命令行。 我之前的安装绝对不是这种情况。
我应该补充一点,我在扩展软件包选择后进行了这些更改。 我不只是安装 X11 → xterm,而是遵循 http://x.cygwin.com/docs/ug/setup-cygwin-x-installing.html 并安装:
(这个选择选择了 X11 → xterm 作为必需的包。)虽然我没有看到为什么上面的说明不适用于仅安装 X11 → xterm 和 X11 → xinit 的明显原因,但我没有提出这个理论到了测试阶段,我并不想拆除我当前的装置并重建它来证明我的理论。
我希望这可以帮助其他人避免一些痛苦。
OK, after doing more research and getting help from one of my coworkers, I have found a solution to my problem.
What has happened is that, although startx exists, it now starts the X server in fullscreen mode by default instead of multiwindow mode. Looking back, I probably could have copied /etc/X11/xinit/xinitrc to ~/.xinitrc and customized it. However, it turns out that there are other startup scripts for the X server which are easier to modify. (See http://x.cygwin.com/docs/ug/using.html.)
In this case, I took the script startxwin.bat. I then made a couple of changes to startxwin.bat:
The nifty thing is that by going to Start → Programs → Cygwin-X → Xwin Server, I can open a GUI Cygwin X-window without ever opening the standard Cygwin command line. This was decidedly not the case with my previous installation.
I should add that I made these changes after expanding my selection of packages. Instead of just installing X11 → xterm, I followed the recommendations in step 15 of http://x.cygwin.com/docs/ug/setup-cygwin-x-installing.html and installed:
(This selection picked up X11 → xterm as a required package.) While I see no obvious reason why the directions above wouldn't have worked with just X11 → xterm and X11 → xinit installed, I haven't put that theory to the test, and I have little desire to blow away my current installation and rebuild it to prove my theory.
I hope this helps other people avoid some pain.