Installed GLIB on MacOS using Homebrew but "... GLIB could not be found" - homebrew

I tried to update my glib as part of flex, both installed using Homebrew on 10.14. However, when I config/make my flex project, I get:
*** The glib-config script installed by GLIB could not be found
*** If GLIB was installed in PREFIX, make sure PREFIX/bin is in
*** your path, or set the GLIB_CONFIG environment variable to the
*** full path to glib-config.
I assume the problem is that last bit, so I did...
export GLIB_CONFIG=/usr/local/lib/glib-2.0/include
And get the same error. I also tried adding /glibconfig.h to the end, but that does the same.
Looking in config.log I see a different issue:
configure:1696:10: fatal error: 'glib.h' file not found
I assume the two are related of course, but I'm thinking the root issue is the later. Does anyone know where this file is and what envar it might be using to find it?

Related

LuaRocks LuaSocket failed install

Disclaimer: There is a similar question on here by a different user, but it was never answered. Maybe this time will be different.
I'm attempting to install Copas, but one of the dependencies is LuaSocket. However, when I try to install LuaSocket, I get the following error:
src/wsocket.c: In function 'socket_gaistrerror':
src/wsocket.c:417:14: error: 'ERROR_NOT_ENOUGH_MEMORY' undeclared (first use in this function)
case EAI_MEMORY: return "memory allocation failure";
^
src/wsocket.c:417:14: note: each undeclared identifier is reported only once for each function it appears in
Error: Build error: Failed compiling object src/wsocket.o
I've tried downloading the rockspec and installing it there, I've tried the luarocks site as well as the github site, and I've tried different versions. My Lua compiler is Lua for Windows and Lua version is 5.1. I'm using MinGW for the C compiler. All this is on a Windows 10 laptop.
It seems like it may depend on the version of mingw you are using; this discussion of the same error in curl may help with identifying the issue and the proposed resolution/workaround. From the discussion it looks like adding -DENABLE_INET_PTON=OFF or using MinGW64-w64 v7+ may resolve the issue.
Also, Lua for Windows should already include luasocket, so I'm not sure why it would need to be compiled.

Can't find location of libopencv_core.so.3.4.0 even though program is installed and working perfectly

I installed the openCV library through apt-get. I am trying to install the BGSLibrary and the cmake file tries to find " /usr/local/lib/libopencv_core.so.3.4.0" The script fails and looking manually the folder isn't there. I have tried searching for it and nothing is turning, infact nothing is turning up for openCV, apart from a folder in usr/local/share which only contains a few cmake files and folders about the haar cascade. I don't even know where openCV is installed even though it is working perfectly.
I am using python 2.7 with openCV 3.4.0
Its important to have your cMake report (outputlog file) up to the error reporting included into your question without it a black box is presented. Anyhow.. a shot for the bow below.
Look into your cMake output/log for:
CMakeFiles/Makefile2:123456: recipe for target 'modules/python2/CMakeFiles/opencv_python2.dir/all' failed.
followed by something like:
make[1]: *** [modules/python2/CMakeFiles/opencv_python2.dir/all] Error 2
make[1]: Leaving directory '/tmp/opencv32018MMDD7-12345-abcdefg/opencv-3.4.0/>OS system <'
Makefile:123: recipe for target 'all' failed
make: *** [all] Error 2
Then see if below is showing up:
make[2]: *** No rule to make target '/libpython2.7.so', needed by 'lib/cv2.so'. Stop.
If so you need to check CMake/Modules/FindPythonLibs.cmake
file what to do. Github check here at L30-L35 in the cMake pythonlib file what to do exactly to set python lib path correctly... to prevent a cascade of underlying errors.
...but as no cMake output/log file was given and OS remains undetermined ..its a shot in the dark. Nevertheless, I hope it points you in the right direction how to fix it.

Add packages to yocto host sdk

I'm trying to cross-compile a programme for a Yocto qemu using Yocto's sdk tools. After setting up the sdk and sourcing it, trying to cross-compile the programme fails thusly:
*** Unable to find the ncurses libraries or the
*** required header files.
*** 'make menuconfig' requires the ncurses libraries.
***
*** Install ncurses (ncurses-devel) and try again.
***
So I added ncurses to the IMAGE_INSTALL listing in the image's recipe, the same way I've installed other packages like dropbear, and confirmed that the meta layer that provides these packages was included in the bblayers.conf file. Then
TOOLCHAIN_HOST_TASK += "nativesdk-ncurses nativesdk-ncurses-dev"
was also added to the image's recipe, to tell bitbake to give the host's sdk access to ncurses. I tried adding several variations on nativesdk-ncurses-devel, to more closely match what the error was asking for, but the image was unable to build with it. After that the image and sdk were re-built and re-sourced, but when attempting to cross compile the programme, it still asked for Install ncurses (ncurses-devel) and try again.
So my question is:
How is ncurses added properly to Yocto's host sdk environment? Is there a step I'm missing? Are the ncurses files needed not the same as those found in the meta layer?
Any help would be deeply appreciated.
-Patches
Please add needed package as RDEPENDS_${PN} in nativesdk-packagegroup-sdk-host.bb
https://git.yoctoproject.org/cgit/cgit.cgi/poky/tree/meta/recipes-core/packagegroups/nativesdk-packagegroup-sdk-host.bb

NCO, Library not loaded

I am trying to run the NCO executable ncks in the terminal window. I found that I needed to create a .bashrc file to initially get started in addition to installing NCO from MacPorts. Now when I run ncks I get this error.
dhcp-v219-194:~ mlaf$ ncks
dyld: Library not loaded: #rpath/libssh2.1.dylib
Referenced from: /Users/matthewlaffin/anaconda/bin/ncks
Reason: image not found
Trace/BPT trap: 5
I am new to terminal and NCO but I have read that there could be an error in the path name which results in NCO not being able to find the Library. Does anyone have any insight into how to fix this?
The error message is from (ana)conda, not from MacPorts, because the ncks executable /Users/matthewlaffin/anaconda/bin/ncks is in your (ana)conda directory, and it is trying to find an (ana)conda library that apparently not installed. Not sure why. See this issue for a possible solution.
If you did not have (ana)conda installed, then presumably your default NCO would be from MacPorts, and the MacPorts installation works so long as your PATH and LD_LIBRARY_PATH are correctly set.

Brew cannot link postfix due to /usr/local/lib/libdns.a from bind in macos

I am working on a formula to brew install postfix from source code in the my mac mini. I am able to make the makefiles, make, and make install the software, however brew link can not be completed due to the libdns.a needed to be linked into /usr/local/lib. There is a link in the directory with the same name from bind already installed previously. So, I need to ask for help to resolve the conflict.
Is there any workaround to relocate the link to /usr/local/lib/postfix, /usr/lib, or somewhere else?
Can I ignore the very link and just complete the rest? What will fail?

Resources