Commit Graph

11 Commits

Author SHA1 Message Date
Guido Cella fe9e074752 various: remove trailing whitespace 2022-05-14 14:51:34 +00:00
Kiracus 1e90ec647c osxbundle: use python3 2021-07-17 00:08:54 +02:00
Down Thomas 698a6a2747 osxbundle: simplify process_libraries() to eliminate leafs()
Instead of traversing across leafs() which can lead to an infinite
loop issue with cross-linked libraries, use the dictionary
(libs_dict) created by libraries() to create a set (libs_set) of
every unique library. Every value in libs_dict is also a key in
libs_dict, so every unique library linked to mpv will be a key in
libs_dict. Use set() on libs_dict to return a set of the keys from
libs_dict, and remove binary from the set so that a duplicate of
the binary is not added to the libs directory.

Iterate over libs_set to bundle dylibs while using the libs_dict
to determine which install_names to change.
2019-12-15 12:33:25 +01:00
der richter e3972746dc osxbundle: remove rpath definitions towards dev tools
since the loading order of rpaths is system wide lib path, dev tool path
and then bundle lib path it's possible for the xcode swift libs to be
incompatible with the libs the bundle was build with. this leads to
possible segfaults. if we distribute the bundle we don't want to load
the libs from the dev tools anyway.
2019-09-22 17:07:51 +03:00
der richter f64c0115ae build: fix swift linking with upcoming xcode 11
in xcode 11 the dynamic swift libraries were moved to a separated
versioned swift folder, which can't be used for linking and only for
distribution. additional to the std dynamic swift lib folder the system
wide folder is needed for linking too.
2019-09-22 17:07:51 +03:00
der richter 9a2c760614 osxbundle: bundle the dynamic swift std library when needed 2019-07-21 18:13:07 +03:00
Akemi 8ecd404264 osxbundle: fix bundle creation with python3
there were several problems that had to be fixed because of differences
between python2 to python3:
- subprocess.check_output returned an unicode instead of a string
- filter() returns an iterator instead of a list
- recursion limit was reached

first two were fixed by explicitly converting to the needed type or
using the proper function invocation. third was fixed by changing the
recursive process_libraries function to an iterative one.

Fixes #5600, #3316
2018-03-08 15:41:50 -08:00
Stefano Pigozzi 568a0157ff osxbundle: don't try to package Python
This fixes usage when the bundle is used on the same machine that Python/Cython
was compiled on. It doesn't fix the harder problem of packaging a full Python
installation in the mpv app bundle (and I'm not sure we actually want that).

Fixes #1549
2015-02-02 16:11:11 +01:00
Tsukasa OMOTO 1c850ff559 osxbundle: fix detection of user libraries
Previous code would detect for example `libcaca.0.dylib` as a system library,
because it matched the `libc` condition.
2014-07-16 08:36:34 +02:00
Tsukasa OMOTO 0304c4f92d osxbundle: fix recursion termination
Prevents the binary from being copied over to the lib directory.
2014-05-25 07:42:40 +02:00
Stefano Pigozzi fc4a43d39a osxbundle: split and optimize bundling script
Move the code that copies the dylib's to the bundle to a new script
(dylib-unhell.py) which is called by osxbundle.py.

dylib-unhell is about 20x faster than the previous implementation. This is
accomplished by removing superflous shell-out operations which are kept track
of using an in memory tree of all the needed dependencies. Moreover the
shell-outs have been further optimized by not requiring a complete shell for
every operation and just using subprocess.call (which is equivalent to Popen).
2014-05-09 20:48:15 +02:00