@@ -6,7 +6,7 @@ PortGroup compiler_blacklist_versions 1.0
6
6
PortGroup active_variants 1.1
7
7
PortGroup conflicts_build 1.0
8
8
9
- epoch 0
9
+ epoch 1
10
10
name gcc13
11
11
12
12
homepage https://gcc.gnu.org/
@@ -62,7 +62,7 @@ depends_lib-append port:cctools \
62
62
port:zlib \
63
63
port:zstd
64
64
depends_run-append port:gcc_select \
65
- path:share/doc/libgcc/README:libgcc
65
+ port:libgcc13
66
66
67
67
depends_skip_archcheck-append gcc_select ld64 cctools
68
68
license_noconflict gmp mpfr ppl libmpc zlib
@@ -340,9 +340,6 @@ proc dylib_list {location} {
340
340
341
341
if {${subport} eq ${libgccname} } {
342
342
343
- # Always provides primary runtime so always in conflict
344
- conflicts libgcc-devel
345
-
346
343
# Activate hack for new libgcc
347
344
# https://trac.macports.org/wiki/PortfileRecipes#deactivatehack
348
345
pre-activate {
@@ -388,88 +385,21 @@ if {${subport} eq ${libgccname}} {
388
385
}
389
386
}
390
387
391
- # http://trac.macports.org/ticket/35770
392
- # http://trac.macports.org/ticket/38814
393
- # While there can be multiple versions of these runtimes in a single
394
- # process, it is not possible to pass objects between different versions,
395
- # so we simplify this by having the libgcc port provide the newest version
396
- # of these runtimes for all versions of gcc to use.
397
- #
398
- # If there is a binary incompatible change to the runtime in a future
399
- # version of gcc, then the latest version of gcc to provide a given ABI
400
- # version should continue to provide a subport for that and older gcc
401
- # versions.
402
-
403
- depends_run
404
- depends_lib-delete port:zlib port:libiconv
405
- depends_build-append {*}${depends_lib}
406
- depends_lib port:zlib port:libiconv
407
-
408
- configure.args-replace \
409
- --libdir=${prefix} /lib/${name} \
410
- --libdir=${prefix} /lib/libgcc
411
-
412
- configure.args-replace \
413
- --with-gxx-include-dir=${prefix} /include/${name} /c++/ \
414
- --with-gxx-include-dir=${prefix} /include/gcc/c++/
415
-
416
- post-destroot {
417
-
418
- # Temporary working dir for dylibs
419
- file mkdir ${destroot}${prefix} /lib/libgcc.merged
420
-
421
- # loop over libs to install
422
- set dylibs [dylib_list ${destroot}${prefix} /lib/libgcc]
423
- foreach dylib ${dylibs} {
424
-
425
- # Different OS versions (e.g. Leopard) or architectures (e.g. PPC) don't produce all the dylibs
426
- # https://trac.macports.org/ticket/40098
427
- # https://trac.macports.org/ticket/40100
428
- if { ![file exists ${destroot}${prefix} /lib/libgcc/${dylib} ] } {
429
- continue
430
- }
431
-
432
- # Move dylib to temp area
433
- move ${destroot}${prefix} /lib/libgcc/${dylib} ${destroot}${prefix} /lib/libgcc.merged
388
+ # No need to build as nothing that isn't provided by libgcc14
389
+ platforms any
434
390
435
- # If needed create versionless sym link to dylib
436
- set dylib_split [split ${dylib} " ." ]
437
- set dylib_nover ${destroot}${prefix} /lib/libgcc.merged/[lindex ${dylib_split} 0].[lindex ${dylib_split} end]
438
- if { ![file exists ${dylib_nover} ] } {
439
- ln -s ${dylib} ${dylib_nover}
440
- }
441
-
442
- # Universal support
443
- if {[variant_exists universal] && [variant_isset universal]} {
444
- foreach archdir [glob ${destroot}${prefix} /lib/libgcc/*/] {
445
- set archdir_nodestroot [string map " ${destroot} / /" ${archdir} ]
446
- if {[file exists ${archdir} /${dylib} ]} {
447
- system " install_name_tool -id ${prefix} /lib/libgcc/${dylib} ${archdir} /${dylib} "
448
- foreach link [glob -tails -directory ${archdir} *.dylib] {
449
- system " install_name_tool -change ${archdir_nodestroot}${link} ${prefix} /lib/libgcc/${link} ${archdir} /${dylib} "
450
- }
451
- system " lipo -create -output ${destroot}${prefix} /lib/libgcc.merged/${dylib} ~ ${destroot}${prefix} /lib/libgcc.merged/${dylib} ${archdir} /${dylib} && mv ${destroot}${prefix} /lib/libgcc.merged/${dylib} ~ ${destroot}${prefix} /lib/libgcc.merged/${dylib} "
452
- }
453
- }
454
- }
455
-
456
- # strip debug symbols to supress debugger warnings:
457
- # http://trac.macports.org/attachment/ticket/34831
458
- if {! [string match *libgcc_ext* ${dylib} ]} {
459
- system " strip -x ${destroot}${prefix} /lib/libgcc.merged/${dylib} "
460
- }
461
- }
462
-
463
- file delete -force ${destroot}${prefix} /bin
464
- file delete -force ${destroot}${prefix} /share
465
- file delete -force ${destroot}${prefix} /lib/libgcc
466
- file delete -force ${destroot}${prefix} /libexec
467
-
468
- move ${destroot}${prefix} /lib/libgcc.merged ${destroot}${prefix} /lib/libgcc
391
+ depends_run path:share/doc/libgcc/README:libgcc
392
+ depends_lib
469
393
470
- # For binary compatibility with binaries that linked against the old libstdcxx port
471
- ln -s libgcc/libstdc++.6.dylib ${destroot}${prefix} /lib/libstdc++.6.dylib
394
+ fetch.type none
395
+ build { }
396
+ use_configure no
397
+ patchfiles
472
398
399
+ destroot {
400
+ set doc_dir ${destroot}${prefix} /share/doc/${subport}
401
+ xinstall -m 755 -d ${doc_dir}
402
+ system " echo ${subport} provides no runtime > ${doc_dir} /README"
473
403
}
474
404
475
405
}
0 commit comments