Fails to build Yaws on Mac OS X 10.9 - macos

I downloaded Yaws 1.98, but when executing ./configure && make if fails with the message provided below:
gcc -c -g -O2 -I/usr/include/security -m64 -I/usr/include/pam -DHAVE_SENDFILE -I"/usr/local/lib/erlang/usr/include" -I/usr/include/pam/ epam.c
epam.c:2:10: fatal error: 'pam_appl.h' file not found
#include <pam_appl.h>
^
1 error generated.
make[1]: *** [epam.o] Error 1
make: *** [all] Error 1
Any suggestions on how to solve this? is there any other way I can run the latest version of Yaws on Mac OS X 10.9?

The pam_appl.h include file is normally found in /usr/include/security on OS X 10.6 and higher, and that's installed as part of the Command Line Tools installation. Normally you would run sudo xcode-select --install from your Terminal command line to install the command line tools, but that sometimes fails — see Failed to install command line tools on OSX Mavericks for details and workarounds. Of course, you can always download the command line tools install package from Apple's Developer site (registration required).
Since your error message shows you already have gcc, be aware that it's also installed as part of the command line tools installation.

This shows that pam development library is not available in you mac OS for YAWS to get compiled successfully.
I do not have experience in installing pam-devel in mac but on unix based machine yum install pam-devel would help me installing. Please check if something helps here http://www.webmin.com/udownload.html

Related

How to install OS X 10.12 command line tools on 10.11?

I get this error when trying to brew install geckodriver
==> Installing geckodriver dependency: rust
==> Downloading https://static.rust-lang.org/dist/rustc-1.42.0-src.tar.gz
######################################################################## 100.0%
==> ./configure --prefix=/usr/local/Cellar/rust/1.42.0 --release-channel=stable
==> make
Last 15 lines from /Users/nilshaus/Library/Logs/Homebrew/rust/02.make:
2020-04-12 21:13:48 -0400
make
make: error: unable to find utility "make", not a developer tool or in PATH
xcodebuild: error: SDK "/Library/Developer/CommandLineTools/SDKs/MacOSX10.12.sdk" cannot be located.
clang: error: unable to find utility "clang", not a developer tool or in PATH
Do not report this issue to Homebrew/brew or Homebrew/core!
These open issues may also help:
Rust dependents that currently fail to build from source https://github.com/Homebrew/homebrew-core/issues/50815
Error: You are using macOS 10.11.
We (and Apple) do not provide support for this old version.
You will encounter build failures with some formulae.
Please create pull requests instead of asking for help on Homebrew's GitHub,
Discourse, Twitter or IRC. You are responsible for resolving any issues you
experience while you are running this old version.
Obviously 10.11 is no longer supported by Homebrew. The fact that it can't find make is weird, but I'm willing to bet that the real issue is that the rust build expects the 10.12 command line tools. Is there a way for me to install them on OS X 10.11? I have Xcode 8.
I encountered this same error message when brew upgrade installed a new version of clang and tcl-tk. Found a workaround here:
Xcode was overriding the command line tools install. After moving
Xcode to the trash I found the directory of the command line tools
install:
clang --version
/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin
/Library/Developer/CommandLineTools/usr/bin
https://github.com/pytorch/pytorch/issues/1139#issuecomment-302967251
Another possible workaround - instead of moving Xcode, choose one of the following to specify CLT version:
sudo xcode-select -s /Library/Developer/CommandLineTools
sudo xcode-select -s /Applications/Xcode.app/Contents/Developer
To display the current CLT path: xcode-select -p
https://github.com/pytorch/pytorch/issues/1139#issuecomment-303033942

How do I fix `ld: unexpected token: !tapi-tbd-v3 file` with gfortran on my Mac?

I keep getting this error whenever I try and compile a .f90 file on my Mac Mojave (10.14)
collect2: fatal error: ld terminated with signal 11 [Segmentation fault: 11]
compilation terminated.
ld: unexpected token: !tapi-tbd-v3 file
'/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/lib/libSystem.tbd' for architecture x86_64
I've tried uninstalling Xcode and command line tools multiple times as well as created a symlink to the *tbd file so it doesn't require the tbd files anymore. I've also tried deleting gfortran from my laptop and reinstalling it again but it's still not working.
I don't really know how to go about fixing this problem and I'm also a beginner at this compiler/linker topic. Any help would be greatly appreciated.
In case you installed gfortran via MacPorts, please uninstall it and install the xcode variant of the ld64 port:
sudo port install ld64 +ld64_xcode
After this, install gcc (version N) with -s to build it on your local machine:
sudo port install libgcc<N> libgcc
sudo port install -s gcc<N>
Unfortunately, I'm not familiar with solutions not using MacPorts.
After installing macports, the below 2 commands worked for me
sudo port -f activate ld64
sudo port install ld64 +ld64_xcode

Installing gphoto2 on mac os x Yosemite - issue with ./configure

I am trying to install gphoto2 on my macbook pro. I installed the tar.gz from their website and from terminal I cd Downloads and run ./configure as the README file recommends doing. I keep receiving this error:
checking for pkg-config... false
configure: error:
*** Build requires pkg-config
***
*** Possible solutions:
*** - set PKG_CONFIG to where your pkg-config is located
*** - set PATH to include the directory where pkg-config is installed
*** - get it from http://freedesktop.org/software/pkgconfig/ and install it
I have Xcode 6 installed, as well as Command Line tools (tested it by running gcc in terminal). What am I doing wrong? What should I do?
Also, should I install gphoto2 or libgphoto2?
I wouldn't bother faffing around with building it yourself. I would install homebrew from here.
Then you can simply do
brew install gphoto2
and you will also have a decent package manager if you want to install other cool stuff later on - e.g. ImageMagick, gawk, GNU sed, swatch, youtube-downloader, wxWidgets, vips, redis, sox, ffmpeg. To find other cool stuff that can be managed with homebrew just do
brew search

Cannot install command line tools due to out of date xcode-select

For weeks I've been trying to work this out.
When I run bash install_script.sh file as yt-project ( http://yt-project.org/#getyt ) instructs, it outputs this error:
gcc -fPIC -c blocksort.c
make: gcc: No such file or directory
make: *** [blocksort.o] Error 1
I got into contact with someone from the yt-users mailing list who had me check my version of xcode. I ran xcode-select -version and I recieve:
xcode-select version 2003.
This is definitely outdated.
I try to run xcode-select --install to ensure I have CLT, but it only feeds me back the menu of options to input into xcode-select. Nothing occurs.
I installed CLT directly from the developer website, as in Xcode 5.0 and later it is not in Preferences->Downloads. It seemed to install correctly, but it seems that Xcode itself installed incorrectly if I am unable to get a version number higher than 2003.
I tried uninstalling and reinstalling Xcode, but the problems did not change. As per xcode-select --install not running I checked the path on Xcode and it seemed correct. The output of xcodebuild -version is
Error: Can't run /Library/Developer/CommandLineTools/usr/bin/xcodebuild (no such file).
I tried the command listed here Can't install Command Line Tool, "xcode-select --install" doesn't work after confirming that I do not have a /Library/Developer folder.
The path for xcode-select --print-path is
/Library/Developer/CommandLineTools
When I do gcc --version it returns
-bash: gcc: command not found
How do I get the correct xcode-select binary?
I am very amateur at command line and there could be any number of assumptions that are incorrect that I fell into.
Thank you for your help!

Installing openCV 2.4.2 on Mac OS X 10.9 (Mavericks)

I'm trying to install openCV 2.4.2 (not the newest version but stable version compatible with newer OS X according to several sources) on Mac OS X 10.9 (Mavericks). I have tried installing from source and using homebrew but neither works. I get the following error when I try installing it:
build Marieke$ make
[ 25%] Building CXX object modules/ts/CMakeFiles/opencv_ts.dir/src/precomp.cpp.o
In file included from /users/Marieke/Downloads/OpenCV-2.4.2/modules/ts/src/precomp.cpp:1:
In file included from /users/Marieke/Downloads/OpenCV-2.4.2/modules/ts/src/precomp.hpp:2:
In file included from /users/Marieke/Downloads/OpenCV-2.4.2/modules/ts/include/opencv2/ts/ts.hpp:40:
/users/Marieke/Downloads/OpenCV-2.4.2/modules/ts/include/opencv2/ts/ts_gtest.h:1657:13: fatal error:
'tr1/tuple' file not found
# include <tr1/tuple> // NOLINT
^
1 error generated.
make[2]: *** [modules/ts/CMakeFiles/opencv_ts.dir/src/precomp.cpp.o] Error 1
make[1]: *** [modules/ts/CMakeFiles/opencv_ts.dir/all] Error 2
make: *** [all] Error 2
I don't know how to solve this and I have tried several things already (I do now have newest versions of Xcode, cmake, ffmpeg, faac, faad, qt, ...) so if anybody can help me, that would be much appreciated, thanks!
Run the following commands assuming you have brew installed.
brew tap homebrew/science
brew install opencv
Use macports. Once you install macports, just run
sudo port install opencv
at the command prompt.
This other stackoverflow question is mostly correct for how to start using the macports version of opencv in Xcode.
Here are some more up-to-date instructions for using the macports version of OpenCV from Xcode 5:
Create a new Xcode project as OS X Application -> Command Line Tool, etc.
Click the target in the upper left
Click the Build Settings tab
Scroll down to (or search for) the Search Paths section
Under User Header Search Paths add /opt/local/include
Click the Build Phases tab
Click Link Binary with Libraries
Choose the required libraries from /opt/local/lib
At least, add libopencv_core.dylib
If you want pre-set command-line arguments, go to Product -> Scheme -> Edit Scheme (⌘<)
Click the Run tab on the left
Click the Arguments tab
Enter arguments into Arguments Passed on Launch
Done!
You can try to install opencv from homebrew, I met the same problem with cmake in my 10.9 and finally I found the solution from Chris Muktar. Here are the steps:
Make sure xcode-select --install Xcode command line tools 5.0.1 are installed.
Install python using brew - brew install python.
pip update
pip install numpy
brew linkapps
Add export PYTHONPATH=/usr/local/Cellar/opencv/2.4.6.1/lib/python2.7/site-packages:$PYTHONPATH to .bash_profile in your home directory
brew install opencv
In the last step I came across the Error: No available formula for opencv. In this case, you should first run the command brew tap homebrew/science.
Good Luck
This may be related to the current issues with Qt on Mavericks.
See: https://github.com/mxcl/homebrew/pull/23793
I'd try installing the current patched homebrew keg for qt, and then installing opencv:
brew update
brew uninstall opencv
brew uninstall qt
brew install -v https://raw.github.com/cliffrowley/homebrew/patched_qt/Library/Formula/qt.rb --HEAD
brew install opencv
Caution to the wind: the qt build took me about an hour to complete
Thanks for the answers!
I ended up with the following solution: I added #define GTEST_USE_OWN_TR1_TUPLE 1 to ts_gtest.h. Probably not the prettiest solution but I don't need gtest for anything else so it works for me.
You could disable ts module in CMakeCache.txt file:
//Include opencv_ts module into the OpenCV build
BUILD_opencv_ts:BOOL=OFF
I mean that there is no reason to modify existing code.
I think you really need to do a configuration and that is it.
I tried your problems and I think steps are as follow:
open terminal in mac
in the terminal, check you have cmake and ccmake. If not, please type "brew install cmake"
go to your downloaded opencv folder, make a new folder by typing "mkdir build", then "cd build"
in this build folder, check you have gcc and g++ installed.
now, doing configuration by type "ccmake .. -DCMAKE_C_COMPILER=/usr/bin/gcc -DCMAKE_CXX_COMPILER=/usr/bin/g++", type "c" first for configuration then exit by "e" then "g" for generating!
you should be in terminal again now! then please type "make"
type "sudo make install", and now the opencv is installed, check it by type "brew list", and you should see the opencv there
type "brew linkapps"
do a test if you have python, by typing "import cv", and it should be working!

Resources