Commit graph

1060 commits

Author SHA1 Message Date
Paul Kulchenko
e204fc0820
Update redbean If-Modified-Since check to accept same timestamp (#562) 2022-08-21 22:03:30 -07:00
Justine Tunney
b76540105d Release Cosmopolitan v2.0.1 2022-08-21 18:59:20 -07:00
Justine Tunney
14e3025749 Release redbean 2.0.17 2022-08-21 18:35:53 -07:00
Justine Tunney
51fa5535ac Fix regression in Fetch() 2022-08-21 18:32:57 -07:00
Justine Tunney
bea0b55576 Fix If-Modified-Since regression 2022-08-21 18:05:05 -07:00
Justine Tunney
57b39d8793 Revert recent fixupobj.com change 2022-08-21 17:33:54 -07:00
Justine Tunney
d52170ca34 Avoid zip -d redbean.com foo issue on Windows 2022-08-21 16:32:57 -07:00
Justine Tunney
bf757c4646 Fix _Thread_local with fork() on Windows 2022-08-21 15:51:44 -07:00
Justine Tunney
99a92048b4 Get awk to build and make it hackable 2022-08-21 13:39:20 -07:00
Justine Tunney
2f1679e5cf Import The One True Awk
https://github.com/onetrueawk/awk
2022-08-21 13:38:12 -07:00
Justine Tunney
ee49b71be2 Fix build 2022-08-21 01:11:14 -07:00
Justine Tunney
73845be1f0 Restore zip.com and .symtab files
This change restores the .symtab symbol table files in our flagship
programs (e.g. redbean.com, python.com) needed to show backtraces. This
also rolls back earlier changes to zip.com w.r.t. temp directories since
the right way to do it turned out to be the -b DIR flag.

This change also improves the performance of zip.com. It turned out
mmap() wasn't being used, because zip.com was assuming a 4096-byte
granularity, but cosmo requires 65536. There was also a chance to speed
up stdio scanning using the unlocked functions.
2022-08-21 00:17:20 -07:00
Justine Tunney
35203c0551 Do some string library work 2022-08-20 22:17:14 -07:00
Justine Tunney
83d41e4588 Clean up some code 2022-08-20 12:32:51 -07:00
Paul Kulchenko
a51edaa0db
Remove .heartbeat.lua from redbean (#554)
It's been replaced by `OnServerHeartbeat`.
2022-08-20 01:31:58 -07:00
Justine Tunney
d76dfadc7a Reduce GNU Make latency 17% for cosmo
fgets() is now 4x faster which makes Make 2% faster. Landlock Make now
has a builtin $(uniq ...) function that uses critbit trees rather than
functional programming. Since uniq is the most important function this
optimization makes our cold start latency 15% faster.
2022-08-19 15:29:24 -07:00
Justine Tunney
8835b82a7c Avoid sandboxing directory prerequisites
Landlock Make will no longer sandbox prerequisites that end with a
trailing slash. This means you can use use directory prerequisites
for detecting deleted files when using using globbing, without the
effect of unveiling the entire directory. When you do want make to
unveil directories, you can omit the trailing slash.
2022-08-19 13:02:25 -07:00
Daniil Kulchenko
2827df688a
Fix M1 Rosetta signal handling (#455) (#553)
Rosetta does something strange to the signal handling registers but
setting SA_SIGINFO prevents the issue from happening. Set the flag
on XNU to work around the issue.
2022-08-19 13:00:50 -07:00
Justine Tunney
1ce101c5a5 Release Cosmopolitan 2.0 2022-08-18 18:22:16 -07:00
Justine Tunney
fcbf64b906 Remove warnings from amalgamation header 2022-08-18 18:16:53 -07:00
Justine Tunney
283fd9e590 Pledge tty on Python ioctl test 2022-08-18 18:02:49 -07:00
Justine Tunney
6bb9ce553e Remove some includes 2022-08-18 17:46:34 -07:00
Justine Tunney
75832f7379 Polyfill sysinfo() a ilttle bit on BSDs 2022-08-18 15:53:11 -07:00
Gavin Hayes
897e33ccc4
Fix stdio fmt of "%.0e" and "%.0g" (#544)
* Fix %.0e by always rounding even if precision is 0
* Fix %.0g by treating it the same as %.1g
* Fix %g tests to match glibc, add more tests
2022-08-18 15:53:07 -07:00
Gavin Hayes
27416e7dd6
Add fake support for locale="" (#546) 2022-08-18 15:51:23 -07:00
Gavin Hayes
6c3048821c
Add libc/str/nltypes.h to langinfo.h (#549) 2022-08-18 15:45:56 -07:00
Harmen Stoppels
2d5f2bebb0
Remove unused variable (#536) 2022-08-18 15:42:48 -07:00
Jared Miller
db509ee158
LaunchBrowser by default in redbean-demo.com (#547) 2022-08-18 12:01:44 -07:00
Gavin Hayes
640b9bfb48
Add test/libc/mem/putenv_test.c (#545) 2022-08-18 00:11:35 -07:00
Justine Tunney
30e1c5bca9 Add statfs() and fstatfs() to redbean unix module 2022-08-17 23:27:17 -07:00
Justine Tunney
2d479f7b11 Update definitions with latest help.txt changes 2022-08-17 21:57:08 -07:00
Justine Tunney
d7372e651d Fix arg redbean lua definition 2022-08-17 21:23:44 -07:00
Justine Tunney
8e176fb026 Reduce build graph by another 14 percent
That's a 37% reduction total from what it was on 2022-05-23.
2022-08-17 20:01:21 -07:00
Justine Tunney
c2211c9e63 Polyfill statfs() and fstatfs() on Windows 2022-08-17 19:01:51 -07:00
Justine Tunney
f7ee9d7d99 Polyfill statfs() and fstatfs() on BSD distros 2022-08-17 14:54:03 -07:00
Gavin Hayes
e3fe127ccd
Change sys_lseek return value from i32 to i64 (#539) 2022-08-17 14:21:24 -07:00
Danny Robinson
fbdab72e3b
Create definitions.lua (#540) 2022-08-17 14:20:07 -07:00
Gavin Hayes
1f735a4af3
Prevent NPE after clearenv (#542) 2022-08-17 14:15:23 -07:00
Justine Tunney
e5f705ace3 Fix redbean doc errors reported by stellartux 2022-08-17 00:10:17 -07:00
Justine Tunney
a1aaf23dc1 Add more apis to redbean unix module
- Document unix.fcntl()
- Add POSIX Advisory Locks
- Add mask parameter to unix.poll()
- Add lowest parameter to unix.dup()
2022-08-16 23:23:34 -07:00
Justine Tunney
ce588dd56b Release pledge.com 1.7 and landlockmake.com 1.3
- pledge("chown") now supported
- pledge("stdio") now allows killing self
- Write tests for pselect() and ppoll()
2022-08-15 19:52:00 -07:00
Justine Tunney
255d834f8f Put ape.macho back in build/bootstrap 2022-08-15 15:45:13 -07:00
Justine Tunney
f0701d2a24 Make improvements
- Polyfill pselect() on Windows
- Add -O NOFILE flag to pledge.com
- Polyfill ppoll() on NetBSD, XNU, and Windows
- Support negative numbers and errno in sizetol()
- Add .RSS, .NOFILE, and .MAXCORE to Landlock Make
- Fix issue with .PLEDGE preventing touching of output files
- Add __watch() function (like ftrace) for logging memory changes
2022-08-15 15:20:36 -07:00
Justine Tunney
d3b599a796 Remove ANSI WIN32 functions and undocumented ADVAPI32 2022-08-15 09:01:40 -07:00
Justine Tunney
0cf9716039 Improve build latency of repository 2022-08-14 22:19:46 -07:00
Justine Tunney
7ab15e0b23 Add .PLEDGE/.CPU/.MEMORY/etc. to Landlock Make 1.2 2022-08-14 20:16:44 -07:00
Justine Tunney
6c0bbfac4a Fix some bugs 2022-08-14 13:28:07 -07:00
tkchia
5584f6adcf
Improve detection of boot media on bare metal (#535)
hello.com now starts up correctly on QEMU when run as a hard
disk image.
2022-08-14 08:32:58 -07:00
Justine Tunney
d36d0634db Add automatic TMPDIR setup/teardown to GNU Make
We now guarantee TMPDIR will be defined on a per build rule basis. It'll
be an absolute path. It'll be secure and unique. It'll be rm -rf'd after
the last shell script line in your build rule is executed. If $TMPDIR is
already defined, then it'll be created as a subdirectory of your $TMPDIR
and then replace the variable with the new definition. The Landlock Make
repository will be updated with examples shortly after this change which
shall be known as Landlock Make 1.1.1.

See #530
2022-08-14 02:03:41 -07:00
Justine Tunney
e1699c5b68 Fix issue with stack creation on OpenBSD 2022-08-14 01:19:58 -07:00