Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Tracking issuss of Bindings PHP #2813

Open
3 tasks
godruoyi opened this issue Aug 8, 2023 · 8 comments
Open
3 tasks

Tracking issuss of Bindings PHP #2813

godruoyi opened this issue Aug 8, 2023 · 8 comments

Comments

@godruoyi
Copy link
Contributor

godruoyi commented Aug 8, 2023

RFC: #2782

Tasks

@Xuanwo Xuanwo changed the title Tracking issuss of RFC-2782: Add PHP binding basic io Tracking issuss of Bindings PHP Aug 11, 2023
@Xuanwo
Copy link
Member

Xuanwo commented Aug 11, 2023

Is there a way to distribute native exetension so that users only need to add fields in composer instead? I expect users don't need to know about rust core details and just use opendal as a native php package.

@godruoyi
Copy link
Contributor Author

Actually, we cannot do this yet. If we want to use "composer require" to install opendalphp, we need to submit the code to https://packagist.org/ and it should only contain PHP code instead of binary files. Generally speaking, we can only install PHP binary extensions through pecl. Perhaps we can consider how to publish opendal on pecl so that we can install opendal-php just like installing redis/swoole.

pecl install redis
pecl install swoole
pecl install opendal-php

@Xuanwo
Copy link
Member

Xuanwo commented Aug 21, 2023

opendal-php is our project name, and users should use opendal in php ecosystem. Thus, we should support pecl install opendal. Others LGTM.

@Xuanwo
Copy link
Member

Xuanwo commented Sep 15, 2023

Hi, @godruoyi, our php build failed on github action, would you like to take a look?

context: #3055

@godruoyi
Copy link
Contributor Author

hi @Xuanwo, It seems that the issue is caused by upgrading to Ubuntu 22.04.3 (ubuntu-latest). In this version, we are using clang 14.0.0.

failed CI

And in Ubuntu 20.04, we were able to compile successfully. This version uses clang 12.0.0.
Passed CI

We can temporarily change the IMAGE in PHP CI to ubuntu-20.04 now(if yes, will push a pr soon), and then I need to take a look at ext-php-rs. We need it to support ubuntu-latest first then we can change the running environment of PHP CI in opendal to ubuntu latest. This may take some time because it seems that this repository has not merged any PR for a long time.

@Xuanwo
Copy link
Member

Xuanwo commented Sep 19, 2023

So, the issue we encountered here is that ext-php-rs doesn't function on clang 14?


By the way, it works on my PC with clang 16:

:) clang -v
clang version 16.0.6
Target: x86_64-pc-linux-gnu
Thread model: posix
InstalledDir: /usr/bin
Found candidate GCC installation: /usr/bin/../lib/gcc/x86_64-pc-linux-gnu/13.2.1
Found candidate GCC installation: /usr/bin/../lib64/gcc/x86_64-pc-linux-gnu/13.2.1
Selected GCC installation: /usr/bin/../lib64/gcc/x86_64-pc-linux-gnu/13.2.1
Candidate multilib: .;@m64
Candidate multilib: 32;@m32
Selected multilib: .;@m64
:) php -v
PHP 8.2.10 (cli) (built: Sep  1 2023 11:07:36) (NTS)
Copyright (c) The PHP Group
Zend Engine v4.2.10, Copyright (c) Zend Technologies

@godruoyi
Copy link
Contributor Author

godruoyi commented Sep 19, 2023

I don't have much knowledge about this case, need some time to take a look.


Are you running on 22.04.3? @Xuanwo

@Xuanwo
Copy link
Member

Xuanwo commented Sep 19, 2023

Are you running on 22.04.3? @Xuanwo

I'm running on archlinux.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants