File tree Expand file tree Collapse file tree 1 file changed +11
-0
lines changed
src/SPC/builder/unix/library Expand file tree Collapse file tree 1 file changed +11
-0
lines changed Original file line number Diff line number Diff line change 44
55namespace SPC \builder \unix \library ;
66
7+ use SPC \exception \WrongUsageException ;
78use SPC \util \executor \UnixAutoconfExecutor ;
89
910trait unixodbc
1011{
1112 protected function build (): void
1213 {
14+ $ sysconf_selector = match (PHP_OS_FAMILY ) {
15+ 'Darwin ' => match (GNU_ARCH ) {
16+ 'x86_64 ' => '/usr/local/etc ' ,
17+ 'aarch64 ' => '/opt/homebrew/etc ' ,
18+ default => throw new WrongUsageException ('Unsupported architecture: ' . GNU_ARCH ),
19+ },
20+ 'Linux ' => '/etc ' ,
21+ default => throw new WrongUsageException ('Unsupported OS: ' . PHP_OS_FAMILY ),
22+ };
1323 UnixAutoconfExecutor::create ($ this )
1424 ->configure (
1525 '--disable-debug ' ,
1626 '--disable-dependency-tracking ' ,
1727 "--with-libiconv-prefix= {$ this ->getBuildRootPath ()}" ,
1828 '--with-included-ltdl ' ,
29+ "--sysconfdir= {$ sysconf_selector }" ,
1930 '--enable-gui=no ' ,
2031 )
2132 ->make ();
You can’t perform that action at this time.
0 commit comments