pyroscope 0.5.9-x86_64-linux → 0.5.11-x86_64-linux
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/Gemfile +3 -0
- data/Gemfile.lock +23 -0
- data/ext/rbspy/Cargo.toml +1 -6
- data/ext/rbspy/include/rbspy.h +43 -0
- data/ext/rbspy/src/lib.rs +2 -9
- data/ext/thread_id/Cargo.toml +1 -7
- data/ext/thread_id/include/thread_id.h +17 -0
- data/lib/pyroscope/version.rb +1 -1
- data/lib/rbspy/rbspy.so +0 -0
- data/lib/thread_id/thread_id.so +0 -0
- data/pyroscope.gemspec +27 -2
- metadata +10 -19
- data/elflib/rbspy/manylinux.sh +0 -19
- data/elflib/rbspy/pyproject.toml +0 -7
- data/elflib/rbspy/rbspy/__init__.py +0 -0
- data/elflib/rbspy/setup.cfg +0 -22
- data/elflib/rbspy/setup.py +0 -46
- data/elflib/thread_id/manylinux.sh +0 -19
- data/elflib/thread_id/pyproject.toml +0 -7
- data/elflib/thread_id/setup.cfg +0 -22
- data/elflib/thread_id/setup.py +0 -46
- data/elflib/thread_id/thread_id/__init__.py +0 -0
- data/ext/rbspy/Cargo.lock +0 -2663
- data/ext/thread_id/Cargo.lock +0 -324
- data/scripts/docker.sh +0 -23
- data/scripts/tests/test.rb +0 -59
    
        checksums.yaml
    CHANGED
    
    | @@ -1,7 +1,7 @@ | |
| 1 1 | 
             
            ---
         | 
| 2 2 | 
             
            SHA256:
         | 
| 3 | 
            -
              metadata.gz:  | 
| 4 | 
            -
              data.tar.gz:  | 
| 3 | 
            +
              metadata.gz: e4059fe7eddea5fd86d50698bc90fbbdcaf3016d41da486e86c72878ed2598e4
         | 
| 4 | 
            +
              data.tar.gz: 5edba45dda1546bf8dc60b95d1c4bf8f49569953329215cd367f9c7c5da8cef5
         | 
| 5 5 | 
             
            SHA512:
         | 
| 6 | 
            -
              metadata.gz:  | 
| 7 | 
            -
              data.tar.gz:  | 
| 6 | 
            +
              metadata.gz: c72efe93a4fc7fad4a6fbe8506edf52b2883329cd61a21fd701f6570cc134411085a251eb9f93d00ce164ae8de9341e518e446b6d06e8313060504e379579cf2
         | 
| 7 | 
            +
              data.tar.gz: 27a21f16d7d22d7f42f5e6380d97d742c4ad8652bac0743397a1e5c41e3700376c983e48fa8431dff9de8e159c4507a9effce593f50388bbd9d1d6b2bab7750b
         | 
    
        data/Gemfile
    ADDED
    
    
    
        data/Gemfile.lock
    ADDED
    
    | @@ -0,0 +1,23 @@ | |
| 1 | 
            +
            PATH
         | 
| 2 | 
            +
              remote: .
         | 
| 3 | 
            +
              specs:
         | 
| 4 | 
            +
                pyroscope (0.5.11)
         | 
| 5 | 
            +
                  ffi
         | 
| 6 | 
            +
             | 
| 7 | 
            +
            GEM
         | 
| 8 | 
            +
              remote: https://rubygems.org/
         | 
| 9 | 
            +
              specs:
         | 
| 10 | 
            +
                ffi (1.16.3)
         | 
| 11 | 
            +
                rake (13.2.0)
         | 
| 12 | 
            +
             | 
| 13 | 
            +
            PLATFORMS
         | 
| 14 | 
            +
              ruby
         | 
| 15 | 
            +
              x86_64-linux
         | 
| 16 | 
            +
             | 
| 17 | 
            +
            DEPENDENCIES
         | 
| 18 | 
            +
              bundler
         | 
| 19 | 
            +
              pyroscope!
         | 
| 20 | 
            +
              rake (~> 13.0)
         | 
| 21 | 
            +
             | 
| 22 | 
            +
            BUNDLED WITH
         | 
| 23 | 
            +
               2.5.3
         | 
    
        data/ext/rbspy/Cargo.toml
    CHANGED
    
    | @@ -2,7 +2,7 @@ | |
| 2 2 | 
             
            name = "rbspy"
         | 
| 3 3 | 
             
            version = "0.1.0"
         | 
| 4 4 | 
             
            edition = "2021"
         | 
| 5 | 
            -
            rust-version = "1. | 
| 5 | 
            +
            rust-version = "1.64"
         | 
| 6 6 |  | 
| 7 7 | 
             
            [lib]
         | 
| 8 8 | 
             
            name = "rbspy"
         | 
| @@ -19,8 +19,3 @@ log = "0.4" | |
| 19 19 | 
             
            [build-dependencies]
         | 
| 20 20 | 
             
            cbindgen = "0.20.0"
         | 
| 21 21 |  | 
| 22 | 
            -
            [profile.release]
         | 
| 23 | 
            -
            opt-level= "z"
         | 
| 24 | 
            -
            debug = false
         | 
| 25 | 
            -
            lto = true
         | 
| 26 | 
            -
            codegen-units = 1
         | 
| @@ -0,0 +1,43 @@ | |
| 1 | 
            +
            /* Licensed under Apache-2.0 */
         | 
| 2 | 
            +
             | 
| 3 | 
            +
            #ifndef RBSPY_H_
         | 
| 4 | 
            +
            #define RBSPY_H_
         | 
| 5 | 
            +
             | 
| 6 | 
            +
            /* Generated with cbindgen:0.20.0 */
         | 
| 7 | 
            +
             | 
| 8 | 
            +
            /* Warning, this file is autogenerated by cbindgen. Don't modify this manually. */
         | 
| 9 | 
            +
             | 
| 10 | 
            +
            #include <stdarg.h>
         | 
| 11 | 
            +
            #include <stdbool.h>
         | 
| 12 | 
            +
            #include <stdint.h>
         | 
| 13 | 
            +
            #include <stdlib.h>
         | 
| 14 | 
            +
             | 
| 15 | 
            +
            bool initialize_logging(uint32_t logging_level);
         | 
| 16 | 
            +
             | 
| 17 | 
            +
            bool initialize_agent(const char *application_name,
         | 
| 18 | 
            +
                                  const char *server_address,
         | 
| 19 | 
            +
                                  const char *auth_token,
         | 
| 20 | 
            +
                                  const char *basic_auth_user,
         | 
| 21 | 
            +
                                  const char *basic_auth_password,
         | 
| 22 | 
            +
                                  uint32_t sample_rate,
         | 
| 23 | 
            +
                                  bool detect_subprocesses,
         | 
| 24 | 
            +
                                  bool oncpu,
         | 
| 25 | 
            +
                                  bool report_pid,
         | 
| 26 | 
            +
                                  bool report_thread_id,
         | 
| 27 | 
            +
                                  const char *tags,
         | 
| 28 | 
            +
                                  const char *compression,
         | 
| 29 | 
            +
                                  const char *_report_encoding,
         | 
| 30 | 
            +
                                  const char *tenant_id,
         | 
| 31 | 
            +
                                  const char *http_headers_json);
         | 
| 32 | 
            +
             | 
| 33 | 
            +
            bool drop_agent(void);
         | 
| 34 | 
            +
             | 
| 35 | 
            +
            bool add_thread_tag(uint64_t thread_id, const char *key, const char *value);
         | 
| 36 | 
            +
             | 
| 37 | 
            +
            bool remove_thread_tag(uint64_t thread_id, const char *key, const char *value);
         | 
| 38 | 
            +
             | 
| 39 | 
            +
            bool add_global_tag(const char *key, const char *value);
         | 
| 40 | 
            +
             | 
| 41 | 
            +
            bool remove_global_tag(const char *key, const char *value);
         | 
| 42 | 
            +
             | 
| 43 | 
            +
            #endif /* RBSPY_H_ */
         | 
    
        data/ext/rbspy/src/lib.rs
    CHANGED
    
    | @@ -122,7 +122,7 @@ pub extern "C" fn initialize_agent( | |
| 122 122 | 
             
                report_thread_id: bool,
         | 
| 123 123 | 
             
                tags: *const c_char,
         | 
| 124 124 | 
             
                compression: *const c_char,
         | 
| 125 | 
            -
                 | 
| 125 | 
            +
                _report_encoding: *const c_char,
         | 
| 126 126 | 
             
                tenant_id: *const c_char,
         | 
| 127 127 | 
             
                http_headers_json: *const c_char,
         | 
| 128 128 | 
             
            ) -> bool {
         | 
| @@ -169,11 +169,6 @@ pub extern "C" fn initialize_agent( | |
| 169 169 | 
             
                    .unwrap()
         | 
| 170 170 | 
             
                    .to_string();
         | 
| 171 171 |  | 
| 172 | 
            -
                let report_encoding = unsafe { CStr::from_ptr(report_encoding) }
         | 
| 173 | 
            -
                    .to_str()
         | 
| 174 | 
            -
                    .unwrap()
         | 
| 175 | 
            -
                    .to_string();
         | 
| 176 | 
            -
             | 
| 177 172 | 
             
                let tenant_id = unsafe { CStr::from_ptr(tenant_id) }
         | 
| 178 173 | 
             
                    .to_str()
         | 
| 179 174 | 
             
                    .unwrap()
         | 
| @@ -185,8 +180,6 @@ pub extern "C" fn initialize_agent( | |
| 185 180 | 
             
                    .to_string();
         | 
| 186 181 |  | 
| 187 182 | 
             
                let compression = Compression::from_str(&compression_string);
         | 
| 188 | 
            -
                let report_encoding = ReportEncoding::from_str(&report_encoding)
         | 
| 189 | 
            -
                    .unwrap_or(ReportEncoding::FOLDED);
         | 
| 190 183 |  | 
| 191 184 | 
             
                let pid = std::process::id();
         | 
| 192 185 |  | 
| @@ -206,7 +199,7 @@ pub extern "C" fn initialize_agent( | |
| 206 199 | 
             
                    .backend(rbspy)
         | 
| 207 200 | 
             
                    .func(transform_report)
         | 
| 208 201 | 
             
                    .tags(tags)
         | 
| 209 | 
            -
                    .report_encoding( | 
| 202 | 
            +
                    .report_encoding(ReportEncoding::PPROF);
         | 
| 210 203 |  | 
| 211 204 | 
             
                if auth_token != "" {
         | 
| 212 205 | 
             
                    agent_builder = agent_builder.auth_token(auth_token);
         | 
    
        data/ext/thread_id/Cargo.toml
    CHANGED
    
    | @@ -2,7 +2,7 @@ | |
| 2 2 | 
             
            name = "thread_id"
         | 
| 3 3 | 
             
            version = "0.1.0"
         | 
| 4 4 | 
             
            edition = "2021"
         | 
| 5 | 
            -
            rust-version = "1. | 
| 5 | 
            +
            rust-version = "1.64"
         | 
| 6 6 |  | 
| 7 7 | 
             
            [lib]
         | 
| 8 8 | 
             
            name = "thread_id"
         | 
| @@ -13,9 +13,3 @@ libc = "*" | |
| 13 13 |  | 
| 14 14 | 
             
            [build-dependencies]
         | 
| 15 15 | 
             
            cbindgen = "0.20.0"
         | 
| 16 | 
            -
             | 
| 17 | 
            -
            [profile.release]
         | 
| 18 | 
            -
            opt-level= "z"
         | 
| 19 | 
            -
            debug = false
         | 
| 20 | 
            -
            lto = true
         | 
| 21 | 
            -
            codegen-units = 1
         | 
| @@ -0,0 +1,17 @@ | |
| 1 | 
            +
            /* Licensed under Apache-2.0 */
         | 
| 2 | 
            +
             | 
| 3 | 
            +
            #ifndef RBSPY_H_
         | 
| 4 | 
            +
            #define RBSPY_H_
         | 
| 5 | 
            +
             | 
| 6 | 
            +
            /* Generated with cbindgen:0.20.0 */
         | 
| 7 | 
            +
             | 
| 8 | 
            +
            /* Warning, this file is autogenerated by cbindgen. Don't modify this manually. */
         | 
| 9 | 
            +
             | 
| 10 | 
            +
            #include <stdarg.h>
         | 
| 11 | 
            +
            #include <stdbool.h>
         | 
| 12 | 
            +
            #include <stdint.h>
         | 
| 13 | 
            +
            #include <stdlib.h>
         | 
| 14 | 
            +
             | 
| 15 | 
            +
            uint64_t thread_id(void);
         | 
| 16 | 
            +
             | 
| 17 | 
            +
            #endif /* RBSPY_H_ */
         | 
    
        data/lib/pyroscope/version.rb
    CHANGED
    
    
    
        data/lib/rbspy/rbspy.so
    CHANGED
    
    | Binary file | 
    
        data/lib/thread_id/thread_id.so
    CHANGED
    
    | Binary file | 
    
        data/pyroscope.gemspec
    CHANGED
    
    | @@ -31,8 +31,33 @@ Gem::Specification.new do |s| | |
| 31 31 | 
             
                  #(f == __FILE__) || f.match(%r{\A(?:(?:bin|test|spec|features)/|\.(?:git|travis|circleci)|appveyor)})
         | 
| 32 32 | 
             
                #end
         | 
| 33 33 | 
             
              #end
         | 
| 34 | 
            -
             | 
| 35 | 
            -
             | 
| 34 | 
            +
            #   s.files = `git ls-files -z`.split("\0").reject { |f| f =~ /^(\.|G|spec|Rakefile)/ }
         | 
| 35 | 
            +
              s.files = [
         | 
| 36 | 
            +
                "Gemfile",
         | 
| 37 | 
            +
                "Gemfile.lock",
         | 
| 38 | 
            +
                "LICENSE",
         | 
| 39 | 
            +
            #     "Makefile",
         | 
| 40 | 
            +
                "README.md",
         | 
| 41 | 
            +
            #     "Rakefile",
         | 
| 42 | 
            +
                "ext/rbspy/Cargo.toml",
         | 
| 43 | 
            +
                "ext/rbspy/Rakefile",
         | 
| 44 | 
            +
                "ext/rbspy/build.rs",
         | 
| 45 | 
            +
                "ext/rbspy/cbindgen.toml",
         | 
| 46 | 
            +
                "ext/rbspy/extconf.rb",
         | 
| 47 | 
            +
                "ext/rbspy/include/rbspy.h",
         | 
| 48 | 
            +
                "ext/rbspy/src/lib.rs",
         | 
| 49 | 
            +
                "ext/thread_id/Cargo.toml",
         | 
| 50 | 
            +
                "ext/thread_id/Rakefile",
         | 
| 51 | 
            +
                "ext/thread_id/build.rs",
         | 
| 52 | 
            +
                "ext/thread_id/cbindgen.toml",
         | 
| 53 | 
            +
                "ext/thread_id/extconf.rb",
         | 
| 54 | 
            +
                "ext/thread_id/include/thread_id.h",
         | 
| 55 | 
            +
                "ext/thread_id/src/lib.rs",
         | 
| 56 | 
            +
                "lib/pyroscope.rb",
         | 
| 57 | 
            +
                "lib/pyroscope/version.rb",
         | 
| 58 | 
            +
                "pyroscope.gemspec",
         | 
| 59 | 
            +
            #     "scripts/tests/test.rb",
         | 
| 60 | 
            +
              ]
         | 
| 36 61 | 
             
              s.platform = Gem::Platform::RUBY
         | 
| 37 62 |  | 
| 38 63 | 
             
              s.required_ruby_version = ">= 1.9.3"
         | 
    
        metadata
    CHANGED
    
    | @@ -1,14 +1,14 @@ | |
| 1 1 | 
             
            --- !ruby/object:Gem::Specification
         | 
| 2 2 | 
             
            name: pyroscope
         | 
| 3 3 | 
             
            version: !ruby/object:Gem::Version
         | 
| 4 | 
            -
              version: 0.5. | 
| 4 | 
            +
              version: 0.5.11
         | 
| 5 5 | 
             
            platform: x86_64-linux
         | 
| 6 6 | 
             
            authors:
         | 
| 7 7 | 
             
            - Pyroscope Team
         | 
| 8 | 
            -
            autorequire: | 
| 8 | 
            +
            autorequire:
         | 
| 9 9 | 
             
            bindir: bin
         | 
| 10 10 | 
             
            cert_chain: []
         | 
| 11 | 
            -
            date:  | 
| 11 | 
            +
            date: 2024-04-08 00:00:00.000000000 Z
         | 
| 12 12 | 
             
            dependencies:
         | 
| 13 13 | 
             
            - !ruby/object:Gem::Dependency
         | 
| 14 14 | 
             
              name: ffi
         | 
| @@ -24,6 +24,7 @@ dependencies: | |
| 24 24 | 
             
                - - ">="
         | 
| 25 25 | 
             
                  - !ruby/object:Gem::Version
         | 
| 26 26 | 
             
                    version: '0'
         | 
| 27 | 
            +
              force_ruby_platform: false
         | 
| 27 28 | 
             
            - !ruby/object:Gem::Dependency
         | 
| 28 29 | 
             
              name: bundler
         | 
| 29 30 | 
             
              requirement: !ruby/object:Gem::Requirement
         | 
| @@ -59,39 +60,29 @@ executables: [] | |
| 59 60 | 
             
            extensions: []
         | 
| 60 61 | 
             
            extra_rdoc_files: []
         | 
| 61 62 | 
             
            files:
         | 
| 63 | 
            +
            - Gemfile
         | 
| 64 | 
            +
            - Gemfile.lock
         | 
| 62 65 | 
             
            - LICENSE
         | 
| 63 66 | 
             
            - README.md
         | 
| 64 | 
            -
            - elflib/rbspy/manylinux.sh
         | 
| 65 | 
            -
            - elflib/rbspy/pyproject.toml
         | 
| 66 | 
            -
            - elflib/rbspy/rbspy/__init__.py
         | 
| 67 | 
            -
            - elflib/rbspy/setup.cfg
         | 
| 68 | 
            -
            - elflib/rbspy/setup.py
         | 
| 69 | 
            -
            - elflib/thread_id/manylinux.sh
         | 
| 70 | 
            -
            - elflib/thread_id/pyproject.toml
         | 
| 71 | 
            -
            - elflib/thread_id/setup.cfg
         | 
| 72 | 
            -
            - elflib/thread_id/setup.py
         | 
| 73 | 
            -
            - elflib/thread_id/thread_id/__init__.py
         | 
| 74 | 
            -
            - ext/rbspy/Cargo.lock
         | 
| 75 67 | 
             
            - ext/rbspy/Cargo.toml
         | 
| 76 68 | 
             
            - ext/rbspy/Rakefile
         | 
| 77 69 | 
             
            - ext/rbspy/build.rs
         | 
| 78 70 | 
             
            - ext/rbspy/cbindgen.toml
         | 
| 79 71 | 
             
            - ext/rbspy/extconf.rb
         | 
| 72 | 
            +
            - ext/rbspy/include/rbspy.h
         | 
| 80 73 | 
             
            - ext/rbspy/src/lib.rs
         | 
| 81 | 
            -
            - ext/thread_id/Cargo.lock
         | 
| 82 74 | 
             
            - ext/thread_id/Cargo.toml
         | 
| 83 75 | 
             
            - ext/thread_id/Rakefile
         | 
| 84 76 | 
             
            - ext/thread_id/build.rs
         | 
| 85 77 | 
             
            - ext/thread_id/cbindgen.toml
         | 
| 86 78 | 
             
            - ext/thread_id/extconf.rb
         | 
| 79 | 
            +
            - ext/thread_id/include/thread_id.h
         | 
| 87 80 | 
             
            - ext/thread_id/src/lib.rs
         | 
| 88 81 | 
             
            - lib/pyroscope.rb
         | 
| 89 82 | 
             
            - lib/pyroscope/version.rb
         | 
| 90 83 | 
             
            - lib/rbspy/rbspy.so
         | 
| 91 84 | 
             
            - lib/thread_id/thread_id.so
         | 
| 92 85 | 
             
            - pyroscope.gemspec
         | 
| 93 | 
            -
            - scripts/docker.sh
         | 
| 94 | 
            -
            - scripts/tests/test.rb
         | 
| 95 86 | 
             
            homepage: https://pyroscope.io
         | 
| 96 87 | 
             
            licenses:
         | 
| 97 88 | 
             
            - Apache-2.0
         | 
| @@ -101,7 +92,7 @@ metadata: | |
| 101 92 | 
             
              documentation_uri: https://pyroscope.io/docs/ruby/
         | 
| 102 93 | 
             
              changelog_uri: https://github.com/pyroscope-io/pyroscope-rs/tree/main/pyroscope_ffi/ruby/CHANGELOG.md
         | 
| 103 94 | 
             
              source_code_uri: https://github.com/pyroscope-io/pyroscope-rs/tree/main/pyroscope_ffi/ruby
         | 
| 104 | 
            -
            post_install_message: | 
| 95 | 
            +
            post_install_message:
         | 
| 105 96 | 
             
            rdoc_options: []
         | 
| 106 97 | 
             
            require_paths:
         | 
| 107 98 | 
             
            - lib
         | 
| @@ -117,7 +108,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement | |
| 117 108 | 
             
                  version: '0'
         | 
| 118 109 | 
             
            requirements: []
         | 
| 119 110 | 
             
            rubygems_version: 3.3.26
         | 
| 120 | 
            -
            signing_key: | 
| 111 | 
            +
            signing_key:
         | 
| 121 112 | 
             
            specification_version: 4
         | 
| 122 113 | 
             
            summary: Pyroscope
         | 
| 123 114 | 
             
            test_files: []
         | 
    
        data/elflib/rbspy/manylinux.sh
    DELETED
    
    | @@ -1,19 +0,0 @@ | |
| 1 | 
            -
            #!/bin/sh
         | 
| 2 | 
            -
            set -ex
         | 
| 3 | 
            -
             | 
| 4 | 
            -
            cargo --version
         | 
| 5 | 
            -
             | 
| 6 | 
            -
            # Build wheels
         | 
| 7 | 
            -
            # todo this one is deprecated, use "build" package
         | 
| 8 | 
            -
            /opt/python/cp37-cp37m/bin/python setup.py bdist_wheel
         | 
| 9 | 
            -
             | 
| 10 | 
            -
            # Audit wheels
         | 
| 11 | 
            -
            for wheel in dist/*.whl; do
         | 
| 12 | 
            -
              auditwheel repair $wheel -w dist/
         | 
| 13 | 
            -
              rm $wheel
         | 
| 14 | 
            -
            done
         | 
| 15 | 
            -
             | 
| 16 | 
            -
            # Extract wheels
         | 
| 17 | 
            -
            for wheel in dist/*.whl; do
         | 
| 18 | 
            -
                /opt/python/cp37-cp37m/bin/wheel unpack $wheel -d wheelhouse
         | 
| 19 | 
            -
            done
         | 
    
        data/elflib/rbspy/pyproject.toml
    DELETED
    
    
| 
            File without changes
         | 
    
        data/elflib/rbspy/setup.cfg
    DELETED
    
    | @@ -1,22 +0,0 @@ | |
| 1 | 
            -
            [metadata]
         | 
| 2 | 
            -
            name = rbspy 
         | 
| 3 | 
            -
            version= 1.0.0
         | 
| 4 | 
            -
            description = Fake wheel to generate audtiwheel libs
         | 
| 5 | 
            -
            url = https://proscope.io
         | 
| 6 | 
            -
            maintainer = Abid Omar 
         | 
| 7 | 
            -
            maintainer_email = contact@pyroscope.io 
         | 
| 8 | 
            -
            license = Apache 2.0
         | 
| 9 | 
            -
            classifiers =
         | 
| 10 | 
            -
                Intended Audience :: Developers
         | 
| 11 | 
            -
            project_urls =
         | 
| 12 | 
            -
                Documentation = https://proscope.io
         | 
| 13 | 
            -
                Bug Tracker = https://proscope.io
         | 
| 14 | 
            -
                Discussions = https://proscope.io
         | 
| 15 | 
            -
                Changelog = https://proscope.io
         | 
| 16 | 
            -
             | 
| 17 | 
            -
            [options]
         | 
| 18 | 
            -
            packages = find:
         | 
| 19 | 
            -
            install_requires =
         | 
| 20 | 
            -
                milksnakex>=0.1.6
         | 
| 21 | 
            -
            include_package_data = True
         | 
| 22 | 
            -
            zip_safe = False
         | 
    
        data/elflib/rbspy/setup.py
    DELETED
    
    | @@ -1,46 +0,0 @@ | |
| 1 | 
            -
            import os
         | 
| 2 | 
            -
            import sys
         | 
| 3 | 
            -
            from setuptools import find_packages, setup
         | 
| 4 | 
            -
            from pathlib import Path
         | 
| 5 | 
            -
             | 
| 6 | 
            -
            SCRIPT_DIR = Path(__file__).resolve().parent
         | 
| 7 | 
            -
             | 
| 8 | 
            -
            os.chdir(SCRIPT_DIR)
         | 
| 9 | 
            -
             | 
| 10 | 
            -
            # print script_dir
         | 
| 11 | 
            -
            print(SCRIPT_DIR)
         | 
| 12 | 
            -
             | 
| 13 | 
            -
            LIB_DIR = str(SCRIPT_DIR / "../../ext/rbspy")
         | 
| 14 | 
            -
             | 
| 15 | 
            -
            def build_native(spec):
         | 
| 16 | 
            -
                # Step 1: build the rust library
         | 
| 17 | 
            -
                build = spec.add_external_build(
         | 
| 18 | 
            -
                    cmd=['cargo', 'build', '--release'],
         | 
| 19 | 
            -
                    path=LIB_DIR
         | 
| 20 | 
            -
                )
         | 
| 21 | 
            -
             | 
| 22 | 
            -
                def find_dylib():
         | 
| 23 | 
            -
                    cargo_target = os.environ.get('CARGO_BUILD_TARGET')
         | 
| 24 | 
            -
                    if cargo_target:
         | 
| 25 | 
            -
                        in_path = 'target/%s/release' % (cargo_target)
         | 
| 26 | 
            -
                    else:
         | 
| 27 | 
            -
                        in_path = 'target/release'
         | 
| 28 | 
            -
                    return build.find_dylib('rbspy', in_path=in_path)
         | 
| 29 | 
            -
             | 
| 30 | 
            -
                # Step 2: package the compiled library
         | 
| 31 | 
            -
                rtld_flags = ["NOW"]
         | 
| 32 | 
            -
                if sys.platform == "darwin":
         | 
| 33 | 
            -
                    rtld_flags.append("NODELETE")
         | 
| 34 | 
            -
             | 
| 35 | 
            -
                spec.add_cffi_module(module_path='rbspy._native',
         | 
| 36 | 
            -
                        dylib=find_dylib,
         | 
| 37 | 
            -
                        header_filename=lambda:
         | 
| 38 | 
            -
                        build.find_header('rbspy.h',in_path='include'),
         | 
| 39 | 
            -
                        rtld_flags=rtld_flags,
         | 
| 40 | 
            -
                )
         | 
| 41 | 
            -
             | 
| 42 | 
            -
            setup(
         | 
| 43 | 
            -
                platforms="any",
         | 
| 44 | 
            -
                milksnake_tasks=[build_native],
         | 
| 45 | 
            -
                setup_requires=["milksnakex>=0.1.6"],
         | 
| 46 | 
            -
            )
         | 
| @@ -1,19 +0,0 @@ | |
| 1 | 
            -
            #!/bin/sh
         | 
| 2 | 
            -
            set -ex
         | 
| 3 | 
            -
             | 
| 4 | 
            -
            cargo --version
         | 
| 5 | 
            -
             | 
| 6 | 
            -
            # Build wheels
         | 
| 7 | 
            -
            # todo this one is deprecated, use "build" package
         | 
| 8 | 
            -
            /opt/python/cp37-cp37m/bin/python setup.py bdist_wheel
         | 
| 9 | 
            -
             | 
| 10 | 
            -
            # Audit wheels
         | 
| 11 | 
            -
            for wheel in dist/*.whl; do
         | 
| 12 | 
            -
              auditwheel repair $wheel -w dist/
         | 
| 13 | 
            -
              rm $wheel
         | 
| 14 | 
            -
            done
         | 
| 15 | 
            -
             | 
| 16 | 
            -
            # Extract wheels
         | 
| 17 | 
            -
            for wheel in dist/*.whl; do
         | 
| 18 | 
            -
                /opt/python/cp37-cp37m/bin/wheel unpack $wheel -d wheelhouse
         | 
| 19 | 
            -
            done
         | 
    
        data/elflib/thread_id/setup.cfg
    DELETED
    
    | @@ -1,22 +0,0 @@ | |
| 1 | 
            -
            [metadata]
         | 
| 2 | 
            -
            name = thread_id 
         | 
| 3 | 
            -
            version= 1.0.0
         | 
| 4 | 
            -
            description = Fake wheel to generate audtiwheel libs
         | 
| 5 | 
            -
            url = https://proscope.io
         | 
| 6 | 
            -
            maintainer = Abid Omar 
         | 
| 7 | 
            -
            maintainer_email = contact@pyroscope.io 
         | 
| 8 | 
            -
            license = Apache 2.0
         | 
| 9 | 
            -
            classifiers =
         | 
| 10 | 
            -
                Intended Audience :: Developers
         | 
| 11 | 
            -
            project_urls =
         | 
| 12 | 
            -
                Documentation = https://proscope.io
         | 
| 13 | 
            -
                Bug Tracker = https://proscope.io
         | 
| 14 | 
            -
                Discussions = https://proscope.io
         | 
| 15 | 
            -
                Changelog = https://proscope.io
         | 
| 16 | 
            -
             | 
| 17 | 
            -
            [options]
         | 
| 18 | 
            -
            packages = find:
         | 
| 19 | 
            -
            install_requires =
         | 
| 20 | 
            -
                milksnakex>=0.1.6
         | 
| 21 | 
            -
            include_package_data = True
         | 
| 22 | 
            -
            zip_safe = False
         | 
    
        data/elflib/thread_id/setup.py
    DELETED
    
    | @@ -1,46 +0,0 @@ | |
| 1 | 
            -
            import os
         | 
| 2 | 
            -
            import sys
         | 
| 3 | 
            -
            from setuptools import find_packages, setup
         | 
| 4 | 
            -
            from pathlib import Path
         | 
| 5 | 
            -
             | 
| 6 | 
            -
            SCRIPT_DIR = Path(__file__).resolve().parent
         | 
| 7 | 
            -
             | 
| 8 | 
            -
            os.chdir(SCRIPT_DIR)
         | 
| 9 | 
            -
             | 
| 10 | 
            -
            # print script_dir
         | 
| 11 | 
            -
            print(SCRIPT_DIR)
         | 
| 12 | 
            -
             | 
| 13 | 
            -
            LIB_DIR = str(SCRIPT_DIR / "../../ext/thread_id")
         | 
| 14 | 
            -
             | 
| 15 | 
            -
            def build_native(spec):
         | 
| 16 | 
            -
                # Step 1: build the rust library
         | 
| 17 | 
            -
                build = spec.add_external_build(
         | 
| 18 | 
            -
                    cmd=['cargo', 'build', '--release'],
         | 
| 19 | 
            -
                    path=LIB_DIR
         | 
| 20 | 
            -
                )
         | 
| 21 | 
            -
             | 
| 22 | 
            -
                def find_dylib():
         | 
| 23 | 
            -
                    cargo_target = os.environ.get('CARGO_BUILD_TARGET')
         | 
| 24 | 
            -
                    if cargo_target:
         | 
| 25 | 
            -
                        in_path = 'target/%s/release' % (cargo_target)
         | 
| 26 | 
            -
                    else:
         | 
| 27 | 
            -
                        in_path = 'target/release'
         | 
| 28 | 
            -
                    return build.find_dylib('thread_id', in_path=in_path)
         | 
| 29 | 
            -
             | 
| 30 | 
            -
                # Step 2: package the compiled library
         | 
| 31 | 
            -
                rtld_flags = ["NOW"]
         | 
| 32 | 
            -
                if sys.platform == "darwin":
         | 
| 33 | 
            -
                    rtld_flags.append("NODELETE")
         | 
| 34 | 
            -
             | 
| 35 | 
            -
                spec.add_cffi_module(module_path='thread_id._native',
         | 
| 36 | 
            -
                        dylib=find_dylib,
         | 
| 37 | 
            -
                        header_filename=lambda:
         | 
| 38 | 
            -
                        build.find_header('thread_id.h',in_path='include'),
         | 
| 39 | 
            -
                        rtld_flags=rtld_flags,
         | 
| 40 | 
            -
                )
         | 
| 41 | 
            -
             | 
| 42 | 
            -
            setup(
         | 
| 43 | 
            -
                platforms="any",
         | 
| 44 | 
            -
                milksnake_tasks=[build_native],
         | 
| 45 | 
            -
                setup_requires=["milksnakex>=0.1.6"],
         | 
| 46 | 
            -
            )
         | 
| 
            File without changes
         |