MCPcopy Create free account
hub / github.com/cztomczak/cefpython / create_prebuilt_binaries

Function create_prebuilt_binaries

tools/automate.py:722–870  ·  view source on GitHub ↗

After building copy binaries/libs to build/cef_xxxx/. Not all projects may have been built on all platforms.

()

Source from the content-addressed store, hash-verified

720
721
722def create_prebuilt_binaries():
723 """After building copy binaries/libs to build/cef_xxxx/.
724 Not all projects may have been built on all platforms."""
725
726 # Directories
727 src = Options.cef_binary
728 version_header = os.path.join(src, "include", "cef_version.h")
729 dst = get_prebuilt_name(version_header)
730 dst = os.path.join(Options.build_dir, dst)
731 rmdir(dst)
732 os.makedirs(dst)
733 bindir = os.path.join(dst, "bin")
734 libdir = os.path.join(dst, "lib")
735 os.makedirs(bindir)
736 os.makedirs(libdir)
737
738 # Copy Release/Debug and Resources
739 cpdir(os.path.join(src, Options.build_type), bindir)
740 if not MAC:
741 cpdir(os.path.join(src, "Resources"), bindir)
742
743 # Fix id in CEF framework on Mac (currently it expects Frameworks/ dir)
744 if MAC:
745 new_id = ("@rpath/Chromium Embedded Framework.framework"
746 "/Chromium Embedded Framework")
747 cef_framework_dir = os.path.join(
748 bindir, "Chromium Embedded Framework.framework")
749 cef_library = os.path.join(
750 cef_framework_dir, "Chromium Embedded Framework")
751 assert os.path.isdir(cef_framework_dir)
752 run_command(["install_name_tool", "-id", new_id, cef_library],
753 working_dir=cef_framework_dir)
754
755 # Copy cefclient, cefsimple, ceftests
756
757 # cefclient
758 cefclient = os.path.join(
759 src,
760 "build_cefclient", "tests", "cefclient",
761 Options.build_type,
762 "cefclient" + APP_EXT)
763 if not MAC:
764 assert os.path.exists(cefclient)
765 if LINUX:
766 # On Windows resources/*.html files are embedded inside exe
767 cefclient_files = os.path.join(
768 src,
769 "build_cefclient", "tests", "cefclient",
770 Options.build_type,
771 "cefclient_files")
772 cpdir(cefclient_files, os.path.join(bindir, "cefclient_files"))
773
774 # cefsimple
775 cefsimple = os.path.join(
776 src,
777 "build_cefclient", "tests", "cefsimple",
778 Options.build_type,
779 "cefsimple" + APP_EXT)

Callers 2

build_cefFunction · 0.85
prebuilt_cefFunction · 0.85

Calls 8

get_prebuilt_nameFunction · 0.85
rmdirFunction · 0.85
cpdirFunction · 0.85
run_commandFunction · 0.85
copy_appFunction · 0.85
mvfilesFunction · 0.85
copyMethod · 0.80

Tested by

no test coverage detected