标签: macos-mojave

如何解决 lldb 在运行调用后立即停止的问题?

我在 Mojave 上使用 lldb 和 Xcode 10.2.1。一旦命令“运行”到 lldb,就会发生这种情况:

(lldb) target create "<executable>"
Current executable set to '<executable>' (x86_64).
(lldb) run
Process 95857 launched: '/Users/<path to executable>' (x86_64)
Process 95857 stopped
* thread #2, stop reason = exec
    frame #0: 0x0000000102491000 dyld`_dyld_start
dyld`_dyld_start:
->  0x102491000 <+0>: popq   %rdi
    0x102491001 <+1>: pushq  $0x0
    0x102491003 <+3>: movq   %rsp, %rbp
    0x102491006 <+6>: andq   $-0x10, %rsp
Target 0: (pmtad) stopped.
Run Code Online (Sandbox Code Playgroud)

我尝试查找与 dyld`_dyld_start 打印输出相关的问题,因为这是我能想到的唯一线索。我读到这可能与尝试重新运行可执行文件有关,尽管我不太确定所描述的内容。

我应该能跑得这么好。它可以在其他具有较旧操作系统的计算机上运行。

macos lldb macos-mojave

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

系统存储在 macOS Mojave 中占用太多空间

我的 Mac 经常向我发送磁盘空间不足的警报。当我检查系统存储时,显示系统占用了 170+GB。我不确定我的空间在哪里被使用?

我也尝试了一些更清洁的工具,但没有得到太多帮助。

请帮忙解决一下?

在此输入图像描述

macos diskspace macos-mojave

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

我在链接 brew 的 vim 版本时遇到问题

我正在尝试在 Mac OS mojave 中使用 brew 安装 vim,我可以通过在终端中引入整个方向来使用它,但是当我输入vim它时使用默认一个,当我构建它时它显示了这个错误:

==> Pouring vim-8.2.0750.mojave.bottle.tar.gz
Error: The `brew link` step did not complete successfully
The formula built, but is not symlinked into /usr/local
Could not symlink share/man/de/man1/ex.1
/usr/local/share/man/de/man1 is not writable.

You can try again using:
  brew link vim
Run Code Online (Sandbox Code Playgroud)

我尝试链接它并显示此错误:

$ brew link vim
Linking /usr/local/Cellar/vim/8.2.0750... 
Error: Could not symlink share/man/de/man1/ex.1
/usr/local/share/man/de/man1 is not writable.
MacBook-Air-de-Carlos:~ julian$ 
Run Code Online (Sandbox Code Playgroud)

vim homebrew macos-mojave

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

Applescript Mojave 切换辅助功能灰度开/关

我有一个脚本,我定期运行以使用 Applescript 打开/关闭灰度。它在 High Sierra 上运行良好,但在我使用 Mojave 时抛出异常。

tell application "System Preferences"
    reveal anchor "Seeing_Display" of pane id "com.apple.preference.universalaccess"
end tell

tell application "System Events" to tell process "System Preferences"
    delay 0.5 # Needed or else script fails
    set theCheckbox to checkbox "Use grayscale" of window "Accessibility"
    tell theCheckbox
        # If the checkbox is not checked, check it to turn grayscale on
        if not (its value as boolean) then
            set checked to true
            click theCheckbox
        else # else turn grayscale …
Run Code Online (Sandbox Code Playgroud)

applescript macos-mojave

3
推荐指数
1
解决办法
974
查看次数

Mac“中止” OpenCV Python脚本

所以我只是试图运行基本的OpenCV程序

    import numpy as np
    import cv2

    cap = cv2.VideoCapture(0)

    while(True):
        # Capture frame-by-frame
        ret, frame = cap.read()

        # Our operations on the frame come here
        gray = cv2.cvtColor(frame, cv2.COLOR_BGR2BGRA)

        # Display the resulting frame
        cv2.imshow('frame',frame)
        if cv2.waitKey(1) & 0xFF == ord('q'):
            break

    # When everything done, release the capture
    cap.release()
    cv2.destroyAllWindows()
Run Code Online (Sandbox Code Playgroud)

但是由于某种原因,当我尝试运行它(使用python 2或3)时,我得到了这个奇怪的中止语句

    [1]    74309 abort      python3 index.py
Run Code Online (Sandbox Code Playgroud)

(我猜5位数是PID),但是,如果我在VideoCapture函数中传递到现有视频的路径,则它确实可以工作。我是所有这方面的初学者,所以我不确定是什么问题

谢谢 :)

python opencv macos-mojave

3
推荐指数
1
解决办法
2009
查看次数

无法在Mac OS X Mojave上安装mysqlclient

我正在尝试在Mac OS X Mojave上安装mysqlclient:

sudo pip3 install mysqlclient
Run Code Online (Sandbox Code Playgroud)

我收到以下错误:

clang -Wno-unused-result -Wsign-compare -Wunreachable-code -fno-common -dynamic -DNDEBUG -g -fwrapv -O3 -Wall -Wstrict-prototypes -I/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.13.sdk/System/Library/Frameworks/Tk.framework/Versions/8.5/Headers -Dversion_info=(1,3,13,'final',0) -D__version__=1.3.13 -I/usr/local/Cellar/mysql/8.0.12/include/mysql -I/usr/local/Cellar/python3/3.6.4/Frameworks/Python.framework/Versions/3.6/include/python3.6m -c _mysql.c -o build/temp.macosx-10.13-x86_64-3.6/_mysql.o
    clang -bundle -undefined dynamic_lookup build/temp.macosx-10.13-x86_64-3.6/_mysql.o -L/usr/local/Cellar/mysql/8.0.12/lib -lmysqlclient -lssl -lcrypto -o build/lib.macosx-10.13-x86_64-3.6/_mysql.cpython-36m-darwin.so
    ld: library not found for -lssl
    clang: error: linker command failed with exit code 1 (use -v to see invocation)
    error: command 'clang' failed with exit status 1

    ----------------------------------------
Command "/Users//Development/apps/hid_ve/bin/python3.6 -u -c "import setuptools, tokenize;__file__='/private/tmp/pip-install-1mo7e_ok/mysqlclient/setup.py';f=getattr(tokenize, 'open', open)(__file__);code=f.read().replace('\r\n', '\n');f.close();exec(compile(code, …
Run Code Online (Sandbox Code Playgroud)

python macos mysql-connector mysql-python macos-mojave

3
推荐指数
2
解决办法
4513
查看次数

安装nokogiri(1.6.6.2)时发生错误,并且Bundler无法继续

在执行sudo bundle install时,出现以下错误。宝石文件将保留安装在/Users/madhakul/Documents/Inshort/puurna/vendor/cache/ruby/2.3.0/gems/nokogiri-1.6.6.2中进行检查。结果记录到/Users/madhakul/Documents/Inshort/puurna/vendor/cache/ruby/2.3.0/extensions/universal-darwin-18/2.3.0/nokogiri-1.6.6.2/gem_make.out

安装nokogiri(1.6.6.2)时发生错误,并且Bundler无法继续。gem install nokogiri -v '1.6.6.2' --source 'https://rubygems.org/'捆绑前确保成功。

在Gemfile中:roo已解析为2.0.0,具体取决于

在阅读了很少的帮助材料之后,为MacOS 10.14 Mojave安装了开发人员工具,但仍然无法解决问题。

ruby-on-rails nokogiri macos-mojave

3
推荐指数
2
解决办法
750
查看次数

PHP致命错误:允许的内存大小为1073741824字节耗尽(尝试分配16777216字节)

我在Mac Book Pro 上运行了composer install16 GB,我得到了这个

 ??  distributor-portal  composer install                                                                                                       
Loading composer repositories with package information
Updating dependencies (including require-dev)                      
PHP Fatal error:  Allowed memory size of 1073741824 bytes exhausted (tried to allocate 16777216 bytes) in phar:///usr/local/bin/composer/src/Composer/DependencyResolver/Solver.php on line 220

Fatal error: Allowed memory size of 1073741824 bytes exhausted (tried to allocate 16777216 bytes) in phar:///usr/local/bin/composer/src/Composer/DependencyResolver/Solver.php on line 220

Check https://getcomposer.org/doc/articles/troubleshooting.md#memory-limit-errors for more info on how to handle out of memory errors.??  distributor-portal 
Run Code Online (Sandbox Code Playgroud)

哪个php

/usr/local/php5/bin/php
Run Code Online (Sandbox Code Playgroud)

php --version …

php laravel composer-php laravel-5 macos-mojave

3
推荐指数
1
解决办法
1343
查看次数

从python检测macos中的暗模式

我正在编写一个 PyQt 应用程序,我必须添加一个补丁,以便字体在启用暗模式的 macos 上可读:

app = QApplication([])
# Fix for the font colours on macos when running dark mode
if sys.platform == 'darwin':
    p = app.palette()
    p.setColor(QPalette.Base, QColor(101, 101, 101))
    p.setColor(QPalette.ButtonText, QColor(231, 231, 231))
    app.setPalette(p)
main_window = MainWindow()
main_window.show()
app.exec_()
Run Code Online (Sandbox Code Playgroud)

这个补丁的问题是它使 macos 上的灯光模式变得不可读。

有没有办法可以从 python 或通过子进程使用标准 shell 命令检测 macos 上的暗模式?

编辑:从 PyQt 5.12 开始,不再需要暗模式修复。

python macos macos-mojave

3
推荐指数
1
解决办法
1384
查看次数

采取行动的IntelliJ(Webstorm / PyCharm)快捷方式现在打开奇怪的弹出窗口

enter action在Mac上的IntelliJ IDE上,默认的键盘快捷键是:cmd+ shift+ A

当我输入此快捷方式时,会弹出一个奇怪的终端弹出窗口。

奇怪的终端弹出屏幕截图

如何恢复该默认快捷方式正常工作?

keyboard-shortcuts intellij-idea pycharm webstorm macos-mojave

3
推荐指数
1
解决办法
74
查看次数