fplll / g6k

The General Sieve Kernel
GNU General Public License v2.0
99 stars 30 forks source link

Problems when installing G6K. #116

Closed zlhlovelattice closed 1 year ago

zlhlovelattice commented 1 year ago

I have some problems installing the G6K library,Here are some steps of my installation: PYTHON=python3 ./boostrap.sh Some problems occurred during this process, the following is part of the intercepted code / no previously-included directories found matching 'build' no previously-included directories found matching 'dist' build/src/fpylll/fplll/enumeration.cpp:2853:21: error: conflicting declaration of ‘bool evaluator_callback_call_obj(PyObject, int, double)’ with ‘C++’ linkage 2853 | __PYX_EXTERN_C bool evaluator_callback_call_obj(PyObject , int, double ); /proto/ | ^~~~~~~ In file included from build/src/fpylll/fplll/enumeration.cpp:1198: build/src/fpylll/fplll/enumeration_callback_helper.h:9:8: note: previous declaration with ‘C’ linkage 9 | bool evaluator_callback_call_obj(PyObject obj, int n, double new_sol_coord); | ^~~~~~~ error: command '/usr/bin/x86_64-linux-gnu-gcc' failed with exit code 1 Requirement already satisfied: Cython in ./g6k-env/lib/python3.8/site-packages (from -r requirements.txt (line 1)) (3.0.0) Requirement already satisfied: cysignals in ./g6k-env/lib/python3.8/site-packages (from -r requirements.txt (line 2)) (1.11.2) / when it finished(with errors),I try to run python -m pytest then it occurs lost of mistakes: ERROR bkz.py - ModuleNotFoundError: No module named 'fpylll' ERROR full_sieve.py - ModuleNotFoundError: No module named 'g6k.siever_params' ERROR hkz.py - ModuleNotFoundError: No module named 'g6k.siever_params' ERROR hkz_maybe.py - ModuleNotFoundError: No module named 'g6k.siever_params' ERROR lwe_challenge.py - ModuleNotFoundError: No module named 'fpylll' ERROR plain_sieve.py - ModuleNotFoundError: No module named 'g6k.siever_params' ERROR svp_challenge.py - ModuleNotFoundError: No module named 'fpylll' ERROR svp_exact.py - ModuleNotFoundError: No module named 'fpylll' ERROR svp_exact_find_norm.py - ModuleNotFoundError: No module named 'fpylll' ERROR examples/all_short_vectors.py - ModuleNotFoundError: No module named 'fpylll' ERROR examples/use_pump.py - ModuleNotFoundError: No module named 'fpylll' ERROR g6k/init.py - ModuleNotFoundError: No module named 'g6k.siever_params' ERROR g6k/algorithms/init.py - ModuleNotFoundError: No module named 'g6k.siever_params' ERROR g6k/algorithms/bkz.py - ModuleNotFoundError: No module named 'g6k.siever_params' ERROR g6k/algorithms/ducas18.py - ModuleNotFoundError: No module named 'g6k.siever_params' ERROR g6k/algorithms/pump.py - ModuleNotFoundError: No module named 'g6k.siever_params' ERROR g6k/algorithms/workout.py - ModuleNotFoundError: No module named 'g6k.siever_params' ERROR g6k/utils/init.py - ModuleNotFoundError: No module named 'g6k.siever_params' ERROR g6k/utils/cli.py - ModuleNotFoundError: No module named 'g6k.siever_params' ERROR g6k/utils/lwe_estimation.py - ModuleNotFoundError: No module named 'g6k.siever_params' ERROR g6k/utils/machine.py - ModuleNotFoundError: No module named 'g6k.siever_params' ERROR g6k/utils/stats.py - ModuleNotFoundError: No module named 'g6k.siever_params' ERROR g6k/utils/util.py - ModuleNotFoundError: No module named 'g6k.siever_params' ERROR tests/test_bkz.py - ModuleNotFoundError: No module named 'fpylll' ERROR tests/test_bkz.py ERROR tests/test_full_sieve.py - ModuleNotFoundError: No module named 'g6k.siever_params' ERROR tests/test_full_sieve.py ERROR tests/test_svp_challenge.py - ModuleNotFoundError: No module named 'fpylll' ERROR tests/test_svp_challenge.py !!!!!!!!!!!!!!!!!!! Interrupted: 29 errors during collection !!!!!!!!!!!!!!!!!!!

I don't know what to do, I have tried many times and it is the same. If you have time, can you help me answer it?

malb commented 1 year ago

This should be fixed (in FPyLLL)

zlhlovelattice commented 1 year ago

Hello Professor, I would like to ask if this problem has been solved? Can I use the powerful G6K library normally?

malb commented 1 year ago

This should be fixed for Python=3.10 now (by hardcoding Cython=0.29.36)