<feed xmlns='http://www.w3.org/2005/Atom'>
<title>ruby.git/lib/bundler/templates/newgem/ext, branch v4.0.3</title>
<subtitle>The Ruby Programming Language</subtitle>
<link rel='alternate' type='text/html' href='https://git.ruby-lang.org/ruby.git/'/>
<entry>
<title>[ruby/rubygems] Add `--ext=go` to `bundle gem`</title>
<updated>2025-11-19T00:47:07+00:00</updated>
<author>
<name>Go Sueyoshi</name>
<email>sue445@users.noreply.github.com</email>
</author>
<published>2025-11-19T00:46:35+00:00</published>
<link rel='alternate' type='text/html' href='https://git.ruby-lang.org/ruby.git/commit/?id=4423facbffd5bd523541ebf42dc274272b1de732'/>
<id>4423facbffd5bd523541ebf42dc274272b1de732</id>
<content type='text'>
(https://github.com/ruby/rubygems/pull/8183)

* Add new gem templates

* Add `--ext=go` in `bundle gem`

* Add setup-go to .github/workflows/main.yml

* Embed go version in go.mod

* Use go in bundler CI

* Add example method to template

* Install Go in .circleci/config.yml

* Install Go in .gitlab-ci.yml

* Allow hard tabs in go template

* Run `rake update_manifest`

* Fix test

* Move go_gem to gemspec

Respect to 9b0ec80

* nits: :golf:

* includes valid module name in go.mod

* generate header file

* Run `go mod tidy` to create `go.sum`

* Check if `go.sum` is generated only when Go is installed

To avoid test failure in environments where Go is not installed

* Run CI

* Workaround for hung up

c.f. https://github.com/rubygems/rubygems/actions/runs/11639408044/job/32415545422

* Write man for --ext=go

* Re-generate man with `./bin/rake man:build`

* pinning :pushpin:

* Update with `./bin/rake man:build`

* nits: Extract to method

* nits: Use `sys_exec` instead of `system`

* Clean go module cache after test

Workaround following error

```
1) bundle gem gem naming with underscore --ext parameter set with go includes go_gem extension in extconf.rb
   Failure/Error: FileUtils.rm_r(dir)

   Errno::EACCES:
     Permission denied @ apply2files - /home/runner/work/rubygems/rubygems/bundler/tmp/2.2/home/go/pkg/mod/gopkg.in/yaml.v3@v3.0.1/decode_test.go
   # ./spec/support/helpers.rb:37:in `block in reset!'
   # ./spec/support/helpers.rb:21:in `each'
   # ./spec/support/helpers.rb:21:in `reset!'
   # ./spec/spec_helper.rb:130:in `block (2 levels) in &lt;top (required)&gt;'
   # /home/runner/work/rubygems/rubygems/lib/rubygems.rb:303:in `load'
   # /home/runner/work/rubygems/rubygems/lib/rubygems.rb:303:in `activate_and_load_bin_path'
```

Files installed with `go get` have permissions set to 444
ref. https://github.com/golang/go/issues/35615

```
$ ls -l /home/runner/work/rubygems/rubygems/bundler/tmp/2.2/home/go/pkg/mod/gopkg.in/yaml.v3@v3.0.1/decode_test.go
-r--r--r-- 1 runner runner 42320 Nov 15 06:38 /home/runner/work/rubygems/rubygems/bundler/tmp/2.2/home/go/pkg/mod/gopkg.in/yaml.v3@v3.0.1/decode_test.go
```

So they cannot be deleted by `FileUtils.rm_r`.
Therefore, this is necessary to execute `go clean -modcache` separately from `FileUtils.rm_r` to circumvent it.

* Remove needless changes

ref. https://github.com/ruby/rubygems/pull/8183#discussion_r2532902051

* ci: setup-go is needless

* Don't run go command in `bundle gem`

ref. https://github.com/ruby/rubygems/pull/8183#discussion_r2532765470

* Revert unrelated date changes

---------

https://github.com/ruby/rubygems/commit/260d7d60b3

Co-authored-by: Hiroshi SHIBATA &lt;hsbt@ruby-lang.org&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
(https://github.com/ruby/rubygems/pull/8183)

* Add new gem templates

* Add `--ext=go` in `bundle gem`

* Add setup-go to .github/workflows/main.yml

* Embed go version in go.mod

* Use go in bundler CI

* Add example method to template

* Install Go in .circleci/config.yml

* Install Go in .gitlab-ci.yml

* Allow hard tabs in go template

* Run `rake update_manifest`

* Fix test

* Move go_gem to gemspec

Respect to 9b0ec80

* nits: :golf:

* includes valid module name in go.mod

* generate header file

* Run `go mod tidy` to create `go.sum`

* Check if `go.sum` is generated only when Go is installed

To avoid test failure in environments where Go is not installed

* Run CI

* Workaround for hung up

c.f. https://github.com/rubygems/rubygems/actions/runs/11639408044/job/32415545422

* Write man for --ext=go

* Re-generate man with `./bin/rake man:build`

* pinning :pushpin:

* Update with `./bin/rake man:build`

* nits: Extract to method

* nits: Use `sys_exec` instead of `system`

* Clean go module cache after test

Workaround following error

```
1) bundle gem gem naming with underscore --ext parameter set with go includes go_gem extension in extconf.rb
   Failure/Error: FileUtils.rm_r(dir)

   Errno::EACCES:
     Permission denied @ apply2files - /home/runner/work/rubygems/rubygems/bundler/tmp/2.2/home/go/pkg/mod/gopkg.in/yaml.v3@v3.0.1/decode_test.go
   # ./spec/support/helpers.rb:37:in `block in reset!'
   # ./spec/support/helpers.rb:21:in `each'
   # ./spec/support/helpers.rb:21:in `reset!'
   # ./spec/spec_helper.rb:130:in `block (2 levels) in &lt;top (required)&gt;'
   # /home/runner/work/rubygems/rubygems/lib/rubygems.rb:303:in `load'
   # /home/runner/work/rubygems/rubygems/lib/rubygems.rb:303:in `activate_and_load_bin_path'
```

Files installed with `go get` have permissions set to 444
ref. https://github.com/golang/go/issues/35615

```
$ ls -l /home/runner/work/rubygems/rubygems/bundler/tmp/2.2/home/go/pkg/mod/gopkg.in/yaml.v3@v3.0.1/decode_test.go
-r--r--r-- 1 runner runner 42320 Nov 15 06:38 /home/runner/work/rubygems/rubygems/bundler/tmp/2.2/home/go/pkg/mod/gopkg.in/yaml.v3@v3.0.1/decode_test.go
```

So they cannot be deleted by `FileUtils.rm_r`.
Therefore, this is necessary to execute `go clean -modcache` separately from `FileUtils.rm_r` to circumvent it.

* Remove needless changes

ref. https://github.com/ruby/rubygems/pull/8183#discussion_r2532902051

* ci: setup-go is needless

* Don't run go command in `bundle gem`

ref. https://github.com/ruby/rubygems/pull/8183#discussion_r2532765470

* Revert unrelated date changes

---------

https://github.com/ruby/rubygems/commit/260d7d60b3

Co-authored-by: Hiroshi SHIBATA &lt;hsbt@ruby-lang.org&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>[ruby/rubygems] update magnus version in rust extension gem template</title>
<updated>2025-10-20T07:04:08+00:00</updated>
<author>
<name>Mat Sadler</name>
<email>mat@sourcetagsandcodes.com</email>
</author>
<published>2025-10-18T02:49:12+00:00</published>
<link rel='alternate' type='text/html' href='https://git.ruby-lang.org/ruby.git/commit/?id=6eb75f6c36288cdd7522f27ad18608d13031f2b8'/>
<id>6eb75f6c36288cdd7522f27ad18608d13031f2b8</id>
<content type='text'>
https://github.com/ruby/rubygems/commit/1ba8eb4ab3
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
https://github.com/ruby/rubygems/commit/1ba8eb4ab3
</pre>
</div>
</content>
</entry>
<entry>
<title>[rubygems/rubygems] update Magnus library in Rust extension gem template</title>
<updated>2023-11-29T02:21:38+00:00</updated>
<author>
<name>Michael Go</name>
<email>michael.go@shopify.com</email>
</author>
<published>2023-11-28T15:37:26+00:00</published>
<link rel='alternate' type='text/html' href='https://git.ruby-lang.org/ruby.git/commit/?id=bd2b6b702cf43fb25562bdf8b1929d06ed3fcd98'/>
<id>bd2b6b702cf43fb25562bdf8b1929d06ed3fcd98</id>
<content type='text'>
https://github.com/rubygems/rubygems/commit/46f09800da
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
https://github.com/rubygems/rubygems/commit/46f09800da
</pre>
</div>
</content>
</entry>
<entry>
<title>[rubygems/rubygems] update Magnus library in Rust extension gem template</title>
<updated>2023-07-31T06:25:21+00:00</updated>
<author>
<name>Mat Sadler</name>
<email>mat@sourcetagsandcodes.com</email>
</author>
<published>2023-07-29T04:19:04+00:00</published>
<link rel='alternate' type='text/html' href='https://git.ruby-lang.org/ruby.git/commit/?id=a3c0e9d90d657d9b288fb4a50462684087f4162f'/>
<id>a3c0e9d90d657d9b288fb4a50462684087f4162f</id>
<content type='text'>
https://github.com/rubygems/rubygems/commit/19a92a3367
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
https://github.com/rubygems/rubygems/commit/19a92a3367
</pre>
</div>
</content>
</entry>
<entry>
<title>[rubygems/rubygems] Use append_cflags instead of directly append for CFLAGS</title>
<updated>2023-03-27T09:47:20+00:00</updated>
<author>
<name>Hiroshi SHIBATA</name>
<email>hsbt@ruby-lang.org</email>
</author>
<published>2023-03-27T02:50:32+00:00</published>
<link rel='alternate' type='text/html' href='https://git.ruby-lang.org/ruby.git/commit/?id=36254c5ddf1b1b16fe5f1705227713ee7529b2f5'/>
<id>36254c5ddf1b1b16fe5f1705227713ee7529b2f5</id>
<content type='text'>
https://github.com/rubygems/rubygems/commit/61ec0c8389
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
https://github.com/rubygems/rubygems/commit/61ec0c8389
</pre>
</div>
</content>
</entry>
<entry>
<title>[rubygems/rubygems] Generate native gems with `-fvisibility=hidden`</title>
<updated>2023-03-25T00:31:46+00:00</updated>
<author>
<name>Jean Boussier</name>
<email>jean.boussier@gmail.com</email>
</author>
<published>2023-03-24T13:30:19+00:00</published>
<link rel='alternate' type='text/html' href='https://git.ruby-lang.org/ruby.git/commit/?id=276f4be96df08becfc59ef253025c2e5f19718fa'/>
<id>276f4be96df08becfc59ef253025c2e5f19718fa</id>
<content type='text'>
I recently ran into very nasty issues with dynamic symbols clashing between
two native gems.

I believe the overwhelming majority of native gems don't want to export
their symbols, so hidding them by default would make sense to me.

https://github.com/rubygems/rubygems/commit/449624aa54
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
I recently ran into very nasty issues with dynamic symbols clashing between
two native gems.

I believe the overwhelming majority of native gems don't want to export
their symbols, so hidding them by default would make sense to me.

https://github.com/rubygems/rubygems/commit/449624aa54
</pre>
</div>
</content>
</entry>
<entry>
<title>Merge RubyGems-3.4.0 and Bundler-2.4.0</title>
<updated>2022-12-24T07:57:07+00:00</updated>
<author>
<name>Hiroshi SHIBATA</name>
<email>hsbt@ruby-lang.org</email>
</author>
<published>2022-12-21T23:20:23+00:00</published>
<link rel='alternate' type='text/html' href='https://git.ruby-lang.org/ruby.git/commit/?id=f6620037ba1477d2c337d7b511f094d6d0fbb69c'/>
<id>f6620037ba1477d2c337d7b511f094d6d0fbb69c</id>
<content type='text'>
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
</pre>
</div>
</content>
</entry>
<entry>
<title>[rubygems/rubygems] Fix remaining RuboCop issues</title>
<updated>2020-07-15T07:05:12+00:00</updated>
<author>
<name>Utkarsh Gupta</name>
<email>utkarsh@debian.org</email>
</author>
<published>2020-06-30T07:05:38+00:00</published>
<link rel='alternate' type='text/html' href='https://git.ruby-lang.org/ruby.git/commit/?id=8c65f612f4e4caaecfd3291907f48c9e075c0319'/>
<id>8c65f612f4e4caaecfd3291907f48c9e075c0319</id>
<content type='text'>
With #3731 and #3740 merged, this covers up the
remaining part of the issues.
This was discovered when one tries to create a gem
with a different framework.
Could be reproduced with:
`bundle gem foo --ext --test=test-unit`

Signed-off-by: Utkarsh Gupta &lt;utkarsh@debian.org&gt;

https://github.com/rubygems/rubygems/commit/51b6457150
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
With #3731 and #3740 merged, this covers up the
remaining part of the issues.
This was discovered when one tries to create a gem
with a different framework.
Could be reproduced with:
`bundle gem foo --ext --test=test-unit`

Signed-off-by: Utkarsh Gupta &lt;utkarsh@debian.org&gt;

https://github.com/rubygems/rubygems/commit/51b6457150
</pre>
</div>
</content>
</entry>
<entry>
<title>Added bundler as default gems. Revisit [Feature #12733]</title>
<updated>2018-11-02T23:07:56+00:00</updated>
<author>
<name>hsbt</name>
<email>hsbt@b2dd03c8-39d4-4d8f-98ff-823fe69b080e</email>
</author>
<published>2018-11-02T23:07:56+00:00</published>
<link rel='alternate' type='text/html' href='https://git.ruby-lang.org/ruby.git/commit/?id=59c8d50653480bef3f24517296e6ddf937fdf6bc'/>
<id>59c8d50653480bef3f24517296e6ddf937fdf6bc</id>
<content type='text'>
  * bin/*, lib/bundler/*, lib/bundler.rb, spec/bundler, man/*:
    Merge from latest stable branch of bundler/bundler repository and
    added workaround patches. I will backport them into upstream.
  * common.mk, defs/gmake.mk: Added `test-bundler` task for test suite
    of bundler.
  * tool/sync_default_gems.rb: Added sync task for bundler.

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@65509 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
  * bin/*, lib/bundler/*, lib/bundler.rb, spec/bundler, man/*:
    Merge from latest stable branch of bundler/bundler repository and
    added workaround patches. I will backport them into upstream.
  * common.mk, defs/gmake.mk: Added `test-bundler` task for test suite
    of bundler.
  * tool/sync_default_gems.rb: Added sync task for bundler.

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@65509 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
</pre>
</div>
</content>
</entry>
<entry>
<title>Postponing the Bundler merge.</title>
<updated>2017-12-22T23:08:05+00:00</updated>
<author>
<name>hsbt</name>
<email>hsbt@b2dd03c8-39d4-4d8f-98ff-823fe69b080e</email>
</author>
<published>2017-12-22T23:08:05+00:00</published>
<link rel='alternate' type='text/html' href='https://git.ruby-lang.org/ruby.git/commit/?id=7825e8363d4b2ccad8e2d3f5eeba9e26f6656911'/>
<id>7825e8363d4b2ccad8e2d3f5eeba9e26f6656911</id>
<content type='text'>
  I faced a big issue about Bundler with ruby core.
  I have no time to resolve it issue before 2.5 final release.

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@61416 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
  I faced a big issue about Bundler with ruby core.
  I have no time to resolve it issue before 2.5 final release.

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@61416 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
</pre>
</div>
</content>
</entry>
</feed>
