[php-src] Issue #11785: '++nothing+crc' is not a recognized feature for this target (ignoring feature) when compiling C language on M1 / M2 mac
| From: | youkidearitai | Date: | Tue, 25 Jul 2023 11:06:02 +0000 |
| Subject: | [php-src] Issue #11785: '++nothing+crc' is not a recognized feature for this target (ignoring feature) when compiling C language on M1 / M2 mac | ||
| Groups: | php.bugs | ||
| Request: | Send a blank email to php-bugs+get-245029@lists.php.net to get a copy of this message | ||
Issue: https://github.com/php/php-src/issues/11785
Author: youkidearitai
### Description
Displays
'++nothing+crc' is not a recognized feature for this target (ignoring
feature) when compiling ext/standard/crc32.c on M1 / M2 mac.
```bash
$ make
/bin/sh /Users/tekimen/src/php-src/libtool --silent --preserve-dup-deps --tag CC --mode=compile cc
-Iext/standard/ -I/Users/tekimen/src/php-src/ext/standard/ -I/Users/tekimen/src/php-src/include
-I/Users/tekimen/src/php-src/main -I/Users/tekimen/src/php-src
-I/Users/tekimen/src/php-src/ext/date/lib -I/opt/homebrew/opt/libiconv/include
-I/opt/homebrew/Cellar/oniguruma/6.9.8/include -I/Users/tekimen/src/php-src/ext/mbstring/libmbfl
-I/Users/tekimen/src/php-src/ext/mbstring/libmbfl/mbfl -I/Users/tekimen/src/php-src/TSRM
-I/Users/tekimen/src/php-src/Zend -D_GNU_SOURCE -fno-common -Wstrict-prototypes -Wall -Wextra
-Wno-unused-parameter -Wno-sign-compare -g -fvisibility=hidden -O0 -DZEND_SIGNALS
-DZEND_ENABLE_STATIC_TSRMLS_CACHE=1 -c /Users/tekimen/src/php-src/ext/standard/crc32.c -o
ext/standard/crc32.lo -MMD -MF ext/standard/crc32.dep -MT ext/standard/crc32.lo
```
Resulted in this output:
```
'++nothing+crc' is not a recognized feature for this target (ignoring feature)
'++nothing+crc' is not a recognized feature for this target (ignoring feature)
```
But I expected this output instead:
```
```
(displays nothing)
I think fix below on ext/standard/crc32.c line no 72, however I don't know well to
#pragma target .
```
72 # pragma clang attribute push(__attribute__((target("crc"))), apply_to=function)
```
### PHP Version
PHP 8.3 (master)
### Operating System
macOS 13.4.1