Installing Redis on MAC 10.8.5 Not Working! Where is the DMG ? Undefined symbol -?*&! - redis

I am trying to install latest Redis on my Macbook Pro running 10.8.5 After downloading the tar ball, I am invited to make the project ....
Upon typing make:
LINK redis-server
Undefined symbols for architecture x86_64:
I realize Redis is awesome product, but man where is the DMG? I mean, do you realize how easy it is to install mongodb?
For those interested in the gory details on my mac:
unknownb8f6b11c7271:redis-2.8.19 Mac1$ make
cd src && make all
LINK redis-server
Undefined symbols for architecture x86_64:
"___atomic_add_fetch", referenced from:
_zmalloc in zmalloc.o
_zcalloc in zmalloc.o
_zrealloc in zmalloc.o
_zmalloc_used_memory in zmalloc.o
_zmalloc_get_fragmentation_ratio in zmalloc.o
"___atomic_sub_fetch", referenced from:
_zrealloc in zmalloc.o
_zfree in zmalloc.o
ld: symbol(s) not found for architecture x86_64
clang: error: linker command failed with exit code 1 (use -v to see invocation)
make[1]: *** [redis-server] Error 1
make: *** [all] Error 2

The easy way to install Redis on OS X is using Homebrew. Just install it and run:
brew install redis
This command install already compiled binaries to your system.

Do a
make distclean
first. make distclean should fix this by removing the built hiredis.
The next make should build all again.

[make distclean; CC=gcc make ] I use this command . it works for redis 5.0.6

Using Homebrew it is quite easy to install-
brew update
brew install redis
To check
redis-cli ping
if you are getting PONG
Then you are good to go(y)

I had the same problem while compile C++ project with redis api
BUT I'm using g++ to compile while you using cmake.
if one used g++ compile C++ with redis on Mac(M1), one can add
-lhreids
for project compiling.
It would work.

Related

libpng installed via homebrew but not found on Apple Silicon

I have installed the latest libpng via homebrew on my M1 Pro MacBook. When I compile my C++ program using g++ and the flag -lpng, it says:
ld: library not found for -lpng
clang: error: linker command failed with exit code 1 (use -v to see invocation)
make: *** [mp1] Error 1
I used this command pkg-config --cflags --libs libpng , and it tells me this:
-I/opt/homebrew/Cellar/libpng/1.6.39/include/libpng16 -L/opt/homebrew/Cellar/libpng/1.6.39/lib -lpng16
I check these two paths and libraries and libpng.a and libpng16.16.dylib available.
I don't know why I cannot use that flag and any explanation is appriciated in advance.

Pytorch Build from Source gives Error make: *** No rule to make target 'install'. Stop

I am following this guide to build Pytorch from scratch on a Raspberry Pi3B. For some reason, there is an error:
Building wheel torch-1.2.0a0+f13fadd
-- Building version 1.2.0a0+f13fadd
cmake --build . --target install --config Release -- -j 4
make: *** No rule to make target 'install'. Stop.
when I call python3 setup.py build. I am running Python version 3.5 and I am unsure why this seems to be failing.
Recently I encountered this error so after some research, in
https://stackoverflow.com/a/46987554/12164529
someone mentioned something about cache.
Therefore I guess that's because of some CMake cache behavior, so I run this command:
sudo USE_ROCM=1 USE_LMDB=1 USE_OPENCV=1 MAX_JOBS=15 python setup.py clean
And the error went away.
ps. This is my first answer on stackoverflow, and I'm not sure if this is a good one, but I hope it helps people find here.
I solved this problem with reference to this link.
This error happened at my second installation attempt. During the first I forgot to install the c++ compiler and got CMAKE_CXX_COMPILER not found. With a proper compiler installed, the second attempt gave me the "No rule to make target 'install'" error as mentioned in the question.
The problem was solved by removing the build/ directory and re-run python setup.py install.
So it seems this is caused by the cached build information.

gst-browser fails to start

I have just installed gst-browser (VisualGST) through the Canonical Ubuntu repositories, so I tried to start VisualGST by running gst-browser on the command line. However, I am immediately greeted with an error:
a Smalltalk Stream:2: Abandon
a Smalltalk Stream:2: Error occurred while not in byte code interpreter!!
/usr/lib/libgst.so.7(+0x74c97)[0x7fb5fa5d1c97]
/lib/x86_64-linux-gnu/libc.so.6(+0x3ef20)[0x7fb5fa1aaf20]
/lib/x86_64-linux-gnu/libc.so.6(gsignal+0xc7)[0x7fb5fa1aae97]
/lib/x86_64-linux-gnu/libc.so.6(abort+0x141)[0x7fb5fa1ac801]
/usr/lib/libgst.so.7(+0x2c6a6)[0x7fb5fa5896a6]
/usr/lib/x86_64-linux-gnu/libsigsegv.so.2(+0xe3c)[0x7fb5f9f68e3c]
/lib/x86_64-linux-gnu/libc.so.6(+0x3ef20)[0x7fb5fa1aaf20]
/usr/lib/x86_64-linux-gnu/libgobject-2.0.so.0(g_type_check_is_value_type+0x23)[0x7fb5d4e374f3]
/usr/lib/x86_64-linux-gnu/libgtk-x11-2.0.so.0(+0x20785e)[0x7fb5d551185e]
/usr/lib/x86_64-linux-gnu/libgtk-x11-2.0.so.0(gtk_list_store_new+0xa4)[0x7fb5d5436d94]
[1] 14556 abort (core dumped) gst-browser
What is the cause and meaning of the error, and how can I start VisualGST properly?
GNU Smalltalk version: 3.2.5
EDIT:
This appears to be a known issue. There's a bug report from 2012 on Launchpad: Smalltalk browser does not launch.
This appears to to be "known" issue. As I previously guessed the issue was in libraries link(age).
You can solve your issue either by installing - libgtk2.0-dev.
You can find the whole conversation here. Here is an excerpt:
Digging a bit further, I found that the module "gst-gtk-3.2.92.so" is
linked against "libgtk-x11-2.0.so", which is (now?) only provided by
package: gtk2-devel.
Your second option is to compile it from source. On Fedora 27 (again from the discussion and link above):
I'm on Fedora 27 and after a fresh install this gave me a working build:
sudo dnf install gcc git automake bison flex libtool libtool-ltdl-devel libffi-devel libsigsegv-devel cairo-devel gtk2-devel texinfo
git clone git://git.sv.gnu.org/smalltalk.git
cd smalltalk
autoreconf -vi ./configure make
sudo make install
-----------------------
For future referece you can find testing gst-browser gist.

How to install and use libnet in mac os?

I want to program in C with libnet in Mac OS.
When I type in gcc *.o -o network -lnet, there's an error:
library not found for -lnet.
And when I use homebrew install linnet, is says:
Warning: libnet-1.1.6 already installed.
It is the problem of library PATH.Flow the steps to solve this problem.
First, find where you install the library. For my case, the libnet is located in /usr/local/Cellar/libnet/1.1.6.
Second, run /usr/local/Cellar/libnet/1.1.6/bin/libnet-config.
Third, use -L to add the path when you link.
gcc *.o -L/usr/local/Cellar/libnet/1.1.6/lib -lnet.

Newbie issue? gdal install failing: Xcode and or CLT are misconfigured

I've worked out several sets of problems in installing the libraries for working with D3 and geographic data, but every time I just get to another challenge on this yellow brick road. At least it seems that way after slogging through the installs. I've been to the homebew wikis and many webpages of people who document how they do install on real machines, not 'greenroom' machines
Other people have had similar problems, but I can't see a problem that matches this:
Trying to install gdal (on Mac OS X 10,8.4) following the bost.ocks.org/mike/map guide using
brew install gdal and trying to parse all kinds of errors and solutions others have logged.
I get the following error message now when I run brew install gdal:
gcc-4.2 -bundle -undefined dynamic_lookup -arch i386 -arch x86_64 -g build/temp.macosx-10.6-intel-2.7/libxml2-py.o build/temp.macosx-10.6-intel-2.7/libxml.o build/temp.macosx-10.6-intel-2.7/types.o -L/usr/local/Cellar/libxml2/2.9.1/lib -lxml2 -lm -lz -o build/lib.macosx-10.6-intel-2.7/libxml2mod.so
Your Xcode and or CLT are mis-configured. Try some or all of the following:
xcodebuild -license
sudo xcode-select -switch /path/to/Xcode.app
error: command 'gcc-4.2' failed with exit status 1
I ran xcodebuild -license which completed without an error; then retried brew install gdal again and got the same error. So I ran sudo xcode-select -switch /path/to/Xcode.app and got this message, which puts me back at the proverbial square 1:
xcode-select: Error: An error occurred while trying to -switch to '/path/to/Xcode.app'. (No such file or directory).
What does that message mean? What file or directory is the error referring to? This is what I can't find anywhere on stackoverflow.
Thanks much and in advance,
Francis
If you want to install gdal then I recommend KyngChaos' installer. It will put everything in as a framework. This doesn't really answer the specific question you asked but it perhaps gives you what you were trying to achieve (I hope).