Can anyone help me to get valgrind work on Mavericks? - valgrind

The latest version of valgrind available is 3.9.0 which supports Mac OS X 10.7. I have Mac OS X 10.9.2. I've just begun learning C programming and I need valgrind before I go any further.
Had anyone successfully ran valgrind on Mavericks??

Check here for the work of Frederic Germain:
https://bugs.kde.org/attachment.cgi?id=85889&action=edit

Related

Which mac os version is working pretty good with Valgrind?

I'm asking that because I was using Bigsur 2 days ago and no available version is currently working with Bigsur, so I downgraded my os to El capitan and I tested all options but no one is working. Today I am using Mojave 10.14.6 and still no version available.. Do you know a mac os version is working fine with valgrind please ? Thank's !
MacOS 10.13 is the last supported in the official git repo.
You should be able to get 10.14 to work with an unofficial clone (look for Louis Brunner on GitHub, there should be a brew recipe as well).
The poor state of affairs is all down to lack of resources. The Valgrind dev team has a fairly high bar to become a submitter. No-one is actively working on macOS. If people want Valgrind on macOS then we (the Valgrind dev team) need someone to step up and make a long term commitment to working on it.
Finally, there is also a significant possibility that macOS will be removed entirely from the official Valgrind repo. This was discussed as a possibility for 3.19. The subject hasn’t been raised for the next release (3.20 due out next month, October 2022).

How to find out in which OS a binary was compiled with terminal?

My application needs to know if a binary was compiled in Mac OS X 10.9 or in an inferior version, like 10.6.8. I don't know if there's a C/Objective-C command which can give me that information, but I'm pretty sure that there is a terminal command which can do this.
Someone have any clue? Thanks in advance.
Your question leaves unclear what exactly you're trying to figure out. The actual OS is irrelevant, but ever since OSX 10.6, 64 bit has been standard. Maybe you want to know which architecture(s) the binary was compiled with (e.g. for the ls binary):
> lipo -info /bin/ls
Non-fat file: /bin/ls is architecture: x86_64

How do I get gcc 4.5 (compiled from source) to work with Objective C|C++ programs on Mac OS X?

Anyone,
I have been unable to compile some packages, like WxWidgets, on Mac OS 10.6.4 using gcc 4.5 (compiled from source, not from MacPorts, Fink, etc. with all default languages and Obj-C++). Typically, when trying to compile against the Foundation framework, I get errors such as the following:
/System/Library/Frameworks/Foundation.framework/Headers/NSObject.h:123:35:error: expected ‘;’ before ‘__attribute__’
/System/Library/Frameworks/Foundation.framework/Headers/NSObject.h:138:1:error: stray ‘#’ in program
/System/Library/Frameworks/Foundation.framework/Headers/NSObject.h:139:1:error: expected ‘=’, ‘,’, ‘;’, ‘asm’ or ‘__attribute__’ before ‘-’ token In file included from main2.m:2:0:
/System/Library/Frameworks/Foundation.framework/Headers/NSString.h:139:63:error: expected ‘;’ before ‘__attribute__’
I'm somewhat somewhat new developing on the Mac (more experience with Linux and Windows). Right now, I don't need to use Objective-C or Objective-C++. It's just getting in the way of being able to compile other packages (though I may want to start using it down the road). If anyone has any thoughts I would appreciate it. Thank you.
You...don't. GNU's GCC is not compatible with Apple's GCC in terms of Objective-C runtime support. You'll get the GNU Objective-C runtime which is the compatibility problem.
My strong suggestion to you is to not use C++0x features until the new standard is...a standard, and not a draft. Don't expect compiler support for draft features on all platforms.
On Lion, I was able to install gcc 4.7 using brew. I don't know if it will work on snow leopard.
You can try to install it from the homebrew-dupes container:
brew install --use-llvm --enable-cxx https://raw.github.com/Homebrew/homebrew-dupes/master/gcc.rb
Compiled gcc 4.7 successfully with c and c++ enabled on Lion.

OCUnit wants me to install Rosetta

I followed the instructions on Unit Testing objective C from Apple: http://developer.apple.com/tools/unittest.html
I installed the latest version of OCUnit, but when I compile, software update starts and tells me I need to install Resetta. What's going on?
Those instructions are outdated. You shouldn't need to install OCUnit at all, it's built into XCode 2.1 and later. Perhaps you downloaded an old PowerPC version?
the iOS Development Guide has a section on Unit Testing that's much more up-to-date.
There's also one for Mac OS X.

Is there anyway to compile mac binaries from a windows machine?

Seems like there wouldn't be, but it would help us out if there was. I wish to pull the source down to a windows server and compile it and have it be the same as if I had pulled the source code down to a mac machine and used xcode on it. Any Ideas?
Reasons: Release Engineering and IT are much more familiar and comfortable on windows, so it would be easier on us, and LaunchD sucks.
Your original question had less detail... I think you are creating more problems than you are solving buy not using a Mac. Is it really that hard to learn to compile under Xcode or type make in the console?
Anyway...
Apple uses a modified version of the GCC C/C++/Objective C compiler with a proprietary runtime library... You could develop using a port of this code to Windows. See GNUStep.Org. This is not binary compatible though but it isn't impossible that you could rebuild it to cross compile to something that was Mac OS X compatible.
Another idea would be to develop using c# .NET and then move the binaries across to Mac OS X and run the binaries using Mono....
None of these options are robust enough to allow you to do this blind without a Macintosh to test and get up and running in the first place.
You can compile cross app with Cocotron but only on Mac
Why do you need launchd? cron works just as well on Mac as it does on Linux, just have a cronjob that does (Extremely simplified version ahead):
cd /my/source/dir
git pull # You are using Git, right?
xcodebuild MyCoolProject.xcodeproj
cp -r build/MyApp.app /the/distribution/folder