Commit Graph

23752 Commits

Author SHA1 Message Date
rdb 2e7bca90b0 express: fix PointerToArray coercibility regression, fix clear()
This was caused by the assignment operators not being visible to interrogate.
2018-05-24 21:39:54 +02:00
rdb ae8e9d159d tests: add some unit tests for UpdateSeq 2018-05-24 21:39:05 +02:00
rdb 323ddc7d67 putil: fix UpdateSeq::fresh().is_special() return value 2018-05-24 21:37:58 +02:00
rdb 5e0ce969fe Work around clang 3.1 compile error with static constexpr
There is a bug in clang versions before 3.2 (including the one shipped with Xcode) that makes it give a "conflicting types" compile error when there is a static constexpr function defined outside the class.  The way to work around this is either to remove one of the "static" or "constexpr" keywords, or to simply put the definition inline.

See: https://stackoverflow.com/a/17494592/2135754

I would try and upgrade Xcode to version 5 to see if the problem is fixed, but the buildbot still runs OS X Lion (10.7) and the last version of Xcode that works on Lion is 4.6.3, so it seems easier to just apply these workarounds for now.
2018-05-24 14:34:03 +02:00
rdb 8eeab7a26a dxgsg9: fix compile error due to WeakPointerTo changes 2018-05-24 14:26:21 +02:00
rdb 49dfcb09b9 makepanda: refuse building with MSVC versions older than 2015
Panda3D no longer compiles with any version older than Visual Studio 2015 (14.0).

Closes #288
2018-05-23 23:43:36 +02:00
rdb 3077316782 general: use proper deleted funcs instead of stubs with asserts
This gives better compile-time diagnostics and saves on code, while also better communicating intent.
2018-05-23 23:35:27 +02:00
rdb 9fad3dba60 general: remove macros for compatibility with non-C++11 compilers
Now that we require MSVC 2015, we no longer need all this nonsense, so we can write cleaner code.
2018-05-23 23:33:05 +02:00
rdb f45ddcab2f general: switch to C++11 Lockable semantics for mutexes
This renames acquire/release to lock/unlock in order to be compatible with std::lock_guard and std::unique_lock (which will eventually replace the *MutexHolder classes).  It will also allow us to typedef MutexImpl to std::mutex later on.
2018-05-23 20:37:56 +02:00
rdb 3653413cd4 bullet: fix BulletSoftBodyNode::get_node deadlock 2018-05-23 16:55:17 +02:00
rdb 3b4d12cb99 interrogate: also fall back to compare_to in Python 2
This is to create the same behaviour in Python 2 and 3.
2018-05-21 11:55:46 +02:00
rdb 8c80ff1681 Audio3DManager: remove sounds when attached object is deleted
This now uses WeakNodePaths in order to prevent holding a reference to the corresponding nodes.

Closes #145
2018-05-20 18:46:27 +02:00
rdb 941fda6ec3 pgraph: fix comparisons between WeakNodePath and NodePath
Previously it would only work correctly if the WeakNodePath appeared on the left side of the comparison operator.
2018-05-20 15:57:23 +02:00
rdb 14f118b672 pgraph: expose WeakNodePath to Python 2018-05-20 15:56:58 +02:00
rdb 140644d8b6 stdpy: add Python 3 stuff to glob module, remove re dependency 2018-05-20 11:50:32 +02:00
Donny Lawrence 1b3c6fb444 Fix issue with extra flags 2018-05-19 10:30:26 -05:00
Donny Lawrence 8b51b0faeb Merge branch 'cmake' of https://github.com/panda3d/panda3d into cmake 2018-05-17 16:59:04 -05:00
Donny Lawrence beec6578c8 Fix CMake build issues on macOS. 2018-05-17 15:41:31 -05:00
Sam Edwards a3a24f9840 travis: Fix Python test execution 2018-05-16 19:41:15 -06:00
Sam Edwards c62f3d0d23 CMake: Don't set a default Python version.
A blank string to FindPythonInterp finds the version
of Python that the system "python" interpreter invokes,
so this means the default is now the system default.
2018-05-16 18:14:07 -06:00
Sam Edwards 94937dd432 travis: Fix error reporting on failed builds
Apparently after_script is allowed to fail, so just
run the tests inside script.
2018-05-16 18:05:40 -06:00
Sam Edwards d96765b957 CMake: Enhance checkPandaVersion.h
This removes the requirement that it only be included
in a single C++ file per library, by forcing the compiler
to emit the function that references the version symbol
as a weak symbol itself.  Now, the linker will not only
tolerate redundant inclusions, it will also coalesce them
together.
2018-05-16 17:38:13 -06:00
Sam Edwards b08ab6324e CMake: Move panda version logic to dtoolbase 2018-05-16 14:36:31 -06:00
Sam Edwards 9f46d3dc48 CMake: Remove unused LINK_IN_PHYSX 2018-05-15 18:35:22 -06:00
rdb 0bb81a43c9 express: make a thread safe weak pointer implementation (#321)
To access a WeakPointerTo in a thread-safe way, use something like this:

    if (auto ptr = weak_ptr.lock()) {
      ..use ptr as regular PointerTo
    }

The new implementation no longer needs a reference to be stored to all weak pointers on the WeakReferenceList; a mere count of weak pointers is sufficient.  Therefore, callbacks theoretically no longer require a WeakPointerTo to be constructed.

The WeakPointerTo class is not actually atomic; it could be made so, but I don't believe it's worth it at this time.
2018-05-15 13:40:21 +02:00
Sam Edwards 62e335a801 CMake: Update for upstream changes 2018-05-14 19:20:44 -06:00
Sam Edwards 6efb07de93 Merge branch 'master' into cmake 2018-05-14 19:09:14 -06:00
Sam Edwards aeeabdbd3b CMake: Move interrogatedb interrogation to p3interrogatedb 2018-05-14 19:07:27 -06:00
Sam Edwards 538c615abe CMake: Light tidying in Interrogate.cmake 2018-05-14 19:07:27 -06:00
Sam Edwards 8e230495a1 CMake: Consolidate "module or static" library logic 2018-05-14 19:07:27 -06:00
Sam Edwards d2d5e3014c CMake: Generate, don't use, pydtool.cxx 2018-05-14 19:07:27 -06:00
Sam Edwards 47f7d3f297 general: Add headers explaining the renamed config_*.h 2018-05-14 02:36:42 -06:00
Sam Edwards c81229c1a8 pfmprogs: Rename config_pfm to config_pfmprogs 2018-05-14 02:36:42 -06:00
Sam Edwards 52e7c952b3 putil: Rename config_util to config_putil 2018-05-14 02:36:42 -06:00
Sam Edwards 87c11d8018 pstatclient: Rename config_pstats to config_pstatclient 2018-05-14 02:36:42 -06:00
rdb b6f2919420 deploy-ng: make Tkinter work for Windows non-cross-builds
This is only a temporary solution, since this only supports one platform.  We may have to pack the .tcl files into the panda3d .whl archive.
2018-05-13 23:39:30 +02:00
rdb d00109452a deploy-ng: set __file__ for all frozen modules (using import hooks)
Many thirdparty libraries rely on __file__ being set properly, for example to be able to locate data files, so it is easiest to just set this to something remotely sensible (like the executable path).
2018-05-13 23:37:40 +02:00
rdb 5322811e08 deploy-ng: be lenient when processing DLLs with invalid codepage 2018-05-13 23:35:52 +02:00
rdb ef69e8935f freezer: add mechanism for overriding modules with custom code 2018-05-13 23:35:00 +02:00
rdb f34d4c4851 deploy-ng: add hidden imports for matplotlib 2018-05-13 23:32:46 +02:00
rdb 126f4bc418 deploy-ng: copy over data directories for matplotlib 2018-05-13 23:30:14 +02:00
rdb 229e1a1b1f deploy-ng: fix building a Linux build from Python 2.7 on Windows 2018-05-13 23:26:55 +02:00
rdb e292fedd91 deploy-ng: add .libs directory in .whl to search path
This seems to be a convention imposed by auditwheel and used by numpy.
2018-05-13 22:56:44 +02:00
rdb ea351da50c deploy-ng: fix issue with irrelevant wheels in cache dir being used
This is still not a perfect solution, since eg. the wrong version of a package may still be used if older versions are still in the __whl_cache__ directory.  We may want to look into using pip to resolve the package versions, or do something clever such as automatically remove cached wheels if a newer version of the same package was downloaded.
2018-05-13 22:56:11 +02:00
rdb 6175e79c57 cppparser: fix infinite recursion stack overflow with enum classes 2018-05-06 22:21:24 +02:00
rdb 666591ff48 cppparser: fix compile warnings on MSVC 2018-05-06 22:19:33 +02:00
rdb ed54856e9f makepanda: don't fail building Windows installer if Pmw is missing 2018-05-06 22:18:30 +02:00
Mitchell Stokes bf1b486e5a Merge branch 'master' into deploy-ng 2018-05-06 11:30:01 -07:00
Mitchell Stokes ebe2588a50 Merge branch 'master' into deploy-ng 2018-05-06 11:21:13 -07:00
Mitchell Stokes cb077fcdae deploy-ng: Add panda3d.dist-info to installers 2018-05-06 11:20:19 -07:00