You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
> Don't forget to set the `GEN_STUB_SCRIPT` environment variable to the path of the `gen_stub.php` file in the PHP sources you downloaded earlier. This is the same `gen_stub.php` script mentioned in the manual implementation section.
593
593
594
-
If everything went well, a new directory named `build` should have been created. This directory contains the generated files for your extension, including the `my_extension.go` file with the generated PHP function stubs.
594
+
If everything went well, your project directory should contain the following files for your extension:
595
+
596
+
-**`my_extension.go`** - Your original source file (remains unchanged)
597
+
-**`my_extension_generated.go`** - Generated file with CGO wrappers that call your functions
598
+
-**`my_extension.stub.php`** - PHP stub file for IDE autocompletion
599
+
-**`my_extension_arginfo.h`** - PHP argument information
600
+
-**`my_extension.h`** - C header file
601
+
-**`my_extension.c`** - C implementation file
602
+
-**`README.md`** - Documentation
603
+
604
+
> [!IMPORTANT]
605
+
> **Your source file (`my_extension.go`) is never modified.** The generator creates a separate `_generated.go` file containing CGO wrappers that call your original functions. This means you can safely version control your source file without worrying about generated code polluting it.
595
606
596
607
### Integrating the Generated Extension into FrankenPHP
0 commit comments