Граф коммитов

506 Коммитов

Автор SHA1 Сообщение Дата
Nobuyoshi Nakada 98c5907c65
Ripper source on mswin
* Get rid of command substitution for cmd.exe.
* Separate RM1 command to remove single file sans directory.
2021-09-21 13:05:27 +09:00
卜部昌平 789232f9fd template/Doxyfile.tmpl: modernise
applied doxygen -g for Doxygen 1.9.3.
2021-09-15 09:25:23 +09:00
卜部昌平 679f4b895b template/Doxyfile.tmpl: EXTRACT_ALL=NO
This prevents file-static functions/variables be listed in the CAPI
documents.  An entity shall be placed inside of a file that contains
`@file` doxygen comment, in order for it to be documented. [ci skip]
2021-09-10 20:00:06 +09:00
sonots 0e3dae78b3 template/Doxyfile.tmpl: EXTRACT_STATIC: YES [Bugs #14037]
I often feel that C API documents are lacked in C source codes,
especially for static functions. I propose to turn EXTRACT_STATIC = YES
flag of Doxygen to YES, and write document comments for static functions
as much as possible.

* template/Doxyfile.tmpl: EXTRACT_STATIC: YES [Bugs #14037]
2021-09-10 20:00:06 +09:00
卜部昌平 bbe7049813 template/Doxyfile.tmpl: rethink about exclusions
I guess we don't want documents for C API of extension libraries?  They
are never intended to provide C APIs anyways.

We could revisit this decision later. [ci skip]
2021-09-10 20:00:06 +09:00
卜部昌平 809138fe4b include/ruby/io.h: add doxyen
Must not be a bad idea to improve documents. [ci skip]
2021-09-10 20:00:06 +09:00
卜部昌平 0ea157136f postscript about rb_mutex_sleep
Asked ko1 about the design.  [ci skip]
2021-09-10 20:00:06 +09:00
卜部昌平 4881a3ed38 include/ruby/internal/fl_type.h: add doxygen
Must not be a bad idea to improve documents. [ci skip]
2021-09-10 20:00:06 +09:00
卜部昌平 c3c0bf6823 include/ruby/internal/rgengc.h: add dosygen
Must not be a bad idea to improve documents. [ci skip]
2021-09-10 20:00:06 +09:00
卜部昌平 e2a441bdd4 include/ruby/internal/value_type.h: add doxygen
Must not be a bad idea to improve documents. [ci skip]
2021-09-10 20:00:06 +09:00
卜部昌平 28b7b0e13e include/ruby/internal/xmalloc.h: add doxygen
Must not be a bad idea to improve documents. [ci skip]
2021-09-10 20:00:06 +09:00
卜部昌平 b6469c3aaf template/Doxyfile.tmpl: add alias
This enables me to write `@shyouhei` in C comments without complained by
doxygen that @shyouhei is an unknown special command. [ci skip]
2021-09-10 20:00:06 +09:00
卜部昌平 a08163fb24 template/Doxyfile.tmpl: use of += operator
It is easier to maintain (e.g. sort them). [ci skip]
2021-09-10 20:00:06 +09:00
卜部昌平 f9af5c9542 template/Doxyfile.tmpl: quote spaces
The new Doxyfile.tmpl says:

> # Values that contain spaces should be placed between quotes (\" \").

[ci skip]
2021-09-10 20:00:06 +09:00
卜部昌平 85a737a1f9 template/Doxyfile.tmpl: increase DOT_GRAPH_MAX_NODES
`make capi` warned:

> warning: Included by graph for 'dllexport.h' not generated, too many nodes (85)

[ci skip]
2021-09-10 20:00:06 +09:00
卜部昌平 c9753f3f91 template/Doxyfile.tmpl: delete commented-out settings
Let our VCS manage old contents. [ci skip]
2021-09-10 20:00:06 +09:00
卜部昌平 aa5dc3e297 template/Doxyfile.tmpl: modernize
Didn't question the current settings.  This changeset just re-applied
`doxygen -g` against:

doxygen 1.9.0 (1e72202d8fa0e9d2b3f2a29c88ec4f5790a0a4e2)

[ci skip]
2021-09-10 20:00:06 +09:00
Nobuyoshi Nakada 7487371eeb
Make ruby.pc from make
Expand variables undefined in configure.ac, RUBY_RELEASE_DATE and
so on.
2021-08-29 14:08:53 +09:00
Nobuyoshi Nakada 623736ae7f
Move DEFFILE to EXTDLDFLAGS
So that it is no longer needed in ruby.pc.in.
2021-08-29 13:04:42 +09:00
Nobuyoshi Nakada 323c0c392a
Reorder ruby.pc variables
Moved variables obviously independent from others first.
2021-08-29 12:50:24 +09:00
Nobuyoshi Nakada 2e49e4330d
Disable debug flag for executable files when LTO [ci skip]
Get rid of tons of linker warnings that it could not find object
file symbol for every symbols, when targeting darwin.
2021-08-14 23:22:04 +09:00
Nobuyoshi Nakada 6e60fc2945
Group commands on GitHub Actions 2021-08-07 18:32:24 +09:00
Yusuke Endoh 405644f38c Revert "Removed extinit.o from main programs"
This reverts commit ac86fcbfd0.

This change broke "--disable-shared --with-static-linked-ext".
2021-08-05 14:48:24 +09:00
Nobuyoshi Nakada ac86fcbfd0
Removed extinit.o from main programs
It is included in libruby, which is linked into the main programs.
2021-07-03 12:52:46 +09:00
Nobuyoshi Nakada 4b28fea6ee
Run ifchange with shell explicitly, workaround of noexec mount 2021-06-22 09:46:40 +09:00
Nobuyoshi Nakada 60eee3c3cb
Fix syntax error in generated code 2021-06-21 11:20:31 +09:00
Nobuyoshi Nakada 28933c1071
Adjust indents 2021-06-21 11:08:02 +09:00
Nobuyoshi Nakada 2e97240617
prelude.c.tmpl: strip comment-only or empty lines at the beginning 2021-06-06 22:45:37 +09:00
Benoit Daloze 68d6bd0873 Fix trivial -Wundef warnings
* See [Feature #17752]

Co-authored-by: xtkoba (Tee KOBAYASHI) <xtkoba+ruby@gmail.com>
2021-05-04 14:56:55 +02:00
Nobuyoshi Nakada c569c298fe just redirect preprocessed vm.c to mjit header [Bug #17787]
Not all preprocessors work with output option.
2021-04-10 16:05:01 +09:00
Nobuyoshi Nakada cb396d4214
Share variables defined in common GNUmakefile also in cygwin/mingw 2021-03-21 17:57:44 +09:00
Nobuyoshi Nakada 4ea9df0135
No longer aclocal is used [ci skip] 2021-03-20 09:12:08 +09:00
Nobuyoshi Nakada 07b4b1b1cb
Support coroutine on universal binary 2021-01-22 23:41:52 +09:00
Nobuyoshi Nakada dff74ee6db
Revert "Autoconf 2.70 no longer has -o option"
This reverts commit 331f0bc1cb.
It seems a mistake.
2021-01-18 21:15:47 +09:00
Nobuyoshi Nakada 331f0bc1cb
Autoconf 2.70 no longer has -o option 2021-01-18 16:22:17 +09:00
Takashi Kokubun e1fee7f949
Rename RubyVM::MJIT to RubyVM::JIT
because the name "MJIT" is an internal code name, it's inconsistent with
--jit while they are related to each other, and I want to discourage future
JIT implementation-specific (e.g. MJIT-specific) APIs by this rename.

[Feature #17490]
2021-01-13 22:46:51 -08:00
Nobuyoshi Nakada 208192fdb6
Fixed wrong configure option 2020-12-29 17:50:14 +09:00
Nobuyoshi Nakada 2f42243bce Make more silent when -s on GNU make 2020-12-29 17:45:19 +09:00
Nobuyoshi Nakada d57c5a7b61 transcode-tblgen.rb: make silent a little when just -v 2020-12-29 17:45:19 +09:00
Nobuyoshi Nakada 260d626ef6
Ignore symbols declared in the platform header 2020-12-27 15:50:44 +09:00
Koichi Sasada aa6287cd26 fix inline method cache sync bug
`cd` is passed to method call functions to method invocation
functions, but `cd` can be manipulated by other ractors simultaneously
so it contains thread-safety issue.

To solve this issue, this patch stores `ci` and found `cc` to `calling`
and stops to pass `cd`.
2020-12-15 13:29:30 +09:00
Takashi Kokubun 8ce1711c25
Revert "Set VM_FRAME_FLAG_FINISH at once on MJIT"
This reverts commit 4d2c8edca6.

Unfortunately this seems to cause several issues:
https://github.com/ruby/ruby/runs/1462188376?check_suite_focus=true
http://ci.rvm.jp/results/trunk-mjit-wait@phosphorus-docker/3272802
2020-11-26 22:41:15 -08:00
Takashi Kokubun 4d2c8edca6
Set VM_FRAME_FLAG_FINISH at once on MJIT
Performance is probably improved?

$ benchmark-driver -v --rbenv 'before --jit;after --jit' --repeat-count=12 --alternate --output=all benchmark.yml
before --jit: ruby 3.0.0dev (2020-11-27T04:37:47Z master 69e77e81dc) +JIT [x86_64-linux]
after --jit: ruby 3.0.0dev (2020-11-27T05:28:19Z master df6b05c6dd) +JIT [x86_64-linux]
last_commit=Set VM_FRAME_FLAG_FINISH at once
Calculating -------------------------------------
                                 before --jit           after --jit
Optcarrot Lan_Master.nes    80.89292998533379     82.19497327502751 fps
                            80.93130641142331     85.13943315260148
                            81.06214830270119     87.43757879797808
                            82.29172808453910     87.89942441487113
                            84.61206450455929     87.91309779491075
                            85.44545883567997     87.98026086648694
                            86.02923132404449     88.03081060383973
                            86.07411817365879     88.14650206137341
                            86.34348799602836     88.32791633649961
                            87.90257338977324     88.57599644892220
                            88.58006509876580     88.67426384743277
                            89.26611118140011     88.81669430874207

This should have no bad impact on VM because this function is ALWAYS_INLINE.
2020-11-26 21:32:14 -08:00
Nobuyoshi Nakada 75d48a533d
rubyspec-capiext: Use plain DLDFLAGS without flags for libruby 2020-11-22 19:09:58 +09:00
Nobuyoshi Nakada b958e2add8 Removed canonicalization for mathn 2020-11-10 11:14:15 +09:00
Koichi Sasada 07c03bc309 check isolated Proc more strictly
Isolated Proc prohibit to access outer local variables, but it was
violated by binding and so on, so they should be error.
2020-10-29 23:42:55 +09:00
Stefan Stüben 8c2e5bbf58 Don't redefine #rb_intern over and over again 2020-10-21 12:45:18 +09:00
卜部昌平 21b3bc10d3 DEPRECATED_TYPE: is deprecated
Nobody uses this macro any longer.
2020-08-27 15:02:52 +09:00
卜部昌平 5af983af4f template/prelude.c.tmpl: suppress clang-12 warning
Clang 12 warns "suspicious concatenation of string literals in an array
initialization", which is rather annoying than useful in this context.
2020-08-11 16:51:07 +09:00
卜部昌平 acd8ee8dbc tool/prelude.c.tmpl: use RubyVM::CEscape
Do not repeat yourself.
2020-08-11 16:51:07 +09:00
Nobuyoshi Nakada ec9a9aaa51
Ignore configurations in un-built extension libraries
Exclude linker flags for external libraries used by no longer
built extension libraries when static-linked-ext.
2020-06-23 00:25:36 +09:00
Nobuyoshi Nakada f3e081c6b6
Build configured extension libraries only
Consider the libraries, which remain exts.mk but not listed in
ext/configure-ext.mk, removed.
2020-06-19 15:35:14 +09:00
Nobuyoshi Nakada aa21a775a6
Configure only directories having extconf.rb 2020-06-19 15:13:59 +09:00
Nobuyoshi Nakada 1e7c0ccb0d
Now bundled gems are extracted under .bundle/gems 2020-06-19 14:02:46 +09:00
Nobuyoshi Nakada 0d38a51ec4
Clean exts.mk under each extension library 2020-06-19 12:07:19 +09:00
Nobuyoshi Nakada 1f1b62fb7b
Added install-dbg
Scripts to run the interpreter via debugger.
2020-06-13 08:22:06 +09:00
Nobuyoshi Nakada 0c00a4176b
Hash marks in Makefile need to be escaped [Bug #16935] 2020-06-06 16:46:05 +09:00
Nobuyoshi Nakada 1c4eb70654
Build auxiliary program files early 2020-05-12 23:19:20 +09:00
Nobuyoshi Nakada dd830fab69
Fixed a typo 2020-05-10 18:40:47 +09:00
Nobuyoshi Nakada 42e8de8db9
Fix for cross_compiling
`RubyVM.each_builtin` is not defined when cross compiling.
2020-05-10 17:28:03 +09:00
卜部昌平 4fca592e8c delete mk_builtin_binary.rb
To generate what is necessary via generic_erb.rb instead.
2020-05-10 16:51:10 +09:00
卜部昌平 191cfcc407 delete mk_call_iseq_optimized.rb
To generate what is necessary via generic_erb.rb instead.
2020-05-10 16:51:10 +09:00
卜部昌平 9e6e39c351
Merge pull request #2991 from shyouhei/ruby.h
Split ruby.h
2020-04-08 13:28:13 +09:00
Nobuyoshi Nakada df275179bd
Revert "Moved aclocal.m4 to macro directory"
This reverts commit 4a6571dbc1,
because chkbuild does not follow.
2020-04-05 11:53:07 +09:00
Nobuyoshi Nakada 4a6571dbc1 Moved aclocal.m4 to macro directory 2020-04-05 09:26:57 +09:00
Nobuyoshi Nakada 21d0b40de2 Added tooldir variable 2020-04-05 09:26:57 +09:00
Nobuyoshi Nakada 03ca90c732
Share download cache with bundler 2020-03-31 17:36:52 +09:00
Takashi Kokubun 5b3157a511
Make file names and variable names consistent 2020-03-23 22:33:01 -07:00
Nobuyoshi Nakada 6ab3664635
Moved MJIT_WITHOUT_TABS default to configure.ac
And then the environment variable.
2020-03-24 13:46:00 +09:00
Nobuyoshi Nakada 88f4ebac83
Update and extract for each gem 2020-03-13 15:34:50 +09:00
卜部昌平 3b69552a5c add predefined macros for Doxygen
Predefined macros are practices not very well recommended, but can be
better than having no documents at all.  Without those predefined
macros, Doxygen confused for instace PUREFUNC(int foo()) to be a
declaration of PUREFUNC, not foo.
2020-02-06 11:46:51 +09:00
Jeremy Evans 9f99760daf
Get rid of use of special variables
Use `"\n"` and `IO#fileno` instead of `$/` and `$.` respectively.
[Feature #14240]
2020-01-20 16:58:58 +09:00
Nobuyoshi Nakada 93a51c15d9
Update clean-local [ci skip]
* Remove builtin_binary.inc which is generated for each time
  miniruby is built.

* dSYM is a directory, not a file.
2020-01-18 16:47:53 +09:00
卜部昌平 5e22f873ed decouple internal.h headers
Saves comitters' daily life by avoid #include-ing everything from
internal.h to make each file do so instead.  This would significantly
speed up incremental builds.

We take the following inclusion order in this changeset:

1.  "ruby/config.h", where _GNU_SOURCE is defined (must be the very
    first thing among everything).
2.  RUBY_EXTCONF_H if any.
3.  Standard C headers, sorted alphabetically.
4.  Other system headers, maybe guarded by #ifdef
5.  Everything else, sorted alphabetically.

Exceptions are those win32-related headers, which tend not be self-
containing (headers have inclusion order dependencies).
2019-12-26 20:45:12 +09:00
Koichi Sasada 9c2807b2df remove prelude.c
prelude.c is an automatically generated file by template/prelude.c.tmpl.
However it does not contain any required functions. So remove it from
dependency.

Also miniprelude.c is included by mini_builtin.c and does not need
to make miniprelude.o.
2019-12-11 11:24:42 +09:00
Koichi Sasada 2c5c60754c use compiled binary for gem_prelude.rb.
`gem_prelude.rb` is not compiled yet. This patch compile it to
compiled binary.
2019-12-11 11:24:42 +09:00
Koichi Sasada 9c1abe2a6c load prelude.rb by builtin features.
The script in prelude.rb was embed in MRI to load it (eval this
script at everyboot).
This commit change the loading process of prelude.rb. MRI doesn't
eval a script, but load from compiled binary with builtin feature.

So that Init_prelude() does not load `prelude.rb` now.
2019-11-15 03:55:46 +09:00
Dylan Thacker-Smith 7913daf36c Add missing Makefile dependencies for the tool/insns2vm.rb script 2019-11-13 15:36:58 +09:00
Nobuyoshi Nakada faa4f4f23f
Get rid of FreeBSD make incompatibility [Bug #16331]
FreeBSD make works differently with `-j` option.

> -j	max_jobs
> 	Specify the maximum number of jobs that `make` may have running
>	at any one time.  The value is saved in `.MAKE.JOBS.` Turns
>	compatibility mode off, unless the `B` flag is also specified.
>	When compatibility mode is off, all commands associated with a
>	target are executed in a single shell invocation as opposed to
>	the traditional one shell invocation per line.  This can break
>	traditional scripts which change directories on each command
>	invocation and then expect to start with a fresh environment on
>	the next line.  It is more efficient to correct the scripts
>	rather than turn backwards compatibility on.

Stop using exit, cd, exec in middle of commands.
2019-11-10 09:26:19 +09:00
Nobuyoshi Nakada dfaac2b372
Embed builtin ruby scripts in miniprelude.c
Instead of reading from the files by the full-path at runtime.  As
rbinc files need to be included in distributed tarballs, the
full-paths at the packaging are unavailable at compilation times.
2019-11-09 19:28:45 +09:00
Nobuyoshi Nakada 4dc4b18904
Fixed commit miss 2019-11-09 19:15:10 +09:00
Nobuyoshi Nakada 95aed94d2a
Fixed `#line` directives in miniprelude.c 2019-11-09 18:45:48 +09:00
Nobuyoshi Nakada 4e8336bae8
Share test-bundled-gems-run in common.mk 2019-11-05 00:05:38 +09:00
Nobuyoshi Nakada 07b5fec008
Clean mjit and timestamp directories 2019-10-28 18:15:12 +09:00
Kazuhiro NISHIYAMA 58e2ca31db
Use `_` instead of `_n_` 2019-10-18 20:24:36 +09:00
Nobuyoshi Nakada e50b8949fa
Suppress numbered parameter warnings 2019-10-18 14:59:26 +09:00
Benoit Daloze a27dc83113 Pass $(XRUBY) to test-bundled-gems.rb since RbConfig.ruby is incorrect for miniruby 2019-09-29 13:57:54 +02:00
Benoit Daloze 4096e4b08c Move the logic to test bundled gems to Ruby code
* Writing shell scripts in a Makefile is very error-prone.
* TEST_BUNDLED_GEMS_ALLOW_FAILURES seemed to not work before.
2019-09-29 13:57:54 +02:00
Nobuyoshi Nakada 8bfc46a9a3
Fixed wrong usage of file2lastrev.rb 2019-09-07 11:59:19 +09:00
卜部昌平 a569bc09e2 add include/ruby/backward/cxxanyargs.hpp
Compilation of extension libraries written in C++ are reportedly
broken due to https://github.com/ruby/ruby/pull/2404

The root cause of this issue was that the definition of ANYARGS
differ between C and C++, and that of C++ is incompatible with the
updated ones.

We are using the incompatibility against itself.  In C++ two distinct
function prototypes can be overloaded.  We provide the old, ANYARGSed
prototypes in addition to the current granular ones; and let the
older ones warn about types.
2019-09-06 15:50:58 +09:00
Nobuyoshi Nakada 2614653622
Moved INCFLAGS to XCFLAGS from CPPFLAGS as well as mswin
Rules which have used CPPFLAGS will need XCFLAGS or INCFLAGS now.
2019-08-26 16:54:10 +09:00
卜部昌平 48131a4673 rb_mjit_header.h is not worth documenting [ci skip]
This is an auto-generated header file that does not include anything
interesting.  Should skip generating CAPI documents.
2019-08-26 13:01:58 +09:00
Nobuyoshi Nakada 5108a5dd7f
test-bundled-gems-run: Respect -k option 2019-07-24 12:13:07 +09:00
Nobuyoshi Nakada a39f218f22
Reduced duplicate commands in test-bundled-gems-run 2019-07-24 11:56:17 +09:00
Samuel Williams 7291fef55c
Improve build process and coroutine implementation selection. 2019-07-18 20:54:54 +12:00
Nobuyoshi Nakada dcb8c41a1e
Added depend files 2019-07-14 01:31:29 +09:00
Nobuyoshi Nakada f28450c118
Substitue suffixes with dot 2019-07-01 21:31:18 +09:00
Nobuyoshi Nakada babaad1065
Use configured ASMEXT 2019-07-01 20:05:06 +09:00
Nobuyoshi Nakada c7477c3e1f
Moved Makefile.in under template 2019-06-07 09:09:58 +09:00
Nobuyoshi Nakada 200c840b95
Revert "Moved Makefile.in under template"
This reverts commits:
* 6f9d5fafe0
* bb3c89b643

And remove the dependency of Makefile on Makefile.in
transitionally.
2019-06-07 09:03:25 +09:00
Nobuyoshi Nakada 6f9d5fafe0
Moved Makefile.in under template 2019-06-07 08:44:37 +09:00
nobu 4cfc6cedc4 template/prelude.c.tmpl: allow UTF-8 characters
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@67617 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2019-04-19 10:45:16 +00:00
nobu 14626ed20a fake.rb.in: split by whitespaces not to be affected by -F option
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@67609 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2019-04-18 22:30:01 +00:00
duerst c604219e8d change lib/unicode_normalize/tables.rb to single item per line to make diffs shorter
* template/unicode_norm_gen.tmpl: Change formatting of output to produce only a
  single item (or range) for each line to make future diffs shorter and easier
  to understand and check.

* lib/unicode_normalize/tables.rb: output of the above

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@67439 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2019-04-04 23:40:48 +00:00
nobu 241dced625 Disable tailcall optimization [Bug #15303]
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@66349 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2018-12-12 05:46:13 +00:00
mrkn 5cae104e51 Let sub-directory exts depend on their parent ext
* ext/extmk.rb: Let sub-directory exts depend on their parent ext.

* template/exts.mk.tmpl: ditto.

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@66117 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2018-12-01 09:29:14 +00:00
nobu c878cf5030 Moved REVISION_FORCE before uncommon.mk
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@65704 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2018-11-13 06:16:56 +00:00
nobu c818b2fcf4 ruby-runner.c: enable MJIT_SEARCH_BUILD_DIR
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@65588 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2018-11-07 04:02:14 +00:00
eregon 35f2b71ce9 Fix template/fake.rb.in if ENV["RUBYOPT"] is nil
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@64568 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2018-08-27 14:33:10 +00:00
eregon 5e9cd5208e Fix template/fake.rb.in when external and internal encodings are set
* To be able to run spec/ruby/command_line/dash_encoding_spec.rb
  with the in-repo build.

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@64567 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2018-08-27 14:25:14 +00:00
shyouhei d83536c980 reduce copy & paste
We see several occurrence of "diagnostic push/pop" so why not
make them macros.  Tested on GCC8 / Clang 6.

Note that ruby.h is intentionally left untouched because we don't
want to introduce new public macros.


git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@64118 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2018-07-30 07:07:48 +00:00
nobu b03c1d087b fake.rb.in: duplicated RUBYOPT
* template/fake.rb.in: removed duplicated options in RUBYOPT.

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@63834 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2018-07-03 04:43:27 +00:00
mame 301fa452f7 Remove flip-flop usages from build scripts
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@63669 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2018-06-15 08:53:17 +00:00
nobu dfdd556255 Bootstrapping ruby runtime might not have RubyVM::MJIT defined.
[Fix GH-1891]

From: U-DESKTOP-RLT5UQ8\moriyoshi <mozo@mozo.jp>

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@63664 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2018-06-15 00:06:33 +00:00
nobu 9fd0858c3b fake.rb: fix RUBY_DESCRIPTION for MJIT
* template/fake.rb.in: switch RUBY_DESCRIPTION at runtime
  depending on the MJIT status.

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@63523 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2018-05-29 23:28:50 +00:00
nobu 0342fcbd51 fake.rb: fix RUBY_DESCRIPTION for MJIT
* template/fake.rb.in: reflect MJIT to RUBY_DESCRIPTION.

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@63522 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2018-05-29 08:47:07 +00:00
nobu 6916130566 parse.y: NUL-terminate ruby_sourcefile
* parse.y (yycompile): in some cases (warning, error, dtrace,...),
  ruby_sourcefile is expected to be NUL-terminated, so ensure it.

* template/prelude.c.tmpl (prelude_name): NUL-terminate to get rid
  of copying static data.

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@62841 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2018-03-19 14:12:00 +00:00
nobu bb3db69e2a configure.ac: library options to MAINLIBS
* configure.ac (MAINLIBS): moved library options for main program
  and static libruby, and append MAINLIBS to LIBRUBYARG_STATIC, as
  these libraries are not needed for linking to shared libruby.
  [ruby-core:85882] [Bug #14422]

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@62627 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2018-03-02 01:37:53 +00:00
nobu 14693ba549 Escape MINIRUBY in --make-flags to extmk.rb
If MINIRUBY had arguments, which is the case of cross compiling
they wouldn't be parsed correctly and compiling would fail as a RUBY
without arguments would then be present in the Makefile's in ext/*
[ruby-core:85620] [Bug #14486] [Fix GH-1819]

Author:    Carl Hörberg <carl.hoerberg@gmail.com>

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@62479 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2018-02-19 01:45:17 +00:00
nobu 4b8719c1cd MJIT header for multiarch
* configure.ac: MJIT_HEADER_INSTALL_DIR to rubyarchhdrdir to
  support multiarch.

* Makefile.in (MJIT_HEADER_INSTALL_DIR): configured by multiarch.

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@62320 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2018-02-08 15:19:32 +00:00
nobu 88035b9979 mjit headers for universal binary
* common.mk (MJIT_HEADER, MJIT_MIN_HEADER): added hook to separate
  intermediate headers per archs.

* defs/gmake.mk: build mjit headers per -arch options, and then
  merge the headers with `#ifdef`s.

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@62245 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2018-02-06 03:19:42 +00:00
hsbt 4b190c4852 Fix a typo.
* template/unicode_norm_gen.tmpl: ouput -> output

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@61791 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2018-01-12 13:05:09 +00:00
shyouhei f6ea376317 delete tool/instruction.rb (2nd try)
Previous commit changed insns.def format. Now is the time for its
generators. In doing so I chose to modernize the system, not just
patch.  My attempt includes

- extensive use of Onigumo regular expressions
- split from one big file (instruction.rb) into separated MVC
- partial view

Also, let me take this opportunity to kill old unused features
such as

- stack caching
- minsns / yasmdata which are never seriously used
- yarvarch document generation (moved to doc/)
- vast majority of unused arguments to insns2vm.rb

This commit generates VM source codes that cleanly compile, and
the generated binary passes tests.  At least for me.

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@61784 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2018-01-12 08:38:09 +00:00
shyouhei 5ad95486e6 merge revisions 61753:61750 61747:61740 61737:61728
Revert all the VM generator rewrites; requested by naruse


git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@61755 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2018-01-10 01:53:24 +00:00
shyouhei 55317a74f7 delete tool/instruction.rb
Previous commit changed insns.def format. Now is the time for its
generators. In doing so I chose to modernize the system, not just
patch.  My attempt includes

- extensive use of Onigumo regular expressions
- split from one big file (instruction.rb) into separated MVC
- partial view

Also, let me take this opportunity to kill old unused features
such as

- stack caching
- minsns / yasmdata which are never seriously used
- yarvarch document generation (moved to doc/)
- vast majority of unused arguments to insns2vm.rb

This commit generates VM source codes that cleanly compile, and
the generated binary passes tests.  At least for me.

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@61733 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2018-01-09 13:30:31 +00:00
nobu d68a3d3bc1 insns_info.inc.tmpl: split rb_vm_insn_name_info
* template/insns_info.inc.tmpl (rb_vm_insn_name_info): split
  instruction names pool not to exceed C90 limit.

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@61723 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2018-01-09 12:26:23 +00:00
mame 92b81dc597 make rb_iseq_new* accept rb_ast_body_t instead of NODE*
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@61609 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2018-01-05 08:59:22 +00:00
mame 503b858cef node.h: define rb_ast_body_t and restructure rb_ast_t
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@61608 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2018-01-05 08:59:20 +00:00
nobu 9edca48cff insns_info.inc.tmpl: share large tablese
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@61590 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2018-01-04 01:46:01 +00:00
nobu 7acd7b2771 insns_info.inc: position independent
* template/insns_info.inc.tmpl (insn_name_info): make position
  independent for large strings.

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@61589 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2018-01-04 01:30:20 +00:00
shyouhei dfb24be6c4 string literal longer than 509 characters is a C99ism
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@61552 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2018-01-02 06:41:49 +00:00
nobu d0afbff3b0 prelude.c.tmpl: get rid of warnings on old gcc
* template/prelude.c.tmpl: ignore missing-field-initializers on
  old gcc, e.g. 4.4, which does not support pushing/popping
  diagnostics.

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@61524 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2017-12-31 12:21:53 +00:00
nobu de11e472b4 prelude.c.tmpl: get rid of errors with old gcc
* template/prelude.c.tmpl: moved diagnostic pragmas outside
  prelude_eval() for very old gcc.  [ruby-core:84449] [Bug #14234]

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@61478 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2017-12-25 23:59:56 +00:00
nobu d66f2d4443 prelude.c.tmpl: static literals
* template/prelude.c.tmpl (PRELUDE_STR): make string objects with
  static literals not to copy them.

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@61460 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2017-12-25 02:42:13 +00:00
nobu d9c76c5bd8 prelude.c.tmpl: fix optimization options
* template/prelude.c.tmpl (prelude_eval): fix optimization
  options.  trace_instruction member has been removed.  filled
  coverage_enabled and debug_level members instead.

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@61459 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2017-12-25 02:09:14 +00:00
nobu 9fbd48ee71 prelude.c.tmpl: fix line number
* template/prelude.c.tmpl (Init_prelude): fix line number of
  preludes.  line of prelude_eval is an int, not a VALUE.

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@61042 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2017-12-06 05:22:19 +00:00
nobu 01830719f6 fix for emoji-data.txt
* common.mk: download emoji-data.txt.  As emoji data files are
  located in a separate directory in Unicode.org site, reearranged
  Unicode data files directories same as the site.

* tool/enc-unicode.rb (get_file): search emoji data files in the
  second argument path.

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@60977 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2017-12-02 03:12:51 +00:00
nobu a8a25b36f1 prelude.c.tmpl: escape comments
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@60955 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2017-12-01 04:27:32 +00:00
nobu b7a908f61b prelude.c.tmpl: split prelude code
* template/prelude.c.tmpl: split prelude code into blocks so that
  each elements do not exceed the string literal size limit in
  C89.

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@60953 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2017-12-01 03:54:50 +00:00
usa b4070513dd revert r60873
* template/prelude.c.tmpl (translate): revert r60873 because when some errors or
  warnings are shown their line numbers are shifted.


git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@60950 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2017-12-01 01:29:50 +00:00
usa afa10bd125 Skip comment lines
* template/prelude.c.tmpl (translate): empty (only LF) lines are not necessary.
  so skip them, but for safety only when they are made from comment line.


git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@60873 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2017-11-21 08:48:07 +00:00
nobu 324b6d306d iseq.c: operand lvar
* iseq.c (rb_insn_operand_intern): show local variable operand
  name in unified instructions.

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@60732 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2017-11-09 23:08:01 +00:00
ko1 85fcaf025d * node.h (ast_t): renamed to `rb_ast_t`.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@60565 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2017-10-29 15:51:23 +00:00
mame e35fe8d11b Revert "Revert "Manage AST NODEs out of GC""
This re-introduces r60485.
This reverts commit 5a176b75b1.

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@60488 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2017-10-27 16:44:57 +00:00
mame 5a176b75b1 Revert "Manage AST NODEs out of GC"
This reverts commit 620ba74778.

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@60486 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2017-10-27 16:02:34 +00:00
mame 620ba74778 Manage AST NODEs out of GC
NODEs in AST are no longer objects managed by GC.  This change will
remove the restriction imposed by the GC.  For example, a NODE can use
more than five words (this is my primary purpose; we want to store the
position data for each NODE, for coverage library), or even a NODE can
have variable length (some kinds of NODEs have unused fields).
To do this, however, we need more work, since Ripper still uses T_NODE
objects managed by the GC.

The life time of NODEs is more obvious than other kinds of objects; they
are created at parsing, and they become disused immediately after
compilation.  This change releases all NODEs by a few `xfree`s after
compilation, so performance will be improved a bit.  In extreme example,
`eval("x=1;" * 10000000)` runs much faster (40 sec. -> 7.8 sec. on my
machine).

The most important part of this change is `ast_t` struct, which has
three contents: (1) NODE buffer (malloc'ed memory), (2) a reference to
the root NODE, and (3) an array that contains objects that must be
marked during parsing (such as literal objects).  Some functions that
had received `NODE*` arguments, must now receive `ast_t*`.

* node.c, node.h: defines `ast_t` struct and related operations.
* gc.c, internal.h: defines `imemo_ast`.
* parse.y: makes `parser_params` struct have a reference to `ast_t`.
  Instead of `rb_node_newnode`, use `rb_ast_newnode` to create a NODE.
* iseq.c, load.c, ruby.c, template/prelude.c.tmpl: modifies some
  functions to handle `ast_t*` instead of `NODE*`.
* test/ruby/test_gc.rb: ad-hoc fix for a failed test.  The test assumes
  GC eden is increased at startup by NODE object creation.  However,
  this change now create no NODE object, so GC eden is not necessarily
  increased.

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@60485 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2017-10-27 15:59:02 +00:00
nobu ae0eea21bf fix missing variables in ruby.pc
* configure.ac (LIBRUBY_SO): get rid of referrence to
  LIBRUBY_SONAME which is not present in ruby.pc.

* template/ruby.pc.in (RUBY_API_VERSION, SOEXT): add new
  variables.  [ruby-core:83208] [Bug #14002]

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@60187 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2017-10-16 04:15:19 +00:00
nobu c8d45bdd59 verconf.h.tmpl: site and vendor directories
* template/verconf.h.tmpl: disable site and vendor directories
  when removed.  based on the path by arnoldwald (arnold w) at
  [ruby-core:81563].  [Bug #13631]

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@60141 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2017-10-09 03:08:02 +00:00
nobu 623cf29787 sizes.c.tmpl: prototype
* template/sizes.c.tmpl (Init_limits): turned a K&R style
  declaration into a prototype declaration.

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@60065 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2017-09-29 23:41:19 +00:00
nobu 1d44d10b48 ruby-runner.c: RUBYLIB
* ruby-runner.c (insert_env_path): extracted the function which
  insert path list to an environment variable.

* ruby-runner.c (main): append library paths to RUBYLIB.

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@60006 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2017-09-24 01:48:25 +00:00
nobu 84bc175cab pack insn_operand_info and insn_len_info
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@59638 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2017-08-22 04:40:16 +00:00
nobu a4d650274d pack insns_name_info
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@59637 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2017-08-22 04:37:08 +00:00
nobu 7735c1f5fe tool/instruction.rb: move logics to templates
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@59636 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2017-08-22 04:22:01 +00:00
nobu 1f89414c20 insns.inc.tmpl: ensure info size
* template/insns.inc.tmpl (ASSERT_VM_INSTRUCTION_SIZE): static
  assertion for VM instruction info tables.

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@59635 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2017-08-22 03:07:01 +00:00
svn 22224a45df * remove trailing spaces.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@59390 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2017-07-22 06:30:54 +00:00
yugui 7b19e6f3fd Add documents
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@59389 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2017-07-22 06:30:53 +00:00
nobu 2abf6a3474 * template/exts.mk.tmpl: extract SUBMAKEOPTS from sub exts.mk files too. [Bug #13730]
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@59288 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2017-07-08 12:31:55 +00:00
nobu 9ab667b856 exts.mk.tmpl: fix multiple rubies
* template/exts.mk.tmpl: get rid of making multiple rubies
  simultaneously.  it can cause making libruby in parallel.

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@58711 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2017-05-14 03:33:01 +00:00
naruse ece9698d73 suppress warning: shadowing outer local variable
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@58460 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2017-04-23 16:19:22 +00:00
nobu 3ca61bb04e exts.mk: refine notes [Feature #13302]
* ext/extmk.rb: split notes into header and footer, which are
  common, from bodies which are unique for each extensions.

* template/exts.mk.tmpl: now each notes are not one line, should
  not unique.

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@58425 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2017-04-21 02:43:25 +00:00
nobu 23e481e390 common.mk: separate note
* common.mk (build-ext): separate note from building extensions,
  not to be intermingled.  [ruby-core:80759] [Feature #13302]

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@58414 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2017-04-20 08:31:20 +00:00
nobu b58a30e1c1 extmk.rb: fail for mandatory libraries
* ext/extmk.rb: fail if a mandatory extension library failed to
  configure.  [ruby-core:80759] [Feature #13302]

* template/exts.mk.tmpl: move `exit` at the end.

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@58412 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2017-04-20 08:13:16 +00:00
stomar 0c10564dd9 nodoc UnicodeNormalize module
* lib/unicode_normalize/normalize.rb: [DOC] nodoc the
  internal UnicodeNormalize module.
* lib/unicode_normalize/tables.rb: ditto.
* template/unicode_norm_gen.tmpl: ditto.

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@58329 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2017-04-12 18:07:32 +00:00
nobu e4262e991d Freeze RbConfig::SIZEOF and RbConfig::LIMITS
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@58261 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2017-04-06 02:33:40 +00:00
nobu 489776e284 Rename RbConfig::Limits as RbConfig::LIMITS
* template/limits.c.tmpl (Init_limits): rename RbConfig::Limits as
  RbConfig::LIMITS, constants other than class or module are all
  uppercase with underscores by convention.

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@58260 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2017-04-06 02:10:40 +00:00
nobu c527fa1341 exts.mk.tmpl: note footer [ci skip]
* template/exts.mk.tmpl: place note footer message at the end.

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@58226 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2017-03-31 07:34:47 +00:00
nobu 3a520acec3 MINIRUBY for cross-compling
* template/configure-ext.mk.tmpl (EXTMK_ARGS): add MINIRUBY for
  cross-compling, which is used in extmk.rb.

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@57764 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2017-03-03 06:22:47 +00:00
nobu 600e942bd4 Makefile.in: by exts.mk
* Makefile.in (clean-ext): recurse by exts.mk in parallel first.

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@57729 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2017-02-27 08:23:18 +00:00
nobu 58e97c4e6d parse.y: TOKEN2ID
* parse.y (TOKEN2ID): add macro which maps static tokens to IDs.

* template/id.h.tmpl (TOKEN2*ID, DEFINE_*ID_FROM_TOKEN): separate
  into macros, token to ID mapping and enum definitions.

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@57598 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2017-02-11 02:14:06 +00:00
nobu 92b710e64b MFLAGS for nmake
* common.mk (mflags): pass make flags to sub-makes, for nmake
  which cannot pass them by the environment variable.

* defs/gmake.mk (mflags): filter out -j option for sub-makes.

* template/exts.mk.tmpl (MFLAGS): extract MFLAGS from sub extmk
  files for nmake.

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@57594 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2017-02-10 06:12:22 +00:00
nobu c2310e8598 common.mk: remove explicit MFLAGS
It is unnecessary to pass MFLAGS to sub-makes, because it is
evaluated implicitly if set by make.  GNU make 4.2 sets both of
-jN and --jobserver-auth (or --jobserver-fds in older versions)
options which conflict.  And it is useless for command line macros
since Microsoft NMAKE does not set them.

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@57489 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2017-02-01 04:54:04 +00:00
nobu ed28d151a3 limits.c.tmpl: fallback ULLONG_MAX
* template/limits.c.tmpl (ULLONG_MAX): add a fallback definition.
  On old CentOS lacks ULLONG_MAX.

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@57475 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2017-01-31 02:01:31 +00:00
shyouhei 8ad7429644 make FIXNUM_MAX visible from Ruby
Because our tests now have several places where FIXNUM_MAX is needed,
we decided to provide it along with several other constants.

	* template/limits.c.tmpl: new file, defining RbConfig::Limits

	* ext/rbconfig/sizeof/depend (limits.c): rule to generate limits.c

	* test/-ext-/num2int/test_num2int.rb: use RbConfig::Limits

	* bootstraptest/test_insns.rb: ditto.

	* .gitignore: ignore new generated file.


git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@57465 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2017-01-30 10:12:18 +00:00
nobu b2c9c82cb7 extmk.rb: remove clean and install mode
* ext/extmk.rb (parse_args): remove clean and install mode, now
  configure mode only.

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@57449 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2017-01-28 05:31:25 +00:00
nobu cc33dd2b67 extension gems in static-linked-exts
* template/configure-ext.mk.tmpl: --no-extstatic option to gems.

* template/exts.mk.tmpl: include extension gems.

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@57447 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2017-01-28 05:02:41 +00:00
nobu 658fc3dd26 exts.mk.tmpl: ruby names
* template/exts.mk.tmpl: extract configured ruby names.

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@57444 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2017-01-28 01:43:29 +00:00
naruse ac66222f1f fix typo
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@57442 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2017-01-27 15:32:50 +00:00
nobu dbacbc440f template/exts.mk.tmpl: fix missing dependencies
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@57440 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2017-01-27 07:51:58 +00:00
nobu 88eea2ba69 template/exts.mk.tmpl: consider EXEEXT
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@57439 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2017-01-27 07:23:21 +00:00
nobu df05027c2d exts.mk.tmpl: for not GNU makes
* template/exts.mk.tmpl: use `cd` then `make` instead of `make -C`
  when not GNU make.

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@57438 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2017-01-27 07:16:36 +00:00
nobu 3be16b24f3 configure-ext.mk.tmpl: fix ext build
* template/configure-ext.mk.tmpl: fixed inverted names of target
  and directory, and chomp the last slash.

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@57433 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2017-01-27 02:55:02 +00:00
nobu 72ad0019ba Parallel gem configuration
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@57424 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2017-01-26 08:19:34 +00:00
nobu 48d489030a configure-ext.mk.tmpl: embed macros
* template/configure-ext.mk.tmpl: embed MINIRUBY and SCRIPT_ARGS
  to get rid of quoting problems of nmake.

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@57404 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2017-01-23 04:22:23 +00:00
nobu f41b7517dc Fix for nmake
* common.mk (EXT_MK): use double-quotes and remove SCRIPT_ARGS
  which contains both types of quotes.

* template/configure-ext.mk.tmpl (all): use single-quotes for MAKE
  which is set by nmake and contains spaces in the path. do not
  use SCRIPT_ARGS.

* template/exts.mk.tmpl (all, static): separate dependency lines,
  not to become a default target unintentionally.

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@57403 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2017-01-23 03:51:25 +00:00
nobu abb8fc1b17 configure-ext.mk.tmpl: FORCE
* template/configure-ext.mk.tmpl (FORCE): add missing target for
  BSD make.

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@57402 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2017-01-23 03:43:43 +00:00
nobu 17b748df2b Parallel ext configuration
* ext/configure-ext.mk: configure each directories underneath ext
  in parallel.

* template/exts.mk.tmpl: then collect the results.


git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@57401 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2017-01-23 02:50:23 +00:00
nobu ea87854c52 extinit.c.tmpl: drop after dot
* template/extinit.c.tmpl: drop rest from the first dot in the
  base name of a feature is ignored since r30464.

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@57398 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2017-01-23 02:19:00 +00:00
nobu 78b95b49f8 template/extinit.c.tmpl
* template/extinit.c.tmpl: separate from ext/extmk.rb.

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@57395 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2017-01-22 12:50:36 +00:00
nobu e95eb9584a Keep -jN option
* {cygwin,template}/GNUmakefile.in (MFLAGS, MAKEFLAGS): keep -jN
  option.

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@57383 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2017-01-20 07:45:10 +00:00
naruse 2873edeafb Merge Onigmo 6.0.0
* https://github.com/k-takata/Onigmo/blob/Onigmo-6.0.0/HISTORY
* fix for ruby 2.4: https://github.com/k-takata/Onigmo/pull/78
* suppress warning: https://github.com/k-takata/Onigmo/pull/79
* include/ruby/oniguruma.h: include onigmo.h.
* template/encdb.h.tmpl: ignore duplicated definition of EUC-CN in
  enc/euc_kr.c. It is defined in enc/gb2313.c with CRuby macro.

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@57045 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2016-12-10 17:47:04 +00:00
kazu 72ad249e54 Update comments in prelude.c [ci skip]
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@56448 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2016-10-18 15:40:31 +00:00
kazu 07efce075b Use https instead of http in some URLs
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@56135 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2016-09-11 10:33:36 +00:00
nobu 2ae5e54e62 open Unicode data in binary mode
* tool/enc-unicode.rb (data_foreach): open in binary mode because
  Unicode 9.0.0 contains non-ascii characters.

* template/unicode_norm_gen.tmpl: ditto.

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@55945 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2016-08-16 13:01:30 +00:00
duerst 0ad3557d81 * template/unicode_norm_gen.tmpl: Remove
UnicodeNormalize::UNICODE_VERSION at origin [Feature #12546].


git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@55725 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2016-07-22 01:32:20 +00:00
nobu 60a063d88d Remove -jN option
* {cygwin,template}/GNUmakefile.in (MAKEFLAGS): remove -jN option
  from MAKEFLAGS as well as MFLAGS.

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@55505 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2016-06-26 00:28:13 +00:00
nobu a7dd094791 rbconfig/sizeof: calculate at compilation time
* ext/rbconfig/sizeof/extconf.rb: just check the existence of each
  types, to reduce configuration time, especially cross-compiling.
* template/sizes.c.tmpl: calculate sizes of checked types at
  compilation time.

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@54759 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2016-04-25 05:39:12 +00:00
nobu 75a5dcf170 sizes.c.tmpl: extra semicolon
* template/sizes.c.tmpl (DEFINE): remove extra semicolon.

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@54758 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2016-04-25 05:38:55 +00:00
nobu 7343b492a2 ruby-runner.h
* template/ruby-runner.h.in: separate configured part from
  ruby-runner.c.

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@54572 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2016-04-14 01:30:12 +00:00
nobu 90d6062181 unicode_norm_gen.tmpl: Remove indicator
* template/unicode_norm_gen.tmpl: Remove indicator for
  "frozen_string_literal: true", as r52526.

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@53577 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2016-01-18 12:48:41 +00:00
nobu 4d0e0a3823 id.h.tmpl: no optparse here
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@53443 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2016-01-05 14:07:58 +00:00