Unable to install z3 - installation

I'm trying to build Z3 from sources (v. 4.3.1., Nov 2013, z3-89c1785b7322), using make/g++ and Python, with the following results
autoconf -- succeeded
./configure -- succeeded
python scripts/mk_make.py -- error message, given below
Traceback (most recent call last):
File "scripts/mk_make.py", line 20, in <module>
mk_makefile()
File "/home/davidg/z3/scripts/mk_util.py", line 854, in mk_makefile
c.mk_makefile(out)
File "/home/davidg/z3/scripts/mk_util.py", line 666, in mk_makefile
for cppfile in self.src_files():
File "/home/davidg/z3/scripts/mk_util.py", line 659, in src_files
return get_cpp_files(self.ex_dir)
File "/home/davidg/z3/scripts/mk_util.py", line 246, in get_cpp_files
return filter(lambda f: f.endswith('.cpp'), os.listdir(path))
OSError: [Errno 2] No such file or directory: 'examples/c++'
I don't know if that should be a fatal error. Proceeding as if it's not,
cd build
make
seem to succeed, concluding with the message "Z3 was successfully built." The next step
sudo make install
fails with the error
No rule to make target `install`
(There's also no target for 'uninstall'.)
Grateful for any help

Together with the Z3 sources you should have received the examples directory. The configuration fails because it can't find the examples/c++ directory (in which there should be a file called example.cpp). At that point only parts of the Makefile have been written, enough for the main target to succeed, but the install target hasn't been written to the Makefile yet, that's why it fails.

Related

labelImg using with m1 pro issue with pip install pip3 install pyqt5 lxml

I am currently trying to run labelImg on my mac m1pro. When trying to install qt5 with "pip3 install pyqt5 lxml" i get this error message:
`
Collecting PyQt5
Using cached PyQt5-5.15.7.tar.gz (3.2 MB)
Installing build dependencies ... done
Getting requirements to build wheel ... done
Preparing metadata (pyproject.toml) ... error
error: subprocess-exited-with-error
× Preparing metadata (pyproject.toml) did not run successfully.
│ exit code: 1
╰─> [23 lines of output]
Querying qmake about your Qt installation...
Traceback (most recent call last):
File "/Users/romanxaver/miniforge3/lib/python3.9/site-packages/pip/_vendor/pep517/in_process/_in_process.py", line 144, in prepare_metadata_for_build_wheel
hook = backend.prepare_metadata_for_build_wheel
AttributeError: module 'sipbuild.api' has no attribute 'prepare_metadata_for_build_wheel'
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File "/Users/romanxaver/miniforge3/lib/python3.9/site-packages/pip/_vendor/pep517/in_process/_in_process.py", line 351, in <module>
main()
File "/Users/romanxaver/miniforge3/lib/python3.9/site-packages/pip/_vendor/pep517/in_process/_in_process.py", line 333, in main
json_out['return_val'] = hook(**hook_input['kwargs'])
File "/Users/romanxaver/miniforge3/lib/python3.9/site-packages/pip/_vendor/pep517/in_process/_in_process.py", line 148, in prepare_metadata_for_build_wheel
whl_basename = backend.build_wheel(metadata_directory, config_settings)
File "/private/var/folders/wm/t87_jx651gvfm3t05dzg24440000gn/T/pip-build-env-lmy12lan/overlay/lib/python3.9/site-packages/sipbuild/api.py", line 46, in build_wheel
project = AbstractProject.bootstrap('wheel',
File "/private/var/folders/wm/t87_jx651gvfm3t05dzg24440000gn/T/pip-build-env-lmy12lan/overlay/lib/python3.9/site-packages/sipbuild/abstract_project.py", line 87, in bootstrap
project.setup(pyproject, tool, tool_description)
File "/private/var/folders/wm/t87_jx651gvfm3t05dzg24440000gn/T/pip-build-env-lmy12lan/overlay/lib/python3.9/site-packages/sipbuild/project.py", line 601, in setup
self.update(tool)
File "project.py", line 166, in update
sipbuild.exceptions.UserException
[end of output]
note: This error originates from a subprocess, and is likely not a problem with pip.
error: metadata-generation-failed
× Encountered error while generating package metadata.
╰─> See above for output.
`
Does anyone know the solution to this? When i try to install it with brew i get the following error at the point of "make qt5py3":
pyrcc5 -o libs/resources.py resources.qrc /Users/xxx/miniforge3/bin/python3: No module named PyQt5.pyrcc_main make: *** [qt5py3] Error 1
I wanted to install labelImg on my m1pro

Trying get Open MPI to play nicely with Fortran on OS X

I'm trying to run a case for the software ExoPlaSim on my MacBook. While the software is built primarily for Linux, it can run on Mac according to the developer instructions. I'm running a simple default "case" script and I'm getting quite a long chain of errors. I suspect (correct me if I'm wrong) that a major reason for these errors is that Open MPI and Fortran aren't playing nicely. I lack the dev knowledge to troubleshoot this, hence my hope for some help. :)
I think these following errors (end of Terminal output) are perhaps the most salient, and may indicate Fortran/Open MPI problems:
ld: library not found for -lm
collect2: error: ld returned 1 exit status
make: *** [makefile:48: plasim.x] Error 1
ld: library not found for -lm
collect2: error: ld returned 1 exit status
ld: library not found for -lm
collect2: error: ld returned 1 exit status
cp: plasim.x: No such file or directory
cp: ../bin/most_plasim_t21_l10_p2.x: No such file or directory
cp: /Users/[name]/Library/Python/3.9/lib/python/site-packages/exoplasim/plasim/run/most_plasim_t21_l10_p2.x: No such file or directory
Mean Molecular Weight set to 28.9703 g/mol
rm: /Users/[name]/ExoPlaSim_Testing/mymodel_testrun/plasim_restart: No such file or directory
Command '['mpiexec -np 2 most_plasim_t21_l10_p2.x']' returned non-zero exit status 134.
Traceback (most recent call last):
File "/Users/[name]/Library/Python/3.9/lib/python/site-packages/exoplasim/__init__.py", line 796, in _run
subprocess.run([self._exec+self.executable],shell=True,check=True,
File "/usr/local/Cellar/python#3.9/3.9.13_1/Frameworks/Python.framework/Versions/3.9/lib/python3.9/subprocess.py", line 528, in run
raise CalledProcessError(retcode, process.args,
subprocess.CalledProcessError: Command '['mpiexec -np 2 most_plasim_t21_l10_p2.x']' returned non-zero exit status 134.
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File "/Users/[name]/ExoPlaSim_Testing/testing_exoplasim.py", line 4, in <module>
mymodel.run(years=10,crashifbroken=True)
File "/Users/[name]/Library/Python/3.9/lib/python/site-packages/exoplasim/__init__.py", line 389, in run
self._run(**kwargs)
File "/Users/[name]/Library/Python/3.9/lib/python/site-packages/exoplasim/__init__.py", line 876, in _run
self._crash() #Bring in the cleaners
File "/Users/[name]/Library/Python/3.9/lib/python/site-packages/exoplasim/__init__.py", line 1383, in _crash
raise RuntimeError("ExoPlaSim has crashed or begun producing garbage. All working files have been moved to %s_crashed/"%(os.getcwd()+"/"+self.modelname))
RuntimeError: ExoPlaSim has crashed or begun producing garbage. All working files have been moved to /Users/[name]/ExoPlaSim_Testing/mymodel_crashed/
I am using Big Sur 11.5 with compilers GNU Fortran/GCC 11.3.0. I used brew to install Open MPI, and the version I'm running (according to ompi_info command in terminal) is 4.1.4, which I believe should work with Fortran. Open-mpi.org does list some instructions for getting a new version of Open MPI to work on OS-X (see #7: open-mpi.org) though I don't quite understand the directions since it's outside my limited dev knowledge base. I don't know if this is the solution to my problem either.
The script I'm using is the base case script for ExoPlaSim (below) It's python.
import exoplasim as exo
mymodel = exo.Model(workdir="mymodel_testrun",modelname="mymodel",resolution="T21",layers=10,ncpus=8)
mymodel.configure()
mymodel.exportcfg()
mymodel.run(years=100,crashifbroken=True)
mymodel.finalize("mymodel_output")
Please note there should be nothing wrong with this script. It works for other users and is the script the software dev recommends using in testing. I'm looking for configuration/install solutions of the relevant libraries on my Mac. This isn't a problem with the software ExoPlaSim.

Symbol not found in flat namespace '_MQBACK' (Python3.9 - MacOS 12.1 Silicon)

Installing pymqi in a MacOS M1 Pro 12.1 Monterey, Python 3.9.9 in a virtualenv and the usual suspect appeared again:
Traceback (most recent call last):
File "/Users/a.gounaris/.virtualenvs/mxhub39/lib/python3.9/site-packages/pymqi/__init__.py", line 132, in <module>
from . import pymqe # type: ignore
ImportError: dlopen(/Users/a.gounaris/.virtualenvs/mxhub39/lib/python3.9/site-packages/pymqi/pymqe.cpython-39-darwin.so, 0x0002): symbol not found in flat namespace '_MQBACK'
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File "<string>", line 1, in <module>
File "/Users/a.gounaris/.virtualenvs/mxhub39/lib/python3.9/site-packages/pymqi/__init__.py", line 134, in <module>
import pymqe # type: ignore # Backward compatibility
ModuleNotFoundError: No module named 'pymqe'
All paths are in place /opt/mqm/bin:/opt/mqm/samp/bin and Python sees the env variable os.environ['DYLD_LIBRARY_PATH']=='/opt/mqm/lib64'
After reinstalling pymqi with --verbose flag, this warning showed up:
ld: warning: ignoring file /opt/mqm/lib64/libmqic_r.dylib, building for macOS-arm64 but attempting to link with file built for macOS-x86_64
Might be the root cause of the exception symbol not found in flat namespace '_MQBACK' in M1 Pro Silicon platforms ?
It says that ibmqic_r.dylib is ignored.
Would a new release of MacOS Toolkit build for macOS-arm64 solve the issue?
Another option - theoretically speaking - could be to run the build for macOS-x86_64 with Rosetta 2 as suggested in this post, I don't know how to do it..
Any help will be mostly appreciated.

DPDK Compilation Error When Building igb_uio

I am trying to test out the DPDK sample applications in a CentOS 6.4 VM running under KVM, but I can't get DPDK to compile.
When trying to run
make install T=x86_64-default-linuxapp-gcc -n
from DPDK-2.0.0, I get the following output:
[...]
make S=lib/librte_eal/linuxapp -f /home/dpdk-1.6.0r2/lib/librte_eal/linuxapp/Makefile -C /home/dpdk-1.6.0r2/x86_64-default-linuxapp-gcc/build/lib/librte_eal/linuxapp all
[ -d /home/dpdk-1.6.0r2/x86_64-default-linuxapp-gcc/build/lib/librte_eal/linuxapp/igb_uio ] || mkdir -p /home/dpdk-1.6.0r2/x86_64-default-linuxapp-gcc/build/lib/librte_eal/linuxapp/igb_uio
echo "== Build lib/librte_eal/linuxapp/igb_uio"
make S=lib/librte_eal/linuxapp/igb_uio -f /home/dpdk-1.6.0r2/lib/librte_eal/linuxapp/igb_uio/Makefile -C /home/dpdk-1.6.0r2/x86_64-default-linuxapp-gcc/build/lib/librte_eal/linuxapp/igb_uio all
if [ ! -f igb_uio.c ]; then ln -nfs /home/dpdk-1.6.0r2/lib/librte_eal/linuxapp/igb_uio/igb_uio.c . ; fi
if [ ! -f Makefile ]; then ln -nfs /home/dpdk-1.6.0r2/lib/librte_eal/linuxapp/igb_uio/Makefile . ; fi
make -C /lib/modules/2.6.32-358.el6.x86_64/build M=/home/dpdk-1.6.0r2/x86_64-default-linuxapp-gcc/build/lib/librte_eal/linuxapp/igb_uio O=/lib/modules/2.6.32-358.el6.x86_64/build \
CROSS_COMPILE=
make: *** /lib/modules/2.6.32-358.el6.x86_64/build: No such file or directory. Stop.
make[7]: *** [igb_uio.ko] Error 2
make[6]: *** [igb_uio] Error 2
make[5]: *** [linuxapp] Error 2
make[4]: *** [librte_eal] Error 2
make[3]: *** [lib] Error 2
make[2]: *** [all] Error 2
make[1]: *** [x86_64-native-linuxapp-gcc_install] Error 2
make: *** [install] Error 2
I've installed all the required packages specified here:
http://dpdk.org/doc/guides/linux_gsg/sys_reqs.html
and I've seen and attempted the solution here:
Intel DPDK Compilation Error
The issue appears for both DPDK2-0.0 and 1.6.0.
Also, just to make sure; running
ls /lib/modules/2.6.32-358.el6.x86_64/build
returns output:
/lib/modules/2.6.32-358.el6.x86_64/build
so the directory definitely exists..
I've managed to compile DPDK in a CentOS 6.6 KVM on the same host without issue, but this time around I keep getting this error.
Also it does need to be CentOS 6.4, sadly.
Update:
Added verbose output above ^
Just solved it:
I was using kernel version 2.6.32-358.el6.x86_64, and I had to update to version 2.6.32-504.23.4.el6.x86_64 to get rid of this error.
Additionally, I ran into another error after this which included the line
previous definition of ‘skb_set_hash’ was here
This happened because of an issue with the DPDK version I was using (1.6) Trying 2.0 fixed this.
Then I got the following error when running any of the module-related options of the setup.sh script:
Traceback (most recent call last):
File "tools/dpdk_nic_bind.py", line 536, in <module>
main()
File "tools/dpdk_nic_bind.py", line 532, in main
get_nic_details()
File "tools/dpdk_nic_bind.py", line 225, in get_nic_details
dev_lines = check_output(["lspci", "-Dvmmn"]).splitlines()
File "tools/dpdk_nic_bind.py", line 120, in check_output
stderr=stderr).communicate()[0]
File "/usr/lib64/python2.6/subprocess.py", line 642, in __init__
errread, errwrite)
File "/usr/lib64/python2.6/subprocess.py", line 1234, in _execute_child
raise child_exception
OSError: [Errno 2] No such file or directory
THIS error was because I didn't have pciutils installed and the script couldn't find lspci.
Hope this helps anyone else with the same issues.
When compiling the DPDK, you suppose to have dependency packages and besides that you must have kernel headers of the same kernel version. If you don't install kernel headers then "/lib/modules/your-kernel-version/build" folder is invalid otherwise it is valid.

Can't install node 0.8.4 on OSX Mavericks

I need to run node 0.8.4 for a project, but I'm having trouble getting it to install. I've installed nvm in order to run it alongside my current system version of node, but I'm getting an error when I run nvm install 0.8.4:
Node.js configure error: No acceptable C compiler found!
Please make sure you have a C compiler installed on your system and/or
consider adjusting the CC environment variable if you installed
it in a non-standard prefix.
./configure
Node.js configure error: No acceptable C compiler found!
Please make sure you have a C compiler installed on your system and/or
consider adjusting the CC environment variable if you installed
it in a non-standard prefix.
python tools/gyp_node -f make
Traceback (most recent call last):
File "tools/gyp_node", line 58, in <module>
run_gyp(gyp_args)
File "tools/gyp_node", line 18, in run_gyp
rc = gyp.main(args)
File "./tools/gyp/pylib/gyp/__init__.py", line 471, in main
options.circular_check)
File "./tools/gyp/pylib/gyp/__init__.py", line 111, in Load
depth, generator_input_info, check, circular_check)
File "./tools/gyp/pylib/gyp/input.py", line 2378, in Load
depth, check)
File "./tools/gyp/pylib/gyp/input.py", line 430, in LoadTargetBuildFile
includes, depth, check)
File "./tools/gyp/pylib/gyp/input.py", line 384, in LoadTargetBuildFile
build_file_data, PHASE_EARLY, variables, build_file_path)
File "./tools/gyp/pylib/gyp/input.py", line 975, in ProcessVariablesAndConditionsInDict
variables, build_file, 'variables')
File "./tools/gyp/pylib/gyp/input.py", line 982, in ProcessVariablesAndConditionsInDict
expanded = ExpandVariables(value, phase, variables, build_file)
File "./tools/gyp/pylib/gyp/input.py", line 739, in ExpandVariables
' in ' + build_file
KeyError: 'Undefined variable target_arch in /Users/raddevon/.nvm/src/node-v0.8.4/deps/v8/tools/gyp/v8.gyp while loading dependencies of /Users/raddevon/.nvm/src/node-v0.8.4/node.gyp while trying to load /Users/raddevon/.nvm/src/node-v0.8.4/node.gyp'
make: *** [out/Makefile] Error 1
nvm: install v0.8.4 failed!
I first tried to make sure I had the Xcode command line tools installed, and it appears that I do. gcc does work. Any ideas how I can get this working?

Resources