RfidResearchGroup / homebrew-proxmark3

Homebrew tap containing proxmark3 software/firmware
MIT License
44 stars 19 forks source link

Unable to install latest on Mac OSX v4.18218 #39

Open codyallenn opened 4 months ago

codyallenn commented 4 months ago
/proxmark3/02.make:
  __Py_NoneStruct, referenced from:
      _Pm3PyRun_SimpleFileNoExit in cmdscript.o
      __wrap_delete_pm3 in pm3_pywrap.o
      __wrap_pm3_name_get in pm3_pywrap.o
      _pm3_swigregister in pm3_pywrap.o
      _pm3_swiginit in pm3_pywrap.o
      _SWIG_Python_NewPointerObj in pm3_pywrap.o
      _SWIG_Python_ConvertPtrAndOwn in pm3_pywrap.o
      ...
  __Py_NotImplementedStruct, referenced from:
      _SwigPyObject_richcompare in pm3_pywrap.o
      _SwigPyObject_richcompare in pm3_pywrap.o
clang: error: linker command failed with exit code 1 (use -v to see invocation)
make[1]: *** [proxmark3] Error 1
make: *** [client/all] Error 2
codyallenn commented 4 months ago

Looks like arm-none-eabi-gcc 10.3-2021.10 -> 13.2.0 needs to be updated @iceman1001

iceman1001 commented 4 months ago

Cool,
First some workflow things. Keep one topic per issue.

  1. Seems like python3 devs is missing. If you find the solution , make a PR.

  2. As long as it works with current cross compiler we good. Feel free to make a PR with the updated version.

codyallenn commented 4 months ago

Apologies on the workflow.

Can you clarify - Seems like python3 devs is missing

iceman1001 commented 4 months ago

your first message is showing a lot of python3 lib errors.

codyallenn commented 4 months ago

Copy - I tried fresh install on both Intel & Silicon Mac.

Previous version worked

Edit - also tried compiling locally,make clean && make all fails

aruznieto commented 4 months ago

I´m getting this error too. The update of arm-none-eabi-gcc, should only be change 10.3-2021.10 by 13.2.Rel1?

codyallenn commented 4 months ago

or an issue with python 3.12.2

jtippett commented 4 months ago

I also tried a new install on an M1 mac, Python 3.12.2, and got the same errors. There's no python3-dev needed (i thought?) with a homebrew install, all headers are included in a standard install and present at /opt/homebrew/Frameworks/Python.framework/Headers.

Headed over to the repo proper and building from source, following the instructions, produced the same result.

update: noting that others in previous issues had more success with cmake, i then tried

cmake client/CMakeLists.txt 
cmake --build .

and it blew up on client/src/fido/cbortools.c

iceman1001 commented 4 months ago

this is related to python3 dev libs. Where we are compiling support for python3 inside the pm3 client.
Hence something changed with python3 libs and how to call it.

  __Py_NoneStruct, referenced from:
  __Py_NotImplementedStruct, referenced from
jtippett commented 4 months ago

This seems like it could be relevant? https://docs.brew.sh/Homebrew-and-Python#pep-668-python312-and-virtualenvs

jtippett commented 4 months ago
 brew uninstall --ignore-dependencies python@3.12
 brew reinstall python@3.11 

Fixed the build issue for me (directly from the repo). Trying to install from brew attempts to update python back to the non-working 3.12

codyallenn commented 4 months ago

@jtippett thank you for helping! I followed downgrading to python@3.11

I also saved the proxmark3.rb file locally changing line 20 to depends_on "python@3.11" => :build and got brew to run successfully.

codyallenn commented 4 months ago

@iceman1001 https://github.com/RfidResearchGroup/homebrew-proxmark3/pull/40 to allow builds using brew per recent python@3.12 changes

iceman1001 commented 4 months ago

Nice! In the long run the project would need to be adapted to work with python3.12 and larger. Seemingly there is a breaking change in it.