ImageMagick - 如何为 MAMP 构建 32 位 Mac 版本?

发布于 2024-09-12 08:38:37 字数 235 浏览 9 评论 0原文

这是一个非常简单的问题:我有一台较旧的 INTEL Mac(32 位),我需要构建一个 32 位版本的 ImageMagick。

我见过一些人在二进制安装过程中尝试使用选项,但我似乎找不到任何有关如何执行此操作的可靠信息!

注意:ImageMagick 在其网页上提供了适用于 Mac OS X 的 64 位版本的二进制文件,但我不确定是否可以在编译过程中将其破解为 32 位版本?

谢谢 - 我真的很困惑!

This is a pretty straight-forward question: I have an older INTEL Mac (32-bit) and I need to build a 32-bit version of ImageMagick.

I've seen some people playing around with options during the binary install, but I can't seem to find any reliable information about how to do this!

NOTE: ImageMagick gives out a 64-bit version of the binaries for Mac OS X on their webpage, but I'm not sure if this can be hacked into a 32-bit version during compiling?

THANK YOU - I'm really stuck on this!

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(2

时光清浅 2024-09-19 08:38:37

问题是 ImageMagick 的网页不直观,这使得我很难弄清楚如何继续 - 我终于在他们的页面上找到了二进制文件并按照以下说明进行安装:

简介:
如果您有一台较旧的 INTEL MacBook - 它可能有 32 位处理器。这是如何使用 ImageMagick 二进制文件将 ImageMagick(Mac OS X 版本)编译为 32 位程序 - 不使用 MACPORTS!

要了解您拥有的处理器,即 32 位或 64 位,请查看此处:
http://support.apple.com/kb/ht3696

要通过 MACPORTS 安装,请查看此处:
http://xentek.net/articles/442/installing -imagemagick-and-imagick-via-macports/

我的电脑:
这适用于我的第一代 INTEL Macbook(你知道的 - 带有 Due Core 处理器的白色笔记本)。

操作系统:
我正在运行 OS X 10.6.4 (Snow Leopard)

安装步骤:
1. 技巧是忽略 ImageMagick 的预打包 MAC OS X 安装包,因为它是在 64 位版本中编译的 - 我们需要 32 位版本!

因此,我们需要在这里获取 UNIX 二进制文件: http://www.imagemagick .org/script/install-source.php#unix

  1. 按照页面的说明,我们下载一个名为 ImageMagick.tar.gz 的文件。 ImageMagick 小组似乎更新了此链接以指向最新版本。

  2. 该文件是一个压缩的 TAR 文件,扩展名为 tar.gz。如果您正在使用 MAMP(就像我一样),那么您可能需要在此文件夹中创建一个名为“ImageMagick”(不带引号“”)的新文件:/Applications/MAMP/bin/。通常我们会将 ImageMagick 安装到此文件夹中 - 但是,因为我们使用二进制文件,所以标准 ./configure / make / make install 模式将简单地将 ImageMagick 默认安装到您在计算机上设置的任何路径中。就我而言,我的默认路径是 USR/LOCAL 文件夹。

注意:如果有人想在这里写下如何直接使用 ./configure 选项,以便 ImageMagick 将安装到 MAMP 文件夹(或其他文件夹)而不是默认路径中,那将非常有帮助!

好吧,回到 MAMP 32 位安装:

  1. 将最近下载的 ImageMagick 二进制副本放入新文件夹中。我使用一个名为 SRC 的文件夹将所有这些文件的中间副本保存在一个位置,以便稍后在不需要时删除/清理它们。

  2. 接下来,通过打开终端来展开压缩文件(在“实用程序”文件夹中查找程序)。

打开 TERMINAL,输入以下内容:

cd path/to/the/ImageMagick/file #navigate to the folder where the file is saved
tar xvfz ImageMagick.tar.gz #expand the tar ball file

您现在应该在 ImageMagick 文件夹中看到一个刚刚展开的新文件夹,名为(例如)“ImageMagick-6.6.3”(注意:更高版本的 ImageMagick 可能有不同的版本号在本文的最后)。现在,该文件夹将被称为 ImageMagick-6.6.3-2 ...

  1. 将上一级移动到该文件夹​​中。

为此,请在终端中输入以下内容:

cd ImageMagick-6.6.3-2 #replace the version number
  1. 现在您将运行标准的 .configure / make / make install 模式 - 您的编译器/系统应该自动将构建配置为您的 32 位环境!

在终端中,您应该位于 ImageMagick-6.6.3 文件夹中。到达那里后,运行这些命令:

sudo ./configure #I use SUDO here just in case your file permissions are messed up...
make  #go get a cup of coffee
make install #go get another cup ...

提示:“#”后面的文本只是我的注释 - 只需忽略 # 以及哈希后面的该行上的文本...

  1. 确保“./configure”“MAKE”和“ MAKE INSTALL”命令完成时没有错误 - 它们应该运行得很好!

然后,您可以使用 TERMINAL 程序运行标准 ImageMagick 测试:

输入以下内容来运行测试:

convert logo: logo.gif
identify logo.gif
display logo.gif

Wholla!您应该会看到 ImageMagick 徽标弹出 - 这意味着 ImageMagick 现在已安装在您的 32 位 MAC OS X 计算机上!

The problem was ImageMagick's un-intuitive webpage that made it a little hard to figure out how to proceed - I finally found the binaries on their page and installed following these directions:

Intro:
If you have an older INTEL MacBook - it might have a 32-bit processor. This is how to compile ImageMagick (Mac OS X version) as a 32-bit program using the ImageMagick binary files - NOT USING MACPORTS!.

To find out what processor you have, i.e. 32-bit or 64-bit, look here:
http://support.apple.com/kb/ht3696

To install via MACPORTS look here:
http://xentek.net/articles/442/installing-imagemagick-and-imagick-via-macports/

My Computer:
This worked on my first-generation INTEL Macbook (you know - the white one with a Due Core processor).

OS:
I'm running OS X 10.6.4 (Snow Leopard)

INSTALL STEPS:
1. The trick is to ignore ImageMagick's pre-packed MAC OS X install package because it's compiled in a 64-bit version - we want a 32-bit version instead!

So, we need to get the UNIX binaries here: http://www.imagemagick.org/script/install-source.php#unix

  1. Following the page's instructions, we download a file called ImageMagick.tar.gz. The ImageMagick group seemingly updates this link to point to the latest version.

  2. The file is a compressed TAR file with the extension tar.gz. If you're using MAMP (like I am) then you might want to create a new file called "ImageMagick" (without the quotation marks "") in this folder: /Applications/MAMP/bin/. Normally we would install ImageMagick into this folder - however, because we're working from the binaries, a standard ./configure / make / make install pattern will simply default install ImageMagick into whatever path you have set up on your computer. In my case, my default path is the USR/LOCAL folder.

NOTE: if somebody wants to write here how to instead direct the ./configure options so that ImageMagick will install into a MAMP folder (or other folder) instead of the default path, that would be really helpful!

Well, back to the MAMP 32-bit install:

  1. Place your recently-downloaded binary copy of ImageMagick in a new folder. I use a folder called SRC to keep all these intermediate copies of files in a place that I can later delete/clean when they are not necessary.

  2. Next, expand the compressed file by opening your TERMINAL (look for the program in the "Utilities" folder).

With TERMINAL open, type the following:

cd path/to/the/ImageMagick/file #navigate to the folder where the file is saved
tar xvfz ImageMagick.tar.gz #expand the tar ball file

You should now see in the ImageMagick folder a new folder that you just expanded, called (for example) "ImageMagick-6.6.3" (NOTE: later versions of ImageMagick might have a different version number written at the end of this). Right now the folder would be called ImageMagick-6.6.3-2 ...

  1. Move one level up into that folder.

To do so, type the following into TERMINAL:

cd ImageMagick-6.6.3-2 #replace the version number
  1. Now you're going to run a standard .configure / make / make install pattern - your compiler/system should automatically configure the build to your 32-bit environment!

In terminal, you should be in the ImageMagick-6.6.3 file folder. Once there, run these commands:

sudo ./configure #I use SUDO here just in case your file permissions are messed up...
make  #go get a cup of coffee
make install #go get another cup ...

HINT: text after the "#" is just my comments - just ignore the # and also the text on that line following the hash...

  1. Make sure the "./configure" "MAKE" and "MAKE INSTALL" commands finish without errors - they should run just fine!

Then, you can run the standard ImageMagick test using your TERMINAL program:

Type this out to run the tests:

convert logo: logo.gif
identify logo.gif
display logo.gif

Wholla! You should see the ImageMagick logo pop up - meaning that ImageMagick is now installed on your 32-bit MAC OS X computer!

等往事风中吹 2024-09-19 08:38:37

谢谢!要将配置指向不同的安装目录,语法为:

./configure --prefix=NEW_PREFIX

其中 NEW_PREFIX 应设置为您的 mamp 安装目录的路径。

thx for this! to point configure to a different installation directory the syntax is:

./configure --prefix=NEW_PREFIX

where NEW_PREFIX should be set to the path of your mamp installation directory.

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文