# This file created by conda-build 3.25.0
# ------------------------------------------------

package:
  name: gcc_impl_linux-64
  version: 13.2.0
source:
  - patches:
      - patches/0021-Hardcode-HAVE_ALIGNED_ALLOC-1-in-libstdc-v3-configur.patch
      - patches/libgomp-support-environ-null.patch
      - patches/new-allow-commands-in-main-specfile.patch
    sha256: 8cb4be3796651976f94b9356fa08d833524f62420d6292c5033a9a26af315078
    url: https://ftp.gnu.org/gnu/gcc/gcc-13.2.0/gcc-13.2.0.tar.gz
build:
  detect_binary_files_with_prefix: false
  ignore_run_exports:
    - __glibc
  missing_dso_whitelist:
    - '*'
  number: 3
  runpath_whitelist:
    - x86_64-conda-linux-gnu/sysroot/lib/libpthread-2.12.2.so
  string: h338b0a0_3
requirements:
  build:
    - binutils_impl_linux-64 2.39 he00db2b_1
    - gcc_bootstrap_linux-64 13.2.0 h4dbdac4_2
    - kernel-headers_linux-64 2.6.32 he073ed8_16
    - ld_impl_linux-64 2.39 hcc3a1bd_1
    - sysroot_linux-64 2.12 he073ed8_16
  host:
    - kernel-headers_linux-64 2.6.32 he073ed8_16
    - libgcc-ng 13.2.0 h807b86a_3
    - libgfortran5 >=13.2.0,<14.0a0
    - libgomp 13.2.0 h807b86a_3
    - libsanitizer 13.2.0 h7e041cc_3
    - libstdcxx-ng 13.2.0 h7e041cc_3
    - sysroot_linux-64 2.12 he073ed8_16
  run:
    - binutils_impl_linux-64 >=2.39
    - libgcc-devel_linux-64 13.2.0 ha9c7c90_103
    - libgcc-ng >=13.2.0
    - libgomp >=13.2.0
    - libsanitizer 13.2.0 h7e041cc_3
    - libstdcxx-ng >=13.2.0
    - sysroot_linux-64
test:
  commands:
    - echo conda_cos6
    - test -f ${PREFIX}/x86_64-conda-linux-gnu/lib/libgomp.so
    - test `readlink ${PREFIX}/x86_64-conda-linux-gnu/lib/libgomp.so` == "../../lib/libgomp.so"
    - test -f ${PREFIX}/bin/x86_64-conda_cos6-linux-gnu-gcc
    - test -f ${PREFIX}/bin/x86_64-conda_cos6-linux-gnu-cpp
    - test -f ${PREFIX}/bin/x86_64-conda-linux-gnu-gcc
    - test -f ${PREFIX}/bin/x86_64-conda-linux-gnu-cpp
    - test ! -f ${PREFIX}/bin/gcc
    - test ! -f ${PREFIX}/bin/cpp
    - CC=$(${PREFIX}/bin/*-gcc -dumpmachine)-gcc
    - ${CC} -Wall tests/aligned_alloc.c -c -o c_aligned.o -v -fsanitize=address
    - ${CC} -Wall tests/aligned_alloc.c -c -o c_aligned.o -v
    - ${CC} -Wall c_aligned.o -o c_aligned -v && ./c_aligned
    - ${CC} -Wall c_aligned.o -o c_aligned -Wl,-rpath,/foo && x86_64-conda-linux-gnu-readelf
      -d c_aligned | grep RPATH | grep "/foo:${PREFIX}/lib"
    - test -f ${PREFIX}/x86_64-conda-linux-gnu/lib/libgcc_s.so
    - test -f ${PREFIX}/x86_64-conda-linux-gnu/lib/libgomp.spec
    - test -f ${PREFIX}/x86_64-conda-linux-gnu/lib/libsanitizer.spec
    - test -f ${PREFIX}/x86_64-conda-linux-gnu/lib/libasan_preinit.o
  files:
    - tests
  requires:
    - sysroot_linux-64 2.12.*
about:
  home: https://gcc.gnu.org/
  license: GPL-3.0-only WITH GCC-exception-3.1
  summary: GNU C Compiler
extra:
  copy_test_source_files: true
  final: true
  recipe-maintainers:
    - beckermr
    - isuruf
    - timsnyder
    - xhochy
