macports

GDB error message (GCC 4.7) (from macports)

社会主义新天地 提交于 2019-11-28 11:48:17
问题 I have this kind of message when I start gdb : $ gdb a.out GNU gdb 6.3.50-20050815 (Apple version gdb-1708) (Thu Nov 3 21:59:02 UTC 2011) Copyright 2004 Free Software Foundation, Inc. GDB is free software, covered by the GNU General Public License, and you are welcome to change it and/or distribute copies of it under certain conditions. Type "show copying" to see the conditions. There is absolutely no warranty for GDB. Type "show warranty" for details. This GDB was configured as "x86_64-apple

Open CV, image loading issue on Mac OS X

ⅰ亾dé卋堺 提交于 2019-11-28 09:44:15
问题 I think my question is pretty basic. I was trying to get Open CV to install on my OSX Lion. I had followed all the steps recommended on this link http://tilomitra.com/opencv-on-mac-osx/ However, when I run the C++ code recommended on the website in Xcode, it fails to load an image with the cvLoadImage( ) function. I have placed my image in the project folder (as recommended). Here is the code I was running: // Example showing how to read and write images #include <opencv2/opencv.hpp> #include

Negative doubles or floats in Haskell (macports)

a 夏天 提交于 2019-11-28 08:40:43
问题 Why do I get a segmentation fault when I try to show a negative double or float? There is no problem for negative integers. Prelude> let a = 4 Prelude> :t a a :: Integer Prelude> let b = -4 Prelude> b -4 Prelude> :t b b :: Integer Prelude> let c = 5.6 Prelude> :t c c :: Double Prelude> let d = -5.6 Prelude> :t d d :: Double Prelude> show d "-Segmentation fault I tried it various ways, it seems that the number is correctly understood but not shown. Version info: ghci --version The Glorious

mysql running but cannot connect to 127.0.0.1

无人久伴 提交于 2019-11-28 08:32:31
问题 I have installed mysql55-server using macports. I can start the server successfully via: $ sudo launchctl load -w /Library/LaunchDaemons/org.macports.mysql55-server.plist And confirm I am running the correct mysql: $ which mysql /opt/local/lib/mysql55/bin/mysql If I run $mysql , I can connect successfully. If I then run: mysql> show databases; It shows two databases. Using Sequel Pro, I can connect via socket: u: root p: root Socket: /opt/local/var/run/mysql55/mysqld.sock Connects and loads

How to set up libusb on Mac OS X?

放肆的年华 提交于 2019-11-28 07:16:13
I'd like to try to make a user-space device driver using libusb on Mac, but I'm confused where to start. In the SDK installer (which I got from http://www.ellert.se/twain-sane ) it said something about examples which I couldn't find anywhere on my computer. Could anyone please describe how do I set up libusb for development on OS X? May I use Xcode? What should I include in my code? spade78 I tried to install the SDK from the aforementioned website and couldn't find a trace of it once the installer finished. Though I did find some libusb items at /usr/local/Developer/SDKs/MacOSX10.6.sdk/usr

How do I instruct CMake to look for libraries installed by MacPorts?

久未见 提交于 2019-11-28 04:55:17
I'm trying to build some of our software, which was designed to run solely on Linux, on MacOS X. We are using CMake and I installed MacPorts so I could easily get CMake along with some of the third party libraries that we depend on. Now the problem is that CMake doesn't appear to look for libraries from MacPorts by default so several of our targets are disabled as it fails to find the dependencies which are all in /opt/local . How can I instruct CMake to also look for includes and libraries from MacPorts? Christopher Bruns Add /opt/local/lib, and any other likely install paths, to the set of

How do I uninstall python from OSX Leopard so that I can use the MacPorts version?

好久不见. 提交于 2019-11-28 04:34:18
I want to use the macports version of python instead of the one that comes with Leopard. I have both installed: $ which python /usr/bin/python $ which python2.5 /opt/local/bin/python2.5 I also added the following line to my .profile : export PATH=/opt/local/bin:/opt/local/sbin:$PATH Don't. Apple ships various system utilities that rely on the system Python (and particularly the Python "framework" build); removing it will cause you problems. Instead, modify your PATH environ variable in your ~/.bash_profile to put /opt/local/bin first. Use the python_select port to switch python interpreters.

Disable assembler warning “.section __TEXT,__textcoal_nt,coalesced,pure_instructions”

家住魔仙堡 提交于 2019-11-28 03:30:13
问题 When using MacPorts GCC on OS X and enlisting the Clang Integrated Assembler via -Wa,-q , the assembler produces a stream of warnings for each file. A sampling of the warnings is shown below (so many of them, the Stack Overflow editor would not allow me to paste the entire stream). I found LLVM Commit r250349, Stop generating coal sections. Here's the code responsible, but its not clear to me how to disable the warning. + // Issue a warning if the target is not powerpc and Section is a *coal*

std::thread in MacPorts gcc4.5

江枫思渺然 提交于 2019-11-27 23:49:16
问题 I'm trying to compile some software I've been writing in Linux that uses some fancy new C++0x features on my Mac. I used MacPorts to install the gcc45 package, which gave me /opt/local/bin/g++-mp-4.5, however this compiler doesn't want to compile anything in <thread> . Eg I try to compile: //test.cpp #include <thread> int main() { std::thread x; return 0; } and get: bash-3.2$ /opt/local/bin/g++-mp-4.5 -std=c++0x test.cpp test.cpp: In function 'int main()': test.cpp:5:2: error: 'thread' is not

Locate MacPorts package?

主宰稳场 提交于 2019-11-27 21:53:54
问题 I just installed the py27-numpy package via MacPorts and python will not find the module when I use this command: import scipy I used the help('modules') command and the scipy port did not come up. Clearly the path is not configured correctly or MacPorts is not installing in the correct place, but either way, it would solve my problem to know where this package is being installed. Where can I find the path to MacPorts-installed package, py27-scipy? Output of echo $PATH command: /Library