Comments (3)
Thanks to the issue since I try to use UnityPack and build the module. In my Windows 64 plateform, the (uint32) should cast to (long long) (It's mentioned in same stackoverflow link) to get the build done.
from decrunch.
Is this still an issue in 0.4.0?
from decrunch.
Still happening with the very latest github master version with python 3.6. And yes, changing the casts on line 2347 and 2369 from (uint32)
to (long long)
fixes it.
sembiance@lostcrag ~/tmp/decrunch $ sudo python setup.py install
running install
running bdist_egg
running egg_info
writing decrunch.egg-info/PKG-INFO
writing dependency_links to decrunch.egg-info/dependency_links.txt
writing top-level names to decrunch.egg-info/top_level.txt
reading manifest template 'MANIFEST.in'
writing manifest file 'decrunch.egg-info/SOURCES.txt'
installing library code to build/bdist.linux-x86_64/egg
running install_lib
running build_ext
building 'decrunch' extension
x86_64-pc-linux-gnu-g++ -pthread -fPIC -Icrunch -I/usr/include/python3.6m -c decrunch.cpp -o build/temp.linux-x86_64-3.6/decrunch.o -std=c++11
x86_64-pc-linux-gnu-g++ -pthread -fPIC -Icrunch -I/usr/include/python3.6m -c crn_decomp.cpp -o build/temp.linux-x86_64-3.6/crn_decomp.o -std=c++11
In file included from crn_decomp.cpp:18:
crunch/crn_decomp.h: In function ‘void* crnd::crnd_malloc(size_t, size_t*)’:
crunch/crn_decomp.h:2347:23: error: cast from ‘crnd::uint8*’ {aka ‘unsigned char*’} to ‘crnd::uint32’ {aka ‘unsigned int’} loses precision [-fpermissive]
2347 | CRND_ASSERT(((uint32)p_new & (CRND_MIN_ALLOC_ALIGNMENT - 1)) == 0);
| ^~~~~
crunch/crn_decomp.h:468:13: note: in definition of macro ‘CRND_ASSERT’
468 | (void)((!!(_exp)) || (crnd::crnd_assert(#_exp, __FILE__, __LINE__), 0))
| ^~~~
crunch/crn_decomp.h: In function ‘void* crnd::crnd_realloc(void*, size_t, size_t*, bool)’:
crunch/crn_decomp.h:2369:23: error: cast from ‘void*’ to ‘crnd::uint32’ {aka ‘unsigned int’} loses precision [-fpermissive]
2369 | CRND_ASSERT(((uint32)p_new & (CRND_MIN_ALLOC_ALIGNMENT - 1)) == 0);
| ^~~~~
crunch/crn_decomp.h:468:13: note: in definition of macro ‘CRND_ASSERT’
468 | (void)((!!(_exp)) || (crnd::crnd_assert(#_exp, __FILE__, __LINE__), 0))
| ^~~~
error: command 'x86_64-pc-linux-gnu-g++' failed with exit status 1
sembiance@lostcrag ~/tmp/decrunch $ x86_64-pc-linux-gnu-g++ --version
x86_64-pc-linux-gnu-g++ (Gentoo 9.1.0-r1 p1.1) 9.1.0
sembiance@lostcrag ~/tmp/decrunch $ python --version
Python 3.6.8
from decrunch.
Related Issues (14)
- cubemaps HOT 1
- Python 3.7 install fails due to Cython-generated cpp file in sdist HOT 1
- ETC2 crunched support HOT 2
- Problem installing on MacOS HOT 2
- mac error
- ERROR: pip install decrunch (Windows 8.1 64-bit) HOT 1
- Unable to install via pip on windows 10
- ‘PyTypeObject’ {aka ‘struct _typeobject’} has no member named ‘tp_print’ on Ubuntu 21.04 HOT 2
- Can't install via pip
- pip install issue HOT 1
- Build still not working on MacOS HOT 1
- AssertionError: decrunch .dist-info directory not found HOT 3
- Malloc.h replaced by stdlib.h while installing HOT 2
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from decrunch.