ffi 1.1.5 → 1.15.5
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +7 -0
- data/CHANGELOG.md +338 -0
- data/COPYING +49 -0
- data/Gemfile +14 -0
- data/LICENSE +21 -11
- data/LICENSE.SPECS +22 -0
- data/README.md +136 -0
- data/Rakefile +149 -154
- data/ext/ffi_c/AbstractMemory.c +133 -57
- data/ext/ffi_c/AbstractMemory.h +21 -12
- data/ext/ffi_c/ArrayType.c +27 -14
- data/ext/ffi_c/ArrayType.h +21 -12
- data/ext/ffi_c/Buffer.c +29 -25
- data/ext/ffi_c/Call.c +154 -125
- data/ext/ffi_c/Call.h +43 -20
- data/ext/ffi_c/ClosurePool.c +100 -42
- data/ext/ffi_c/ClosurePool.h +24 -13
- data/ext/ffi_c/DynamicLibrary.c +47 -28
- data/ext/ffi_c/DynamicLibrary.h +70 -12
- data/ext/ffi_c/Function.c +119 -167
- data/ext/ffi_c/Function.h +23 -19
- data/ext/ffi_c/FunctionInfo.c +55 -25
- data/ext/ffi_c/LastError.c +70 -21
- data/ext/ffi_c/LastError.h +21 -12
- data/ext/ffi_c/LongDouble.c +15 -9
- data/ext/ffi_c/LongDouble.h +21 -16
- data/ext/ffi_c/MappedType.c +22 -15
- data/ext/ffi_c/MappedType.h +21 -12
- data/ext/ffi_c/MemoryPointer.c +58 -33
- data/ext/ffi_c/MemoryPointer.h +22 -19
- data/ext/ffi_c/MethodHandle.c +49 -50
- data/ext/ffi_c/MethodHandle.h +24 -14
- data/ext/ffi_c/Platform.c +28 -62
- data/ext/ffi_c/Platform.h +21 -12
- data/ext/ffi_c/Pointer.c +63 -46
- data/ext/ffi_c/Pointer.h +22 -19
- data/ext/ffi_c/Struct.c +198 -80
- data/ext/ffi_c/Struct.h +33 -18
- data/ext/ffi_c/StructByValue.c +23 -20
- data/ext/ffi_c/StructByValue.h +21 -12
- data/ext/ffi_c/StructLayout.c +184 -39
- data/ext/ffi_c/Thread.c +73 -270
- data/ext/ffi_c/Thread.h +32 -35
- data/ext/ffi_c/Type.c +26 -32
- data/ext/ffi_c/Type.h +24 -10
- data/ext/ffi_c/Types.c +28 -20
- data/ext/ffi_c/Types.h +25 -16
- data/ext/ffi_c/Variadic.c +78 -39
- data/ext/ffi_c/compat.h +25 -17
- data/ext/ffi_c/extconf.rb +68 -31
- data/ext/ffi_c/ffi.c +27 -20
- data/ext/ffi_c/libffi/.appveyor.yml +66 -0
- data/ext/ffi_c/libffi/.gitattributes +4 -0
- data/ext/ffi_c/libffi/.github/issue_template.md +10 -0
- data/ext/ffi_c/libffi/.gitignore +38 -0
- data/ext/ffi_c/libffi/.travis/ar-lib +270 -0
- data/ext/ffi_c/libffi/.travis/bfin-sim.exp +58 -0
- data/ext/ffi_c/libffi/.travis/build-cross-in-container.sh +14 -0
- data/ext/ffi_c/libffi/.travis/build-in-container.sh +12 -0
- data/ext/ffi_c/libffi/.travis/build.sh +142 -0
- data/ext/ffi_c/libffi/.travis/compile +351 -0
- data/ext/ffi_c/libffi/.travis/install.sh +71 -0
- data/ext/ffi_c/libffi/.travis/m32r-sim.exp +58 -0
- data/ext/ffi_c/libffi/.travis/moxie-sim.exp +60 -0
- data/ext/ffi_c/libffi/.travis/or1k-sim.exp +58 -0
- data/ext/ffi_c/libffi/.travis/powerpc-eabisim.exp +58 -0
- data/ext/ffi_c/libffi/.travis/site.exp +27 -0
- data/ext/ffi_c/libffi/.travis/wine-sim.exp +55 -0
- data/ext/ffi_c/libffi/.travis.yml +83 -0
- data/ext/ffi_c/libffi/{ChangeLog → ChangeLog.old} +6366 -3559
- data/ext/ffi_c/libffi/LICENSE +1 -1
- data/ext/ffi_c/libffi/LICENSE-BUILDTOOLS +353 -0
- data/ext/ffi_c/libffi/Makefile.am +123 -169
- data/ext/ffi_c/libffi/Makefile.in +1243 -1003
- data/ext/ffi_c/libffi/README.md +486 -0
- data/ext/ffi_c/libffi/acinclude.m4 +387 -0
- data/ext/ffi_c/libffi/autogen.sh +2 -0
- data/ext/ffi_c/libffi/config.guess +690 -504
- data/ext/ffi_c/libffi/config.sub +1353 -1207
- data/ext/ffi_c/libffi/configure +7308 -2449
- data/ext/ffi_c/libffi/configure.ac +178 -259
- data/ext/ffi_c/libffi/configure.host +311 -4
- data/ext/ffi_c/libffi/doc/Makefile.am +3 -0
- data/ext/ffi_c/libffi/doc/Makefile.in +815 -0
- data/ext/ffi_c/libffi/doc/libffi.texi +455 -58
- data/ext/ffi_c/libffi/doc/version.texi +4 -4
- data/ext/ffi_c/libffi/fficonfig.h.in +37 -13
- data/ext/ffi_c/libffi/generate-darwin-source-and-headers.py +201 -0
- data/ext/ffi_c/libffi/include/Makefile.am +3 -3
- data/ext/ffi_c/libffi/include/Makefile.in +196 -75
- data/ext/ffi_c/libffi/include/ffi.h.in +163 -67
- data/ext/ffi_c/libffi/include/ffi_cfi.h +55 -0
- data/ext/ffi_c/libffi/include/ffi_common.h +39 -12
- data/ext/ffi_c/libffi/install-sh +207 -209
- data/ext/ffi_c/libffi/libffi.map.in +76 -0
- data/ext/ffi_c/libffi/libffi.pc.in +3 -2
- data/ext/ffi_c/libffi/libffi.xcodeproj/project.pbxproj +997 -0
- data/ext/ffi_c/libffi/libtool-ldflags +106 -0
- data/ext/ffi_c/libffi/libtool-version +1 -1
- data/ext/ffi_c/libffi/ltmain.sh +3641 -2026
- data/ext/ffi_c/libffi/m4/asmcfi.m4 +13 -0
- data/ext/ffi_c/libffi/m4/ax_append_flag.m4 +50 -0
- data/ext/ffi_c/libffi/m4/ax_cc_maxopt.m4 +32 -14
- data/ext/ffi_c/libffi/m4/ax_cflags_warn_all.m4 +33 -106
- data/ext/ffi_c/libffi/m4/ax_check_compile_flag.m4 +53 -0
- data/ext/ffi_c/libffi/m4/ax_compiler_vendor.m4 +38 -13
- data/ext/ffi_c/libffi/m4/ax_configure_args.m4 +8 -29
- data/ext/ffi_c/libffi/m4/ax_enable_builddir.m4 +11 -9
- data/ext/ffi_c/libffi/m4/ax_gcc_archflag.m4 +104 -52
- data/ext/ffi_c/libffi/m4/ax_gcc_x86_cpuid.m4 +18 -8
- data/ext/ffi_c/libffi/m4/ax_require_defined.m4 +37 -0
- data/ext/ffi_c/libffi/make_sunver.pl +333 -0
- data/ext/ffi_c/libffi/man/Makefile.am +2 -2
- data/ext/ffi_c/libffi/man/Makefile.in +151 -55
- data/ext/ffi_c/libffi/man/ffi.3 +10 -0
- data/ext/ffi_c/libffi/man/ffi_prep_cif.3 +6 -4
- data/ext/ffi_c/libffi/man/ffi_prep_cif_var.3 +73 -0
- data/ext/ffi_c/libffi/missing +153 -314
- data/ext/ffi_c/libffi/msvc_build/aarch64/Ffi_staticLib.sln +33 -0
- data/ext/ffi_c/libffi/msvc_build/aarch64/Ffi_staticLib.vcxproj +130 -0
- data/ext/ffi_c/libffi/msvc_build/aarch64/Ffi_staticLib.vcxproj.filters +57 -0
- data/ext/ffi_c/libffi/msvc_build/aarch64/Ffi_staticLib.vcxproj.user +4 -0
- data/ext/ffi_c/libffi/{include/ffi.h.vc64 → msvc_build/aarch64/aarch64_include/ffi.h} +151 -67
- data/ext/ffi_c/libffi/msvc_build/aarch64/aarch64_include/fficonfig.h +219 -0
- data/ext/ffi_c/libffi/msvcc.sh +176 -20
- data/ext/ffi_c/libffi/src/aarch64/ffi.c +1025 -0
- data/ext/ffi_c/libffi/src/aarch64/ffitarget.h +97 -0
- data/ext/ffi_c/libffi/src/aarch64/internal.h +68 -0
- data/ext/ffi_c/libffi/src/aarch64/sysv.S +451 -0
- data/ext/ffi_c/libffi/src/aarch64/win64_armasm.S +506 -0
- data/ext/ffi_c/libffi/src/alpha/ffi.c +335 -98
- data/ext/ffi_c/libffi/src/alpha/ffitarget.h +10 -1
- data/ext/ffi_c/libffi/src/alpha/internal.h +23 -0
- data/ext/ffi_c/libffi/src/alpha/osf.S +161 -266
- data/ext/ffi_c/libffi/src/arc/arcompact.S +135 -0
- data/ext/ffi_c/libffi/src/arc/ffi.c +266 -0
- data/ext/ffi_c/libffi/src/arc/ffitarget.h +53 -0
- data/ext/ffi_c/libffi/src/arm/ffi.c +663 -515
- data/ext/ffi_c/libffi/src/arm/ffitarget.h +32 -8
- data/ext/ffi_c/libffi/src/arm/internal.h +7 -0
- data/ext/ffi_c/libffi/src/arm/sysv.S +305 -417
- data/ext/ffi_c/libffi/src/arm/sysv_msvc_arm32.S +311 -0
- data/ext/ffi_c/libffi/src/avr32/ffitarget.h +6 -1
- data/ext/ffi_c/libffi/src/bfin/ffi.c +196 -0
- data/ext/ffi_c/libffi/src/bfin/ffitarget.h +43 -0
- data/ext/ffi_c/libffi/src/bfin/sysv.S +179 -0
- data/ext/ffi_c/libffi/src/closures.c +465 -59
- data/ext/ffi_c/libffi/src/cris/ffi.c +10 -7
- data/ext/ffi_c/libffi/src/cris/ffitarget.h +6 -1
- data/ext/ffi_c/libffi/src/csky/ffi.c +395 -0
- data/ext/ffi_c/libffi/src/csky/ffitarget.h +63 -0
- data/ext/ffi_c/libffi/src/csky/sysv.S +371 -0
- data/ext/ffi_c/libffi/src/debug.c +6 -1
- data/ext/ffi_c/libffi/src/dlmalloc.c +17 -12
- data/ext/ffi_c/libffi/src/frv/ffi.c +2 -2
- data/ext/ffi_c/libffi/src/frv/ffitarget.h +6 -1
- data/ext/ffi_c/libffi/src/ia64/ffi.c +35 -13
- data/ext/ffi_c/libffi/src/ia64/ffitarget.h +8 -2
- data/ext/ffi_c/libffi/src/ia64/unix.S +8 -1
- data/ext/ffi_c/libffi/src/java_raw_api.c +23 -5
- data/ext/ffi_c/libffi/src/kvx/asm.h +5 -0
- data/ext/ffi_c/libffi/src/kvx/ffi.c +273 -0
- data/ext/ffi_c/libffi/src/kvx/ffitarget.h +75 -0
- data/ext/ffi_c/libffi/src/kvx/sysv.S +127 -0
- data/ext/ffi_c/libffi/src/m32r/ffi.c +1 -1
- data/ext/ffi_c/libffi/src/m32r/ffitarget.h +6 -1
- data/ext/ffi_c/libffi/src/m68k/ffi.c +87 -13
- data/ext/ffi_c/libffi/src/m68k/ffitarget.h +6 -1
- data/ext/ffi_c/libffi/src/m68k/sysv.S +119 -32
- data/ext/ffi_c/libffi/src/m88k/ffi.c +400 -0
- data/ext/ffi_c/libffi/src/m88k/ffitarget.h +49 -0
- data/ext/ffi_c/libffi/src/m88k/obsd.S +209 -0
- data/ext/ffi_c/libffi/src/metag/ffi.c +330 -0
- data/ext/ffi_c/libffi/{fficonfig.hw → src/metag/ffitarget.h} +22 -26
- data/ext/ffi_c/libffi/src/metag/sysv.S +311 -0
- data/ext/ffi_c/libffi/src/microblaze/ffi.c +321 -0
- data/ext/ffi_c/libffi/src/microblaze/ffitarget.h +53 -0
- data/ext/ffi_c/libffi/src/microblaze/sysv.S +302 -0
- data/ext/ffi_c/libffi/src/mips/ffi.c +135 -37
- data/ext/ffi_c/libffi/src/mips/ffitarget.h +16 -14
- data/ext/ffi_c/libffi/src/mips/n32.S +128 -56
- data/ext/ffi_c/libffi/src/mips/o32.S +150 -27
- data/ext/ffi_c/libffi/src/moxie/eabi.S +55 -82
- data/ext/ffi_c/libffi/src/moxie/ffi.c +55 -46
- data/ext/ffi_c/libffi/src/moxie/ffitarget.h +52 -0
- data/ext/ffi_c/libffi/src/nios2/ffi.c +304 -0
- data/ext/ffi_c/libffi/src/nios2/ffitarget.h +52 -0
- data/ext/ffi_c/libffi/src/nios2/sysv.S +136 -0
- data/ext/ffi_c/libffi/src/or1k/ffi.c +328 -0
- data/ext/ffi_c/libffi/src/or1k/ffitarget.h +58 -0
- data/ext/ffi_c/libffi/src/or1k/sysv.S +107 -0
- data/ext/ffi_c/libffi/src/pa/ffi.c +46 -91
- data/ext/ffi_c/libffi/src/pa/ffitarget.h +9 -7
- data/ext/ffi_c/libffi/src/pa/hpux32.S +4 -2
- data/ext/ffi_c/libffi/src/pa/linux.S +27 -4
- data/ext/ffi_c/libffi/src/powerpc/aix.S +245 -7
- data/ext/ffi_c/libffi/src/powerpc/aix_closure.S +253 -4
- data/ext/ffi_c/libffi/src/powerpc/asm.h +2 -2
- data/ext/ffi_c/libffi/src/powerpc/darwin.S +2 -7
- data/ext/ffi_c/libffi/src/powerpc/darwin_closure.S +22 -26
- data/ext/ffi_c/libffi/src/powerpc/ffi.c +105 -1378
- data/ext/ffi_c/libffi/src/powerpc/ffi_darwin.c +123 -30
- data/ext/ffi_c/libffi/src/powerpc/ffi_linux64.c +1153 -0
- data/ext/ffi_c/libffi/src/powerpc/ffi_powerpc.h +105 -0
- data/ext/ffi_c/libffi/src/powerpc/ffi_sysv.c +923 -0
- data/ext/ffi_c/libffi/src/powerpc/ffitarget.h +110 -45
- data/ext/ffi_c/libffi/src/powerpc/linux64.S +189 -85
- data/ext/ffi_c/libffi/src/powerpc/linux64_closure.S +436 -108
- data/ext/ffi_c/libffi/src/powerpc/ppc_closure.S +138 -68
- data/ext/ffi_c/libffi/src/powerpc/sysv.S +73 -119
- data/ext/ffi_c/libffi/src/prep_cif.c +111 -25
- data/ext/ffi_c/libffi/src/raw_api.c +18 -5
- data/ext/ffi_c/libffi/src/riscv/ffi.c +481 -0
- data/ext/ffi_c/libffi/src/riscv/ffitarget.h +69 -0
- data/ext/ffi_c/libffi/src/riscv/sysv.S +293 -0
- data/ext/ffi_c/libffi/src/s390/ffi.c +294 -318
- data/ext/ffi_c/libffi/src/s390/ffitarget.h +9 -1
- data/ext/ffi_c/libffi/src/s390/internal.h +11 -0
- data/ext/ffi_c/libffi/src/s390/sysv.S +257 -366
- data/ext/ffi_c/libffi/src/sh/ffi.c +4 -3
- data/ext/ffi_c/libffi/src/sh/ffitarget.h +6 -1
- data/ext/ffi_c/libffi/src/sh64/ffi.c +3 -2
- data/ext/ffi_c/libffi/src/sh64/ffitarget.h +6 -1
- data/ext/ffi_c/libffi/src/sparc/ffi.c +326 -527
- data/ext/ffi_c/libffi/src/sparc/ffi64.c +608 -0
- data/ext/ffi_c/libffi/src/sparc/ffitarget.h +20 -7
- data/ext/ffi_c/libffi/src/sparc/internal.h +26 -0
- data/ext/ffi_c/libffi/src/sparc/v8.S +364 -234
- data/ext/ffi_c/libffi/src/sparc/v9.S +340 -207
- data/ext/ffi_c/libffi/src/tile/ffi.c +355 -0
- data/ext/ffi_c/libffi/src/tile/ffitarget.h +65 -0
- data/ext/ffi_c/libffi/src/tile/tile.S +360 -0
- data/ext/ffi_c/libffi/src/types.c +46 -15
- data/ext/ffi_c/libffi/src/vax/elfbsd.S +195 -0
- data/ext/ffi_c/libffi/src/vax/ffi.c +276 -0
- data/ext/ffi_c/libffi/src/vax/ffitarget.h +49 -0
- data/ext/ffi_c/libffi/src/x86/asmnames.h +30 -0
- data/ext/ffi_c/libffi/src/x86/ffi.c +624 -498
- data/ext/ffi_c/libffi/src/x86/ffi64.c +379 -119
- data/ext/ffi_c/libffi/src/x86/ffitarget.h +74 -35
- data/ext/ffi_c/libffi/src/x86/ffiw64.c +318 -0
- data/ext/ffi_c/libffi/src/x86/internal.h +29 -0
- data/ext/ffi_c/libffi/src/x86/internal64.h +22 -0
- data/ext/ffi_c/libffi/src/x86/sysv.S +1070 -400
- data/ext/ffi_c/libffi/src/x86/sysv_intel.S +995 -0
- data/ext/ffi_c/libffi/src/x86/unix64.S +494 -299
- data/ext/ffi_c/libffi/src/x86/win64.S +231 -458
- data/ext/ffi_c/libffi/src/x86/win64_intel.S +238 -0
- data/ext/ffi_c/libffi/src/xtensa/ffi.c +298 -0
- data/ext/ffi_c/libffi/src/xtensa/ffitarget.h +53 -0
- data/ext/ffi_c/libffi/src/xtensa/sysv.S +258 -0
- data/ext/ffi_c/libffi/stamp-h.in +1 -0
- data/ext/ffi_c/libffi/testsuite/Makefile.am +115 -73
- data/ext/ffi_c/libffi/testsuite/Makefile.in +262 -114
- data/ext/ffi_c/libffi/testsuite/lib/libffi.exp +334 -24
- data/ext/ffi_c/libffi/testsuite/lib/target-libpath.exp +21 -1
- data/ext/ffi_c/libffi/testsuite/libffi.bhaible/Makefile +28 -0
- data/ext/ffi_c/libffi/testsuite/libffi.bhaible/README +78 -0
- data/ext/ffi_c/libffi/testsuite/libffi.bhaible/alignof.h +50 -0
- data/ext/ffi_c/libffi/testsuite/libffi.bhaible/bhaible.exp +63 -0
- data/ext/ffi_c/libffi/testsuite/libffi.bhaible/test-call.c +1745 -0
- data/ext/ffi_c/libffi/testsuite/libffi.bhaible/test-callback.c +2885 -0
- data/ext/ffi_c/libffi/testsuite/libffi.bhaible/testcases.c +743 -0
- data/ext/ffi_c/libffi/testsuite/libffi.call/align_mixed.c +46 -0
- data/ext/ffi_c/libffi/testsuite/libffi.call/align_stdcall.c +46 -0
- data/ext/ffi_c/libffi/testsuite/libffi.call/call.exp +28 -6
- data/ext/ffi_c/libffi/testsuite/libffi.call/err_bad_typedef.c +2 -2
- data/ext/ffi_c/libffi/testsuite/libffi.call/ffitest.h +25 -40
- data/ext/ffi_c/libffi/testsuite/libffi.call/float1.c +3 -1
- data/ext/ffi_c/libffi/testsuite/libffi.call/float2.c +15 -12
- data/ext/ffi_c/libffi/testsuite/libffi.call/float3.c +4 -2
- data/ext/ffi_c/libffi/testsuite/libffi.call/float_va.c +107 -0
- data/ext/ffi_c/libffi/testsuite/libffi.call/many.c +6 -16
- data/ext/ffi_c/libffi/testsuite/libffi.call/many2.c +57 -0
- data/ext/ffi_c/libffi/testsuite/libffi.call/many_double.c +70 -0
- data/ext/ffi_c/libffi/testsuite/libffi.call/many_mixed.c +78 -0
- data/ext/ffi_c/libffi/testsuite/libffi.call/negint.c +0 -1
- data/ext/ffi_c/libffi/testsuite/libffi.call/offsets.c +46 -0
- data/ext/ffi_c/libffi/testsuite/libffi.call/pr1172638.c +127 -0
- data/ext/ffi_c/libffi/testsuite/libffi.call/return_dbl.c +1 -0
- data/ext/ffi_c/libffi/testsuite/libffi.call/return_ldl.c +1 -1
- data/ext/ffi_c/libffi/testsuite/libffi.call/return_sc.c +1 -1
- data/ext/ffi_c/libffi/testsuite/libffi.call/return_uc.c +1 -1
- data/ext/ffi_c/libffi/testsuite/libffi.call/strlen.c +2 -2
- data/ext/ffi_c/libffi/testsuite/libffi.call/strlen2.c +49 -0
- data/ext/ffi_c/libffi/testsuite/libffi.call/strlen3.c +49 -0
- data/ext/ffi_c/libffi/testsuite/libffi.call/strlen4.c +55 -0
- data/ext/ffi_c/libffi/testsuite/libffi.call/struct1.c +9 -7
- data/ext/ffi_c/libffi/testsuite/libffi.call/struct10.c +57 -0
- data/ext/ffi_c/libffi/testsuite/libffi.call/struct2.c +7 -7
- data/ext/ffi_c/libffi/testsuite/libffi.call/struct3.c +7 -6
- data/ext/ffi_c/libffi/testsuite/libffi.call/struct4.c +9 -8
- data/ext/ffi_c/libffi/testsuite/libffi.call/struct5.c +9 -8
- data/ext/ffi_c/libffi/testsuite/libffi.call/struct6.c +9 -9
- data/ext/ffi_c/libffi/testsuite/libffi.call/struct7.c +9 -9
- data/ext/ffi_c/libffi/testsuite/libffi.call/struct8.c +9 -8
- data/ext/ffi_c/libffi/testsuite/libffi.call/struct9.c +9 -8
- data/ext/ffi_c/libffi/testsuite/libffi.call/uninitialized.c +61 -0
- data/ext/ffi_c/libffi/testsuite/libffi.call/va_1.c +196 -0
- data/ext/ffi_c/libffi/testsuite/libffi.call/va_struct1.c +121 -0
- data/ext/ffi_c/libffi/testsuite/libffi.call/va_struct2.c +123 -0
- data/ext/ffi_c/libffi/testsuite/libffi.call/va_struct3.c +125 -0
- data/ext/ffi_c/libffi/testsuite/libffi.closures/closure.exp +67 -0
- data/ext/ffi_c/libffi/testsuite/{libffi.call → libffi.closures}/closure_fn0.c +0 -0
- data/ext/ffi_c/libffi/testsuite/{libffi.call → libffi.closures}/closure_fn1.c +0 -0
- data/ext/ffi_c/libffi/testsuite/{libffi.call → libffi.closures}/closure_fn2.c +0 -0
- data/ext/ffi_c/libffi/testsuite/{libffi.call → libffi.closures}/closure_fn3.c +0 -0
- data/ext/ffi_c/libffi/testsuite/{libffi.call → libffi.closures}/closure_fn4.c +0 -0
- data/ext/ffi_c/libffi/testsuite/{libffi.call → libffi.closures}/closure_fn5.c +0 -0
- data/ext/ffi_c/libffi/testsuite/{libffi.call → libffi.closures}/closure_fn6.c +0 -0
- data/ext/ffi_c/libffi/testsuite/{libffi.call → libffi.closures}/closure_loc_fn0.c +0 -0
- data/ext/ffi_c/libffi/testsuite/{libffi.call/closure_stdcall.c → libffi.closures/closure_simple.c} +7 -16
- data/ext/ffi_c/libffi/testsuite/{libffi.call → libffi.closures}/cls_12byte.c +4 -4
- data/ext/ffi_c/libffi/testsuite/{libffi.call → libffi.closures}/cls_16byte.c +4 -4
- data/ext/ffi_c/libffi/testsuite/{libffi.call → libffi.closures}/cls_18byte.c +4 -4
- data/ext/ffi_c/libffi/testsuite/{libffi.call → libffi.closures}/cls_19byte.c +4 -4
- data/ext/ffi_c/libffi/testsuite/{libffi.call → libffi.closures}/cls_1_1byte.c +4 -4
- data/ext/ffi_c/libffi/testsuite/{libffi.call → libffi.closures}/cls_20byte.c +4 -4
- data/ext/ffi_c/libffi/testsuite/{libffi.call → libffi.closures}/cls_20byte1.c +4 -4
- data/ext/ffi_c/libffi/testsuite/{libffi.call → libffi.closures}/cls_24byte.c +5 -5
- data/ext/ffi_c/libffi/testsuite/{libffi.call → libffi.closures}/cls_2byte.c +4 -4
- data/ext/ffi_c/libffi/testsuite/{libffi.call → libffi.closures}/cls_3_1byte.c +4 -4
- data/ext/ffi_c/libffi/testsuite/{libffi.call → libffi.closures}/cls_3byte1.c +4 -4
- data/ext/ffi_c/libffi/testsuite/{libffi.call → libffi.closures}/cls_3byte2.c +4 -4
- data/ext/ffi_c/libffi/testsuite/libffi.closures/cls_3float.c +95 -0
- data/ext/ffi_c/libffi/testsuite/{libffi.call → libffi.closures}/cls_4_1byte.c +4 -4
- data/ext/ffi_c/libffi/testsuite/{libffi.call → libffi.closures}/cls_4byte.c +4 -4
- data/ext/ffi_c/libffi/testsuite/{libffi.call → libffi.closures}/cls_5_1_byte.c +4 -4
- data/ext/ffi_c/libffi/testsuite/{libffi.call → libffi.closures}/cls_5byte.c +4 -4
- data/ext/ffi_c/libffi/testsuite/{libffi.call → libffi.closures}/cls_64byte.c +5 -5
- data/ext/ffi_c/libffi/testsuite/{libffi.call → libffi.closures}/cls_6_1_byte.c +4 -4
- data/ext/ffi_c/libffi/testsuite/{libffi.call → libffi.closures}/cls_6byte.c +4 -4
- data/ext/ffi_c/libffi/testsuite/{libffi.call → libffi.closures}/cls_7_1_byte.c +4 -4
- data/ext/ffi_c/libffi/testsuite/{libffi.call → libffi.closures}/cls_7byte.c +4 -4
- data/ext/ffi_c/libffi/testsuite/{libffi.call → libffi.closures}/cls_8byte.c +4 -4
- data/ext/ffi_c/libffi/testsuite/{libffi.call → libffi.closures}/cls_9byte1.c +4 -4
- data/ext/ffi_c/libffi/testsuite/{libffi.call → libffi.closures}/cls_9byte2.c +4 -4
- data/ext/ffi_c/libffi/testsuite/{libffi.call → libffi.closures}/cls_align_double.c +4 -4
- data/ext/ffi_c/libffi/testsuite/{libffi.call → libffi.closures}/cls_align_float.c +4 -4
- data/ext/ffi_c/libffi/testsuite/{libffi.call → libffi.closures}/cls_align_longdouble.c +4 -4
- data/ext/ffi_c/libffi/testsuite/{libffi.call → libffi.closures}/cls_align_longdouble_split.c +4 -6
- data/ext/ffi_c/libffi/testsuite/{libffi.call → libffi.closures}/cls_align_longdouble_split2.c +4 -6
- data/ext/ffi_c/libffi/testsuite/{libffi.call → libffi.closures}/cls_align_pointer.c +4 -4
- data/ext/ffi_c/libffi/testsuite/{libffi.call → libffi.closures}/cls_align_sint16.c +4 -4
- data/ext/ffi_c/libffi/testsuite/{libffi.call → libffi.closures}/cls_align_sint32.c +4 -4
- data/ext/ffi_c/libffi/testsuite/{libffi.call → libffi.closures}/cls_align_sint64.c +4 -4
- data/ext/ffi_c/libffi/testsuite/{libffi.call → libffi.closures}/cls_align_uint16.c +4 -4
- data/ext/ffi_c/libffi/testsuite/{libffi.call → libffi.closures}/cls_align_uint32.c +4 -4
- data/ext/ffi_c/libffi/testsuite/{libffi.call → libffi.closures}/cls_align_uint64.c +4 -4
- data/ext/ffi_c/libffi/testsuite/{libffi.call → libffi.closures}/cls_dbls_struct.c +4 -4
- data/ext/ffi_c/libffi/testsuite/{libffi.call → libffi.closures}/cls_double.c +0 -0
- data/ext/ffi_c/libffi/testsuite/{libffi.call → libffi.closures}/cls_double_va.c +10 -9
- data/ext/ffi_c/libffi/testsuite/{libffi.call → libffi.closures}/cls_float.c +0 -0
- data/ext/ffi_c/libffi/testsuite/{libffi.call → libffi.closures}/cls_longdouble.c +3 -3
- data/ext/ffi_c/libffi/testsuite/{libffi.call → libffi.closures}/cls_longdouble_va.c +10 -9
- data/ext/ffi_c/libffi/testsuite/libffi.closures/cls_many_mixed_args.c +70 -0
- data/ext/ffi_c/libffi/testsuite/libffi.closures/cls_many_mixed_float_double.c +55 -0
- data/ext/ffi_c/libffi/testsuite/{libffi.call → libffi.closures}/cls_multi_schar.c +0 -0
- data/ext/ffi_c/libffi/testsuite/{libffi.call → libffi.closures}/cls_multi_sshort.c +0 -0
- data/ext/ffi_c/libffi/testsuite/{libffi.call → libffi.closures}/cls_multi_sshortchar.c +0 -0
- data/ext/ffi_c/libffi/testsuite/{libffi.call → libffi.closures}/cls_multi_uchar.c +0 -0
- data/ext/ffi_c/libffi/testsuite/{libffi.call → libffi.closures}/cls_multi_ushort.c +0 -0
- data/ext/ffi_c/libffi/testsuite/{libffi.call → libffi.closures}/cls_multi_ushortchar.c +0 -0
- data/ext/ffi_c/libffi/testsuite/{libffi.call → libffi.closures}/cls_pointer.c +1 -1
- data/ext/ffi_c/libffi/testsuite/{libffi.call → libffi.closures}/cls_pointer_stack.c +11 -9
- data/ext/ffi_c/libffi/testsuite/{libffi.call → libffi.closures}/cls_schar.c +0 -0
- data/ext/ffi_c/libffi/testsuite/{libffi.call → libffi.closures}/cls_sint.c +0 -0
- data/ext/ffi_c/libffi/testsuite/{libffi.call → libffi.closures}/cls_sshort.c +0 -0
- data/ext/ffi_c/libffi/testsuite/libffi.closures/cls_struct_va1.c +114 -0
- data/ext/ffi_c/libffi/testsuite/{libffi.call → libffi.closures}/cls_uchar.c +0 -0
- data/ext/ffi_c/libffi/testsuite/libffi.closures/cls_uchar_va.c +44 -0
- data/ext/ffi_c/libffi/testsuite/{libffi.call → libffi.closures}/cls_uint.c +0 -0
- data/ext/ffi_c/libffi/testsuite/libffi.closures/cls_uint_va.c +45 -0
- data/ext/ffi_c/libffi/testsuite/libffi.closures/cls_ulong_va.c +45 -0
- data/ext/ffi_c/libffi/testsuite/{libffi.call → libffi.closures}/cls_ulonglong.c +5 -5
- data/ext/ffi_c/libffi/testsuite/{libffi.call → libffi.closures}/cls_ushort.c +0 -0
- data/ext/ffi_c/libffi/testsuite/libffi.closures/cls_ushort_va.c +44 -0
- data/ext/ffi_c/libffi/testsuite/{libffi.call → libffi.closures}/err_bad_abi.c +0 -0
- data/ext/ffi_c/libffi/testsuite/libffi.closures/ffitest.h +138 -0
- data/ext/ffi_c/libffi/testsuite/{libffi.call → libffi.closures}/huge_struct.c +20 -19
- data/ext/ffi_c/libffi/testsuite/{libffi.call → libffi.closures}/nested_struct.c +6 -6
- data/ext/ffi_c/libffi/testsuite/{libffi.call → libffi.closures}/nested_struct1.c +8 -8
- data/ext/ffi_c/libffi/testsuite/{libffi.call → libffi.closures}/nested_struct10.c +7 -6
- data/ext/ffi_c/libffi/testsuite/libffi.closures/nested_struct11.c +121 -0
- data/ext/ffi_c/libffi/testsuite/{libffi.call → libffi.closures}/nested_struct2.c +5 -5
- data/ext/ffi_c/libffi/testsuite/{libffi.call → libffi.closures}/nested_struct3.c +5 -5
- data/ext/ffi_c/libffi/testsuite/{libffi.call → libffi.closures}/nested_struct4.c +5 -5
- data/ext/ffi_c/libffi/testsuite/{libffi.call → libffi.closures}/nested_struct5.c +5 -5
- data/ext/ffi_c/libffi/testsuite/{libffi.call → libffi.closures}/nested_struct6.c +6 -6
- data/ext/ffi_c/libffi/testsuite/{libffi.call → libffi.closures}/nested_struct7.c +5 -5
- data/ext/ffi_c/libffi/testsuite/{libffi.call → libffi.closures}/nested_struct8.c +6 -6
- data/ext/ffi_c/libffi/testsuite/{libffi.call → libffi.closures}/nested_struct9.c +6 -6
- data/ext/ffi_c/libffi/testsuite/{libffi.call → libffi.closures}/problem1.c +0 -0
- data/ext/ffi_c/libffi/testsuite/{libffi.call → libffi.closures}/stret_large.c +7 -7
- data/ext/ffi_c/libffi/testsuite/{libffi.call → libffi.closures}/stret_large2.c +7 -7
- data/ext/ffi_c/libffi/testsuite/{libffi.call → libffi.closures}/stret_medium.c +5 -5
- data/ext/ffi_c/libffi/testsuite/{libffi.call → libffi.closures}/stret_medium2.c +5 -5
- data/ext/ffi_c/libffi/testsuite/{libffi.call → libffi.closures}/testclosure.c +2 -2
- data/ext/ffi_c/libffi/testsuite/{libffi.special → libffi.closures}/unwindtest.cc +3 -10
- data/ext/ffi_c/libffi/testsuite/{libffi.special → libffi.closures}/unwindtest_ffi_call.cc +3 -2
- data/ext/ffi_c/libffi/testsuite/libffi.complex/cls_align_complex.inc +91 -0
- data/ext/ffi_c/libffi/testsuite/libffi.complex/cls_align_complex_double.c +10 -0
- data/ext/ffi_c/libffi/testsuite/libffi.complex/cls_align_complex_float.c +10 -0
- data/ext/ffi_c/libffi/testsuite/libffi.complex/cls_align_complex_longdouble.c +10 -0
- data/ext/ffi_c/libffi/testsuite/libffi.complex/cls_complex.inc +42 -0
- data/ext/ffi_c/libffi/testsuite/libffi.complex/cls_complex_double.c +10 -0
- data/ext/ffi_c/libffi/testsuite/libffi.complex/cls_complex_float.c +10 -0
- data/ext/ffi_c/libffi/testsuite/libffi.complex/cls_complex_longdouble.c +10 -0
- data/ext/ffi_c/libffi/testsuite/libffi.complex/cls_complex_struct.inc +71 -0
- data/ext/ffi_c/libffi/testsuite/libffi.complex/cls_complex_struct_double.c +10 -0
- data/ext/ffi_c/libffi/testsuite/libffi.complex/cls_complex_struct_float.c +10 -0
- data/ext/ffi_c/libffi/testsuite/libffi.complex/cls_complex_struct_longdouble.c +10 -0
- data/ext/ffi_c/libffi/testsuite/libffi.complex/cls_complex_va.inc +80 -0
- data/ext/ffi_c/libffi/testsuite/libffi.complex/cls_complex_va_double.c +10 -0
- data/ext/ffi_c/libffi/testsuite/libffi.complex/cls_complex_va_float.c +16 -0
- data/ext/ffi_c/libffi/testsuite/libffi.complex/cls_complex_va_longdouble.c +10 -0
- data/ext/ffi_c/libffi/testsuite/{libffi.special/special.exp → libffi.complex/complex.exp} +9 -8
- data/ext/ffi_c/libffi/testsuite/libffi.complex/complex.inc +51 -0
- data/ext/ffi_c/libffi/testsuite/libffi.complex/complex_defs_double.inc +7 -0
- data/ext/ffi_c/libffi/testsuite/libffi.complex/complex_defs_float.inc +7 -0
- data/ext/ffi_c/libffi/testsuite/libffi.complex/complex_defs_longdouble.inc +7 -0
- data/ext/ffi_c/libffi/testsuite/libffi.complex/complex_double.c +10 -0
- data/ext/ffi_c/libffi/testsuite/libffi.complex/complex_float.c +10 -0
- data/ext/ffi_c/libffi/testsuite/libffi.complex/complex_int.c +86 -0
- data/ext/ffi_c/libffi/testsuite/libffi.complex/complex_longdouble.c +10 -0
- data/ext/ffi_c/libffi/testsuite/libffi.complex/ffitest.h +1 -0
- data/ext/ffi_c/libffi/testsuite/libffi.complex/many_complex.inc +78 -0
- data/ext/ffi_c/libffi/testsuite/libffi.complex/many_complex_double.c +10 -0
- data/ext/ffi_c/libffi/testsuite/libffi.complex/many_complex_float.c +10 -0
- data/ext/ffi_c/libffi/testsuite/libffi.complex/many_complex_longdouble.c +10 -0
- data/ext/ffi_c/libffi/testsuite/libffi.complex/return_complex.inc +37 -0
- data/ext/ffi_c/libffi/testsuite/libffi.complex/return_complex1.inc +41 -0
- data/ext/ffi_c/libffi/testsuite/libffi.complex/return_complex1_double.c +10 -0
- data/ext/ffi_c/libffi/testsuite/libffi.complex/return_complex1_float.c +10 -0
- data/ext/ffi_c/libffi/testsuite/libffi.complex/return_complex1_longdouble.c +10 -0
- data/ext/ffi_c/libffi/testsuite/libffi.complex/return_complex2.inc +44 -0
- data/ext/ffi_c/libffi/testsuite/libffi.complex/return_complex2_double.c +10 -0
- data/ext/ffi_c/libffi/testsuite/libffi.complex/return_complex2_float.c +10 -0
- data/ext/ffi_c/libffi/testsuite/libffi.complex/return_complex2_longdouble.c +10 -0
- data/ext/ffi_c/libffi/testsuite/libffi.complex/return_complex_double.c +10 -0
- data/ext/ffi_c/libffi/testsuite/libffi.complex/return_complex_float.c +10 -0
- data/ext/ffi_c/libffi/testsuite/libffi.complex/return_complex_longdouble.c +10 -0
- data/ext/ffi_c/libffi/testsuite/libffi.go/aa-direct.c +34 -0
- data/ext/ffi_c/libffi/testsuite/libffi.go/closure1.c +28 -0
- data/ext/ffi_c/libffi/testsuite/libffi.go/ffitest.h +1 -0
- data/ext/ffi_c/libffi/testsuite/libffi.go/go.exp +36 -0
- data/ext/ffi_c/libffi/testsuite/libffi.go/static-chain.h +19 -0
- data/ext/ffi_c/libffi.bsd.mk +12 -6
- data/ext/ffi_c/libffi.darwin.mk +21 -9
- data/ext/ffi_c/libffi.gnu.mk +3 -2
- data/ext/ffi_c/libffi.mk +11 -6
- data/ext/ffi_c/libffi.vc.mk +1 -1
- data/ext/ffi_c/libffi.vc64.mk +1 -1
- data/ext/ffi_c/rbffi.h +22 -14
- data/ext/ffi_c/rbffi_endian.h +11 -2
- data/ffi.gemspec +42 -0
- data/lib/ffi/abstract_memory.rb +44 -0
- data/lib/ffi/autopointer.rb +70 -50
- data/lib/ffi/data_converter.rb +67 -0
- data/lib/ffi/enum.rb +159 -24
- data/lib/ffi/errno.rb +21 -11
- data/lib/ffi/ffi.rb +25 -11
- data/lib/ffi/io.rb +24 -14
- data/lib/ffi/library.rb +174 -67
- data/lib/ffi/managedstruct.rb +63 -34
- data/lib/ffi/platform/aarch64-darwin/types.conf +130 -0
- data/lib/ffi/platform/aarch64-freebsd/types.conf +128 -0
- data/lib/ffi/platform/aarch64-freebsd12/types.conf +181 -0
- data/lib/ffi/platform/aarch64-linux/types.conf +104 -0
- data/lib/ffi/platform/aarch64-openbsd/types.conf +134 -0
- data/lib/ffi/platform/arm-freebsd/types.conf +152 -0
- data/lib/ffi/platform/arm-freebsd12/types.conf +152 -0
- data/lib/ffi/platform/arm-linux/types.conf +110 -82
- data/lib/ffi/platform/i386-cygwin/types.conf +3 -0
- data/lib/ffi/platform/i386-darwin/types.conf +63 -63
- data/lib/ffi/platform/i386-freebsd/types.conf +89 -89
- data/lib/ffi/platform/i386-freebsd12/types.conf +152 -0
- data/lib/ffi/platform/{i486-gnu → i386-gnu}/types.conf +84 -84
- data/lib/ffi/platform/i386-linux/types.conf +77 -77
- data/lib/ffi/platform/i386-netbsd/types.conf +87 -87
- data/lib/ffi/platform/i386-openbsd/types.conf +89 -87
- data/lib/ffi/platform/i386-solaris/types.conf +96 -96
- data/lib/ffi/platform/i386-windows/types.conf +43 -96
- data/lib/ffi/platform/ia64-linux/types.conf +79 -79
- data/lib/ffi/platform/mips-linux/types.conf +79 -79
- data/lib/ffi/platform/mips64-linux/types.conf +104 -0
- data/lib/ffi/platform/mips64el-linux/types.conf +104 -0
- data/lib/ffi/platform/mipsel-linux/types.conf +79 -79
- data/lib/ffi/platform/mipsisa32r6-linux/types.conf +102 -0
- data/lib/ffi/platform/mipsisa32r6el-linux/types.conf +102 -0
- data/lib/ffi/platform/mipsisa64r6-linux/types.conf +104 -0
- data/lib/ffi/platform/mipsisa64r6el-linux/types.conf +104 -0
- data/lib/ffi/platform/powerpc-aix/types.conf +155 -155
- data/lib/ffi/platform/powerpc-darwin/types.conf +63 -63
- data/lib/ffi/platform/powerpc-linux/types.conf +108 -78
- data/lib/ffi/platform/powerpc-openbsd/types.conf +156 -0
- data/lib/ffi/platform/powerpc64-linux/types.conf +104 -0
- data/lib/ffi/platform/powerpc64le-linux/types.conf +100 -0
- data/lib/ffi/platform/riscv64-linux/types.conf +104 -0
- data/lib/ffi/platform/s390-linux/types.conf +79 -79
- data/lib/ffi/platform/s390x-linux/types.conf +79 -79
- data/lib/ffi/platform/sparc-linux/types.conf +79 -79
- data/lib/ffi/platform/sparc-solaris/types.conf +103 -103
- data/lib/ffi/platform/sparc64-linux/types.conf +102 -0
- data/lib/ffi/platform/sparcv9-openbsd/types.conf +156 -0
- data/lib/ffi/platform/sparcv9-solaris/types.conf +103 -103
- data/lib/ffi/platform/x86_64-cygwin/types.conf +3 -0
- data/lib/ffi/platform/x86_64-darwin/types.conf +93 -63
- data/lib/ffi/platform/x86_64-dragonflybsd/types.conf +130 -0
- data/lib/ffi/platform/x86_64-freebsd/types.conf +90 -88
- data/lib/ffi/platform/x86_64-freebsd12/types.conf +158 -0
- data/lib/ffi/platform/x86_64-haiku/types.conf +117 -0
- data/lib/ffi/platform/x86_64-linux/types.conf +107 -77
- data/lib/ffi/platform/x86_64-msys/types.conf +119 -0
- data/lib/ffi/platform/x86_64-netbsd/types.conf +89 -87
- data/lib/ffi/platform/x86_64-openbsd/types.conf +100 -92
- data/lib/ffi/platform/x86_64-solaris/types.conf +96 -96
- data/lib/ffi/platform/x86_64-windows/types.conf +52 -0
- data/lib/ffi/platform.rb +81 -26
- data/lib/ffi/pointer.rb +72 -27
- data/lib/ffi/struct.rb +99 -66
- data/lib/ffi/struct_by_reference.rb +72 -0
- data/lib/ffi/struct_layout.rb +96 -0
- data/lib/ffi/struct_layout_builder.rb +82 -17
- data/lib/ffi/tools/const_generator.rb +11 -8
- data/lib/ffi/tools/generator.rb +48 -1
- data/lib/ffi/tools/generator_task.rb +13 -16
- data/lib/ffi/tools/struct_generator.rb +6 -5
- data/lib/ffi/tools/types_generator.rb +14 -10
- data/lib/ffi/types.rb +31 -14
- data/lib/ffi/union.rb +23 -12
- data/lib/ffi/variadic.rb +25 -21
- data/lib/ffi/version.rb +3 -0
- data/lib/ffi.rb +20 -8
- data/rakelib/ffi_gem_helper.rb +65 -0
- data/samples/getlogin.rb +8 -0
- data/samples/getpid.rb +8 -0
- data/samples/gettimeofday.rb +18 -0
- data/samples/hello.rb +8 -0
- data/samples/inotify.rb +60 -0
- data/samples/pty.rb +75 -0
- data/samples/qsort.rb +20 -0
- metadata +413 -263
- data/History.txt +0 -1
- data/README.rdoc +0 -102
- data/ext/ffi_c/DataConverter.c +0 -91
- data/ext/ffi_c/Ffi_c.iml +0 -12
- data/ext/ffi_c/StructByReference.c +0 -158
- data/ext/ffi_c/StructByReference.h +0 -50
- data/ext/ffi_c/libffi/ChangeLog.libffi +0 -584
- data/ext/ffi_c/libffi/ChangeLog.libgcj +0 -40
- data/ext/ffi_c/libffi/ChangeLog.v1 +0 -764
- data/ext/ffi_c/libffi/Makefile.vc +0 -141
- data/ext/ffi_c/libffi/Makefile.vc64 +0 -141
- data/ext/ffi_c/libffi/README +0 -342
- data/ext/ffi_c/libffi/aclocal.m4 +0 -1873
- data/ext/ffi_c/libffi/build-ios.sh +0 -67
- data/ext/ffi_c/libffi/compile +0 -143
- data/ext/ffi_c/libffi/depcomp +0 -630
- data/ext/ffi_c/libffi/doc/libffi.info +0 -593
- data/ext/ffi_c/libffi/doc/stamp-vti +0 -4
- data/ext/ffi_c/libffi/include/ffi.h.vc +0 -427
- data/ext/ffi_c/libffi/m4/ax_check_compiler_flags.m4 +0 -76
- data/ext/ffi_c/libffi/m4/libtool.m4 +0 -7831
- data/ext/ffi_c/libffi/m4/ltoptions.m4 +0 -369
- data/ext/ffi_c/libffi/m4/ltsugar.m4 +0 -123
- data/ext/ffi_c/libffi/m4/ltversion.m4 +0 -23
- data/ext/ffi_c/libffi/m4/lt~obsolete.m4 +0 -98
- data/ext/ffi_c/libffi/mdate-sh +0 -201
- data/ext/ffi_c/libffi/src/arm/gentramp.sh +0 -118
- data/ext/ffi_c/libffi/src/arm/trampoline.S +0 -4450
- data/ext/ffi_c/libffi/src/x86/darwin.S +0 -444
- data/ext/ffi_c/libffi/src/x86/darwin64.S +0 -416
- data/ext/ffi_c/libffi/src/x86/freebsd.S +0 -458
- data/ext/ffi_c/libffi/src/x86/win32.S +0 -1065
- data/ext/ffi_c/libffi/testsuite/lib/libffi-dg.exp +0 -300
- data/ext/ffi_c/libffi/testsuite/libffi.call/many_win32.c +0 -63
- data/ext/ffi_c/libffi/testsuite/libffi.call/strlen_win32.c +0 -44
- data/ext/ffi_c/libffi/testsuite/libffi.special/ffitestcxx.h +0 -96
- data/ext/ffi_c/libffi/texinfo.tex +0 -7210
- data/ext/ffi_c/win32/stdint.h +0 -199
- data/gen/Rakefile +0 -30
- data/gen/log +0 -1
- data/lib/Lib.iml +0 -13
- data/spec/ffi/Ffi.iml +0 -12
- data/spec/ffi/async_callback_spec.rb +0 -46
- data/spec/ffi/bool_spec.rb +0 -40
- data/spec/ffi/buffer_spec.rb +0 -215
- data/spec/ffi/callback_spec.rb +0 -668
- data/spec/ffi/custom_param_type.rb +0 -47
- data/spec/ffi/custom_type_spec.rb +0 -85
- data/spec/ffi/dup_spec.rb +0 -65
- data/spec/ffi/enum_spec.rb +0 -227
- data/spec/ffi/errno_spec.rb +0 -29
- data/spec/ffi/ffi_spec.rb +0 -40
- data/spec/ffi/function_spec.rb +0 -87
- data/spec/ffi/library_spec.rb +0 -208
- data/spec/ffi/long_double.rb +0 -41
- data/spec/ffi/managed_struct_spec.rb +0 -72
- data/spec/ffi/number_spec.rb +0 -247
- data/spec/ffi/pointer_spec.rb +0 -214
- data/spec/ffi/rbx/attach_function_spec.rb +0 -28
- data/spec/ffi/rbx/memory_pointer_spec.rb +0 -115
- data/spec/ffi/rbx/spec_helper.rb +0 -1
- data/spec/ffi/rbx/struct_spec.rb +0 -13
- data/spec/ffi/spec_helper.rb +0 -35
- data/spec/ffi/string_spec.rb +0 -119
- data/spec/ffi/strptr_spec.rb +0 -61
- data/spec/ffi/struct_callback_spec.rb +0 -80
- data/spec/ffi/struct_initialize_spec.rb +0 -46
- data/spec/ffi/struct_packed_spec.rb +0 -62
- data/spec/ffi/struct_spec.rb +0 -719
- data/spec/ffi/typedef_spec.rb +0 -89
- data/spec/ffi/union_spec.rb +0 -76
- data/spec/ffi/variadic_spec.rb +0 -103
- data/spec/spec.opts +0 -4
- data/tasks/ann.rake +0 -80
- data/tasks/extension.rake +0 -32
- data/tasks/gem.rake +0 -199
- data/tasks/git.rake +0 -41
- data/tasks/notes.rake +0 -27
- data/tasks/post_load.rake +0 -34
- data/tasks/rdoc.rake +0 -50
- data/tasks/rubyforge.rake +0 -55
- data/tasks/setup.rb +0 -301
- data/tasks/spec.rake +0 -54
- data/tasks/svn.rake +0 -47
- data/tasks/test.rake +0 -40
- data/tasks/yard.rake +0 -11
@@ -1,14 +1,12 @@
|
|
1
1
|
#! /bin/sh
|
2
2
|
# Attempt to guess a canonical system name.
|
3
|
-
# Copyright
|
4
|
-
# 2000, 2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008, 2009
|
5
|
-
# Free Software Foundation, Inc.
|
3
|
+
# Copyright 1992-2020 Free Software Foundation, Inc.
|
6
4
|
|
7
|
-
timestamp='
|
5
|
+
timestamp='2020-07-12'
|
8
6
|
|
9
7
|
# This file is free software; you can redistribute it and/or modify it
|
10
8
|
# under the terms of the GNU General Public License as published by
|
11
|
-
# the Free Software Foundation; either version
|
9
|
+
# the Free Software Foundation; either version 3 of the License, or
|
12
10
|
# (at your option) any later version.
|
13
11
|
#
|
14
12
|
# This program is distributed in the hope that it will be useful, but
|
@@ -17,26 +15,22 @@ timestamp='2009-11-20'
|
|
17
15
|
# General Public License for more details.
|
18
16
|
#
|
19
17
|
# You should have received a copy of the GNU General Public License
|
20
|
-
# along with this program; if not,
|
21
|
-
# Foundation, Inc., 51 Franklin Street - Fifth Floor, Boston, MA
|
22
|
-
# 02110-1301, USA.
|
18
|
+
# along with this program; if not, see <https://www.gnu.org/licenses/>.
|
23
19
|
#
|
24
20
|
# As a special exception to the GNU General Public License, if you
|
25
21
|
# distribute this file as part of a program that contains a
|
26
22
|
# configuration script generated by Autoconf, you may include it under
|
27
|
-
# the same distribution terms that you use for the rest of that
|
28
|
-
|
29
|
-
|
30
|
-
# Originally written by Per Bothner. Please send patches (context
|
31
|
-
# diff format) to <config-patches@gnu.org> and include a ChangeLog
|
32
|
-
# entry.
|
23
|
+
# the same distribution terms that you use for the rest of that
|
24
|
+
# program. This Exception is an additional permission under section 7
|
25
|
+
# of the GNU General Public License, version 3 ("GPLv3").
|
33
26
|
#
|
34
|
-
#
|
35
|
-
# config.sub. If it succeeds, it prints the system name on stdout, and
|
36
|
-
# exits with 0. Otherwise, it exits with 1.
|
27
|
+
# Originally written by Per Bothner; maintained since 2000 by Ben Elliston.
|
37
28
|
#
|
38
29
|
# You can get the latest version of this script from:
|
39
|
-
#
|
30
|
+
# https://git.savannah.gnu.org/gitweb/?p=config.git;a=blob_plain;f=config.guess
|
31
|
+
#
|
32
|
+
# Please send patches to <config-patches@gnu.org>.
|
33
|
+
|
40
34
|
|
41
35
|
me=`echo "$0" | sed -e 's,.*/,,'`
|
42
36
|
|
@@ -45,7 +39,7 @@ Usage: $0 [OPTION]
|
|
45
39
|
|
46
40
|
Output the configuration name of the system \`$me' is run on.
|
47
41
|
|
48
|
-
|
42
|
+
Options:
|
49
43
|
-h, --help print this help, then exit
|
50
44
|
-t, --time-stamp print date of last modification, then exit
|
51
45
|
-v, --version print version number, then exit
|
@@ -56,8 +50,7 @@ version="\
|
|
56
50
|
GNU config.guess ($timestamp)
|
57
51
|
|
58
52
|
Originally written by Per Bothner.
|
59
|
-
Copyright
|
60
|
-
2002, 2003, 2004, 2005, 2006, 2007, 2008 Free Software Foundation, Inc.
|
53
|
+
Copyright 1992-2020 Free Software Foundation, Inc.
|
61
54
|
|
62
55
|
This is free software; see the source for copying conditions. There is NO
|
63
56
|
warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE."
|
@@ -91,8 +84,6 @@ if test $# != 0; then
|
|
91
84
|
exit 1
|
92
85
|
fi
|
93
86
|
|
94
|
-
trap 'exit 1' 1 2 15
|
95
|
-
|
96
87
|
# CC_FOR_BUILD -- compiler used by this script. Note that the use of a
|
97
88
|
# compiler to aid in system detection is discouraged as it requires
|
98
89
|
# temporary files to be created and, as you can see below, it is a
|
@@ -103,34 +94,40 @@ trap 'exit 1' 1 2 15
|
|
103
94
|
|
104
95
|
# Portable tmp directory creation inspired by the Autoconf team.
|
105
96
|
|
106
|
-
|
107
|
-
|
108
|
-
trap
|
109
|
-
|
110
|
-
|
111
|
-
|
112
|
-
|
113
|
-
|
114
|
-
|
115
|
-
|
116
|
-
|
117
|
-
|
118
|
-
|
119
|
-
|
120
|
-
|
121
|
-
|
122
|
-
|
123
|
-
|
124
|
-
|
125
|
-
|
126
|
-
|
127
|
-
|
128
|
-
|
129
|
-
|
97
|
+
tmp=
|
98
|
+
# shellcheck disable=SC2172
|
99
|
+
trap 'test -z "$tmp" || rm -fr "$tmp"' 0 1 2 13 15
|
100
|
+
|
101
|
+
set_cc_for_build() {
|
102
|
+
# prevent multiple calls if $tmp is already set
|
103
|
+
test "$tmp" && return 0
|
104
|
+
: "${TMPDIR=/tmp}"
|
105
|
+
# shellcheck disable=SC2039
|
106
|
+
{ tmp=`(umask 077 && mktemp -d "$TMPDIR/cgXXXXXX") 2>/dev/null` && test -n "$tmp" && test -d "$tmp" ; } ||
|
107
|
+
{ test -n "$RANDOM" && tmp=$TMPDIR/cg$$-$RANDOM && (umask 077 && mkdir "$tmp" 2>/dev/null) ; } ||
|
108
|
+
{ tmp=$TMPDIR/cg-$$ && (umask 077 && mkdir "$tmp" 2>/dev/null) && echo "Warning: creating insecure temp directory" >&2 ; } ||
|
109
|
+
{ echo "$me: cannot create a temporary directory in $TMPDIR" >&2 ; exit 1 ; }
|
110
|
+
dummy=$tmp/dummy
|
111
|
+
case ${CC_FOR_BUILD-},${HOST_CC-},${CC-} in
|
112
|
+
,,) echo "int x;" > "$dummy.c"
|
113
|
+
for driver in cc gcc c89 c99 ; do
|
114
|
+
if ($driver -c -o "$dummy.o" "$dummy.c") >/dev/null 2>&1 ; then
|
115
|
+
CC_FOR_BUILD="$driver"
|
116
|
+
break
|
117
|
+
fi
|
118
|
+
done
|
119
|
+
if test x"$CC_FOR_BUILD" = x ; then
|
120
|
+
CC_FOR_BUILD=no_compiler_found
|
121
|
+
fi
|
122
|
+
;;
|
123
|
+
,,*) CC_FOR_BUILD=$CC ;;
|
124
|
+
,*,*) CC_FOR_BUILD=$HOST_CC ;;
|
125
|
+
esac
|
126
|
+
}
|
130
127
|
|
131
128
|
# This is needed to find uname on a Pyramid OSx when run in the BSD universe.
|
132
129
|
# (ghazi@noc.rutgers.edu 1994-08-24)
|
133
|
-
if
|
130
|
+
if test -f /.attbin/uname ; then
|
134
131
|
PATH=$PATH:/.attbin ; export PATH
|
135
132
|
fi
|
136
133
|
|
@@ -139,12 +136,40 @@ UNAME_RELEASE=`(uname -r) 2>/dev/null` || UNAME_RELEASE=unknown
|
|
139
136
|
UNAME_SYSTEM=`(uname -s) 2>/dev/null` || UNAME_SYSTEM=unknown
|
140
137
|
UNAME_VERSION=`(uname -v) 2>/dev/null` || UNAME_VERSION=unknown
|
141
138
|
|
139
|
+
case "$UNAME_SYSTEM" in
|
140
|
+
Linux|GNU|GNU/*)
|
141
|
+
# If the system lacks a compiler, then just pick glibc.
|
142
|
+
# We could probably try harder.
|
143
|
+
LIBC=gnu
|
144
|
+
|
145
|
+
set_cc_for_build
|
146
|
+
cat <<-EOF > "$dummy.c"
|
147
|
+
#include <features.h>
|
148
|
+
#if defined(__UCLIBC__)
|
149
|
+
LIBC=uclibc
|
150
|
+
#elif defined(__dietlibc__)
|
151
|
+
LIBC=dietlibc
|
152
|
+
#else
|
153
|
+
LIBC=gnu
|
154
|
+
#endif
|
155
|
+
EOF
|
156
|
+
eval "`$CC_FOR_BUILD -E "$dummy.c" 2>/dev/null | grep '^LIBC' | sed 's, ,,g'`"
|
157
|
+
|
158
|
+
# If ldd exists, use it to detect musl libc.
|
159
|
+
if command -v ldd >/dev/null && \
|
160
|
+
ldd --version 2>&1 | grep -q ^musl
|
161
|
+
then
|
162
|
+
LIBC=musl
|
163
|
+
fi
|
164
|
+
;;
|
165
|
+
esac
|
166
|
+
|
142
167
|
# Note: order is significant - the case branches are not exclusive.
|
143
168
|
|
144
|
-
case "$
|
169
|
+
case "$UNAME_MACHINE:$UNAME_SYSTEM:$UNAME_RELEASE:$UNAME_VERSION" in
|
145
170
|
*:NetBSD:*:*)
|
146
171
|
# NetBSD (nbsd) targets should (where applicable) match one or
|
147
|
-
# more of the
|
172
|
+
# more of the tuples: *-*-netbsdelf*, *-*-netbsdaout*,
|
148
173
|
# *-*-netbsdecoff* and *-*-netbsd*. For targets that recently
|
149
174
|
# switched to ELF, *-*-netbsd* would select the old
|
150
175
|
# object file format. This provides both forward
|
@@ -154,21 +179,31 @@ case "${UNAME_MACHINE}:${UNAME_SYSTEM}:${UNAME_RELEASE}:${UNAME_VERSION}" in
|
|
154
179
|
# Note: NetBSD doesn't particularly care about the vendor
|
155
180
|
# portion of the name. We always set it to "unknown".
|
156
181
|
sysctl="sysctl -n hw.machine_arch"
|
157
|
-
UNAME_MACHINE_ARCH=`(
|
158
|
-
/
|
159
|
-
|
182
|
+
UNAME_MACHINE_ARCH=`(uname -p 2>/dev/null || \
|
183
|
+
"/sbin/$sysctl" 2>/dev/null || \
|
184
|
+
"/usr/sbin/$sysctl" 2>/dev/null || \
|
185
|
+
echo unknown)`
|
186
|
+
case "$UNAME_MACHINE_ARCH" in
|
160
187
|
armeb) machine=armeb-unknown ;;
|
161
188
|
arm*) machine=arm-unknown ;;
|
162
189
|
sh3el) machine=shl-unknown ;;
|
163
190
|
sh3eb) machine=sh-unknown ;;
|
164
191
|
sh5el) machine=sh5le-unknown ;;
|
165
|
-
*)
|
192
|
+
earmv*)
|
193
|
+
arch=`echo "$UNAME_MACHINE_ARCH" | sed -e 's,^e\(armv[0-9]\).*$,\1,'`
|
194
|
+
endian=`echo "$UNAME_MACHINE_ARCH" | sed -ne 's,^.*\(eb\)$,\1,p'`
|
195
|
+
machine="${arch}${endian}"-unknown
|
196
|
+
;;
|
197
|
+
*) machine="$UNAME_MACHINE_ARCH"-unknown ;;
|
166
198
|
esac
|
167
199
|
# The Operating System including object format, if it has switched
|
168
|
-
# to ELF recently
|
169
|
-
case "$
|
200
|
+
# to ELF recently (or will in the future) and ABI.
|
201
|
+
case "$UNAME_MACHINE_ARCH" in
|
202
|
+
earm*)
|
203
|
+
os=netbsdelf
|
204
|
+
;;
|
170
205
|
arm*|i386|m68k|ns32k|sh3*|sparc|vax)
|
171
|
-
|
206
|
+
set_cc_for_build
|
172
207
|
if echo __ELF__ | $CC_FOR_BUILD -E - 2>/dev/null \
|
173
208
|
| grep -q __ELF__
|
174
209
|
then
|
@@ -180,7 +215,14 @@ case "${UNAME_MACHINE}:${UNAME_SYSTEM}:${UNAME_RELEASE}:${UNAME_VERSION}" in
|
|
180
215
|
fi
|
181
216
|
;;
|
182
217
|
*)
|
183
|
-
|
218
|
+
os=netbsd
|
219
|
+
;;
|
220
|
+
esac
|
221
|
+
# Determine ABI tags.
|
222
|
+
case "$UNAME_MACHINE_ARCH" in
|
223
|
+
earm*)
|
224
|
+
expr='s/^earmv[0-9]/-eabi/;s/eb$//'
|
225
|
+
abi=`echo "$UNAME_MACHINE_ARCH" | sed -e "$expr"`
|
184
226
|
;;
|
185
227
|
esac
|
186
228
|
# The OS release
|
@@ -188,34 +230,60 @@ case "${UNAME_MACHINE}:${UNAME_SYSTEM}:${UNAME_RELEASE}:${UNAME_VERSION}" in
|
|
188
230
|
# thus, need a distinct triplet. However, they do not need
|
189
231
|
# kernel version information, so it can be replaced with a
|
190
232
|
# suitable tag, in the style of linux-gnu.
|
191
|
-
case "$
|
233
|
+
case "$UNAME_VERSION" in
|
192
234
|
Debian*)
|
193
235
|
release='-gnu'
|
194
236
|
;;
|
195
237
|
*)
|
196
|
-
release=`echo $
|
238
|
+
release=`echo "$UNAME_RELEASE" | sed -e 's/[-_].*//' | cut -d. -f1,2`
|
197
239
|
;;
|
198
240
|
esac
|
199
241
|
# Since CPU_TYPE-MANUFACTURER-KERNEL-OPERATING_SYSTEM:
|
200
242
|
# contains redundant information, the shorter form:
|
201
243
|
# CPU_TYPE-MANUFACTURER-OPERATING_SYSTEM is used.
|
202
|
-
echo "$
|
244
|
+
echo "$machine-${os}${release}${abi-}"
|
245
|
+
exit ;;
|
246
|
+
*:Bitrig:*:*)
|
247
|
+
UNAME_MACHINE_ARCH=`arch | sed 's/Bitrig.//'`
|
248
|
+
echo "$UNAME_MACHINE_ARCH"-unknown-bitrig"$UNAME_RELEASE"
|
203
249
|
exit ;;
|
204
250
|
*:OpenBSD:*:*)
|
205
251
|
UNAME_MACHINE_ARCH=`arch | sed 's/OpenBSD.//'`
|
206
|
-
echo $
|
252
|
+
echo "$UNAME_MACHINE_ARCH"-unknown-openbsd"$UNAME_RELEASE"
|
253
|
+
exit ;;
|
254
|
+
*:LibertyBSD:*:*)
|
255
|
+
UNAME_MACHINE_ARCH=`arch | sed 's/^.*BSD\.//'`
|
256
|
+
echo "$UNAME_MACHINE_ARCH"-unknown-libertybsd"$UNAME_RELEASE"
|
257
|
+
exit ;;
|
258
|
+
*:MidnightBSD:*:*)
|
259
|
+
echo "$UNAME_MACHINE"-unknown-midnightbsd"$UNAME_RELEASE"
|
207
260
|
exit ;;
|
208
261
|
*:ekkoBSD:*:*)
|
209
|
-
echo $
|
262
|
+
echo "$UNAME_MACHINE"-unknown-ekkobsd"$UNAME_RELEASE"
|
210
263
|
exit ;;
|
211
264
|
*:SolidBSD:*:*)
|
212
|
-
echo $
|
265
|
+
echo "$UNAME_MACHINE"-unknown-solidbsd"$UNAME_RELEASE"
|
266
|
+
exit ;;
|
267
|
+
*:OS108:*:*)
|
268
|
+
echo "$UNAME_MACHINE"-unknown-os108_"$UNAME_RELEASE"
|
213
269
|
exit ;;
|
214
270
|
macppc:MirBSD:*:*)
|
215
|
-
echo powerpc-unknown-mirbsd$
|
271
|
+
echo powerpc-unknown-mirbsd"$UNAME_RELEASE"
|
216
272
|
exit ;;
|
217
273
|
*:MirBSD:*:*)
|
218
|
-
echo $
|
274
|
+
echo "$UNAME_MACHINE"-unknown-mirbsd"$UNAME_RELEASE"
|
275
|
+
exit ;;
|
276
|
+
*:Sortix:*:*)
|
277
|
+
echo "$UNAME_MACHINE"-unknown-sortix
|
278
|
+
exit ;;
|
279
|
+
*:Twizzler:*:*)
|
280
|
+
echo "$UNAME_MACHINE"-unknown-twizzler
|
281
|
+
exit ;;
|
282
|
+
*:Redox:*:*)
|
283
|
+
echo "$UNAME_MACHINE"-unknown-redox
|
284
|
+
exit ;;
|
285
|
+
mips:OSF1:*.*)
|
286
|
+
echo mips-dec-osf1
|
219
287
|
exit ;;
|
220
288
|
alpha:OSF1:*:*)
|
221
289
|
case $UNAME_RELEASE in
|
@@ -223,7 +291,7 @@ case "${UNAME_MACHINE}:${UNAME_SYSTEM}:${UNAME_RELEASE}:${UNAME_VERSION}" in
|
|
223
291
|
UNAME_RELEASE=`/usr/sbin/sizer -v | awk '{print $3}'`
|
224
292
|
;;
|
225
293
|
*5.*)
|
226
|
-
|
294
|
+
UNAME_RELEASE=`/usr/sbin/sizer -v | awk '{print $4}'`
|
227
295
|
;;
|
228
296
|
esac
|
229
297
|
# According to Compaq, /usr/sbin/psrinfo has been available on
|
@@ -233,60 +301,54 @@ case "${UNAME_MACHINE}:${UNAME_SYSTEM}:${UNAME_RELEASE}:${UNAME_VERSION}" in
|
|
233
301
|
ALPHA_CPU_TYPE=`/usr/sbin/psrinfo -v | sed -n -e 's/^ The alpha \(.*\) processor.*$/\1/p' | head -n 1`
|
234
302
|
case "$ALPHA_CPU_TYPE" in
|
235
303
|
"EV4 (21064)")
|
236
|
-
UNAME_MACHINE=
|
304
|
+
UNAME_MACHINE=alpha ;;
|
237
305
|
"EV4.5 (21064)")
|
238
|
-
UNAME_MACHINE=
|
306
|
+
UNAME_MACHINE=alpha ;;
|
239
307
|
"LCA4 (21066/21068)")
|
240
|
-
UNAME_MACHINE=
|
308
|
+
UNAME_MACHINE=alpha ;;
|
241
309
|
"EV5 (21164)")
|
242
|
-
UNAME_MACHINE=
|
310
|
+
UNAME_MACHINE=alphaev5 ;;
|
243
311
|
"EV5.6 (21164A)")
|
244
|
-
UNAME_MACHINE=
|
312
|
+
UNAME_MACHINE=alphaev56 ;;
|
245
313
|
"EV5.6 (21164PC)")
|
246
|
-
UNAME_MACHINE=
|
314
|
+
UNAME_MACHINE=alphapca56 ;;
|
247
315
|
"EV5.7 (21164PC)")
|
248
|
-
UNAME_MACHINE=
|
316
|
+
UNAME_MACHINE=alphapca57 ;;
|
249
317
|
"EV6 (21264)")
|
250
|
-
UNAME_MACHINE=
|
318
|
+
UNAME_MACHINE=alphaev6 ;;
|
251
319
|
"EV6.7 (21264A)")
|
252
|
-
UNAME_MACHINE=
|
320
|
+
UNAME_MACHINE=alphaev67 ;;
|
253
321
|
"EV6.8CB (21264C)")
|
254
|
-
UNAME_MACHINE=
|
322
|
+
UNAME_MACHINE=alphaev68 ;;
|
255
323
|
"EV6.8AL (21264B)")
|
256
|
-
UNAME_MACHINE=
|
324
|
+
UNAME_MACHINE=alphaev68 ;;
|
257
325
|
"EV6.8CX (21264D)")
|
258
|
-
UNAME_MACHINE=
|
326
|
+
UNAME_MACHINE=alphaev68 ;;
|
259
327
|
"EV6.9A (21264/EV69A)")
|
260
|
-
UNAME_MACHINE=
|
328
|
+
UNAME_MACHINE=alphaev69 ;;
|
261
329
|
"EV7 (21364)")
|
262
|
-
UNAME_MACHINE=
|
330
|
+
UNAME_MACHINE=alphaev7 ;;
|
263
331
|
"EV7.9 (21364A)")
|
264
|
-
UNAME_MACHINE=
|
332
|
+
UNAME_MACHINE=alphaev79 ;;
|
265
333
|
esac
|
266
334
|
# A Pn.n version is a patched version.
|
267
335
|
# A Vn.n version is a released version.
|
268
336
|
# A Tn.n version is a released field test version.
|
269
337
|
# A Xn.n version is an unreleased experimental baselevel.
|
270
338
|
# 1.2 uses "1.2" for uname -r.
|
271
|
-
echo $
|
272
|
-
exit
|
273
|
-
|
274
|
-
|
275
|
-
|
276
|
-
# of the specific Alpha model?
|
277
|
-
echo alpha-pc-interix
|
278
|
-
exit ;;
|
279
|
-
21064:Windows_NT:50:3)
|
280
|
-
echo alpha-dec-winnt3.5
|
281
|
-
exit ;;
|
339
|
+
echo "$UNAME_MACHINE"-dec-osf"`echo "$UNAME_RELEASE" | sed -e 's/^[PVTX]//' | tr ABCDEFGHIJKLMNOPQRSTUVWXYZ abcdefghijklmnopqrstuvwxyz`"
|
340
|
+
# Reset EXIT trap before exiting to avoid spurious non-zero exit code.
|
341
|
+
exitcode=$?
|
342
|
+
trap '' 0
|
343
|
+
exit $exitcode ;;
|
282
344
|
Amiga*:UNIX_System_V:4.0:*)
|
283
345
|
echo m68k-unknown-sysv4
|
284
346
|
exit ;;
|
285
347
|
*:[Aa]miga[Oo][Ss]:*:*)
|
286
|
-
echo $
|
348
|
+
echo "$UNAME_MACHINE"-unknown-amigaos
|
287
349
|
exit ;;
|
288
350
|
*:[Mm]orph[Oo][Ss]:*:*)
|
289
|
-
echo $
|
351
|
+
echo "$UNAME_MACHINE"-unknown-morphos
|
290
352
|
exit ;;
|
291
353
|
*:OS/390:*:*)
|
292
354
|
echo i370-ibm-openedition
|
@@ -295,12 +357,12 @@ case "${UNAME_MACHINE}:${UNAME_SYSTEM}:${UNAME_RELEASE}:${UNAME_VERSION}" in
|
|
295
357
|
echo s390-ibm-zvmoe
|
296
358
|
exit ;;
|
297
359
|
*:OS400:*:*)
|
298
|
-
|
360
|
+
echo powerpc-ibm-os400
|
299
361
|
exit ;;
|
300
362
|
arm:RISC*:1.[012]*:*|arm:riscix:1.[012]*:*)
|
301
|
-
echo arm-acorn-riscix$
|
363
|
+
echo arm-acorn-riscix"$UNAME_RELEASE"
|
302
364
|
exit ;;
|
303
|
-
arm
|
365
|
+
arm*:riscos:*:*|arm*:RISCOS:*:*)
|
304
366
|
echo arm-unknown-riscos
|
305
367
|
exit ;;
|
306
368
|
SR2?01:HI-UX/MPP:*:* | SR8000:HI-UX/MPP:*:*)
|
@@ -325,38 +387,38 @@ case "${UNAME_MACHINE}:${UNAME_SYSTEM}:${UNAME_RELEASE}:${UNAME_VERSION}" in
|
|
325
387
|
sparc) echo sparc-icl-nx7; exit ;;
|
326
388
|
esac ;;
|
327
389
|
s390x:SunOS:*:*)
|
328
|
-
echo $
|
390
|
+
echo "$UNAME_MACHINE"-ibm-solaris2"`echo "$UNAME_RELEASE" | sed -e 's/[^.]*//'`"
|
329
391
|
exit ;;
|
330
392
|
sun4H:SunOS:5.*:*)
|
331
|
-
echo sparc-hal-solaris2`echo $
|
393
|
+
echo sparc-hal-solaris2"`echo "$UNAME_RELEASE"|sed -e 's/[^.]*//'`"
|
332
394
|
exit ;;
|
333
395
|
sun4*:SunOS:5.*:* | tadpole*:SunOS:5.*:*)
|
334
|
-
echo sparc-sun-solaris2`echo $
|
396
|
+
echo sparc-sun-solaris2"`echo "$UNAME_RELEASE" | sed -e 's/[^.]*//'`"
|
335
397
|
exit ;;
|
336
398
|
i86pc:AuroraUX:5.*:* | i86xen:AuroraUX:5.*:*)
|
337
|
-
echo i386-pc-auroraux$
|
399
|
+
echo i386-pc-auroraux"$UNAME_RELEASE"
|
338
400
|
exit ;;
|
339
401
|
i86pc:SunOS:5.*:* | i86xen:SunOS:5.*:*)
|
340
|
-
|
341
|
-
SUN_ARCH=
|
402
|
+
set_cc_for_build
|
403
|
+
SUN_ARCH=i386
|
342
404
|
# If there is a compiler, see if it is configured for 64-bit objects.
|
343
405
|
# Note that the Sun cc does not turn __LP64__ into 1 like gcc does.
|
344
406
|
# This test works for both compilers.
|
345
|
-
if [ "$CC_FOR_BUILD" !=
|
407
|
+
if [ "$CC_FOR_BUILD" != no_compiler_found ]; then
|
346
408
|
if (echo '#ifdef __amd64'; echo IS_64BIT_ARCH; echo '#endif') | \
|
347
|
-
(CCOPTS= $CC_FOR_BUILD -E - 2>/dev/null) | \
|
409
|
+
(CCOPTS="" $CC_FOR_BUILD -E - 2>/dev/null) | \
|
348
410
|
grep IS_64BIT_ARCH >/dev/null
|
349
411
|
then
|
350
|
-
SUN_ARCH=
|
412
|
+
SUN_ARCH=x86_64
|
351
413
|
fi
|
352
414
|
fi
|
353
|
-
echo $
|
415
|
+
echo "$SUN_ARCH"-pc-solaris2"`echo "$UNAME_RELEASE"|sed -e 's/[^.]*//'`"
|
354
416
|
exit ;;
|
355
417
|
sun4*:SunOS:6*:*)
|
356
418
|
# According to config.sub, this is the proper way to canonicalize
|
357
419
|
# SunOS6. Hard to guess exactly what SunOS6 will be like, but
|
358
420
|
# it's likely to be more like Solaris than SunOS4.
|
359
|
-
echo sparc-sun-solaris3`echo $
|
421
|
+
echo sparc-sun-solaris3"`echo "$UNAME_RELEASE"|sed -e 's/[^.]*//'`"
|
360
422
|
exit ;;
|
361
423
|
sun4*:SunOS:*:*)
|
362
424
|
case "`/usr/bin/arch -k`" in
|
@@ -365,25 +427,25 @@ case "${UNAME_MACHINE}:${UNAME_SYSTEM}:${UNAME_RELEASE}:${UNAME_VERSION}" in
|
|
365
427
|
;;
|
366
428
|
esac
|
367
429
|
# Japanese Language versions have a version number like `4.1.3-JL'.
|
368
|
-
echo sparc-sun-sunos`echo $
|
430
|
+
echo sparc-sun-sunos"`echo "$UNAME_RELEASE"|sed -e 's/-/_/'`"
|
369
431
|
exit ;;
|
370
432
|
sun3*:SunOS:*:*)
|
371
|
-
echo m68k-sun-sunos$
|
433
|
+
echo m68k-sun-sunos"$UNAME_RELEASE"
|
372
434
|
exit ;;
|
373
435
|
sun*:*:4.2BSD:*)
|
374
436
|
UNAME_RELEASE=`(sed 1q /etc/motd | awk '{print substr($5,1,3)}') 2>/dev/null`
|
375
|
-
test "x$
|
437
|
+
test "x$UNAME_RELEASE" = x && UNAME_RELEASE=3
|
376
438
|
case "`/bin/arch`" in
|
377
439
|
sun3)
|
378
|
-
echo m68k-sun-sunos$
|
440
|
+
echo m68k-sun-sunos"$UNAME_RELEASE"
|
379
441
|
;;
|
380
442
|
sun4)
|
381
|
-
echo sparc-sun-sunos$
|
443
|
+
echo sparc-sun-sunos"$UNAME_RELEASE"
|
382
444
|
;;
|
383
445
|
esac
|
384
446
|
exit ;;
|
385
447
|
aushp:SunOS:*:*)
|
386
|
-
echo sparc-auspex-sunos$
|
448
|
+
echo sparc-auspex-sunos"$UNAME_RELEASE"
|
387
449
|
exit ;;
|
388
450
|
# The situation for MiNT is a little confusing. The machine name
|
389
451
|
# can be virtually everything (everything which is not
|
@@ -394,44 +456,44 @@ case "${UNAME_MACHINE}:${UNAME_SYSTEM}:${UNAME_RELEASE}:${UNAME_VERSION}" in
|
|
394
456
|
# MiNT. But MiNT is downward compatible to TOS, so this should
|
395
457
|
# be no problem.
|
396
458
|
atarist[e]:*MiNT:*:* | atarist[e]:*mint:*:* | atarist[e]:*TOS:*:*)
|
397
|
-
|
459
|
+
echo m68k-atari-mint"$UNAME_RELEASE"
|
398
460
|
exit ;;
|
399
461
|
atari*:*MiNT:*:* | atari*:*mint:*:* | atarist[e]:*TOS:*:*)
|
400
|
-
echo m68k-atari-mint$
|
401
|
-
|
462
|
+
echo m68k-atari-mint"$UNAME_RELEASE"
|
463
|
+
exit ;;
|
402
464
|
*falcon*:*MiNT:*:* | *falcon*:*mint:*:* | *falcon*:*TOS:*:*)
|
403
|
-
|
465
|
+
echo m68k-atari-mint"$UNAME_RELEASE"
|
404
466
|
exit ;;
|
405
467
|
milan*:*MiNT:*:* | milan*:*mint:*:* | *milan*:*TOS:*:*)
|
406
|
-
|
407
|
-
|
468
|
+
echo m68k-milan-mint"$UNAME_RELEASE"
|
469
|
+
exit ;;
|
408
470
|
hades*:*MiNT:*:* | hades*:*mint:*:* | *hades*:*TOS:*:*)
|
409
|
-
|
410
|
-
|
471
|
+
echo m68k-hades-mint"$UNAME_RELEASE"
|
472
|
+
exit ;;
|
411
473
|
*:*MiNT:*:* | *:*mint:*:* | *:*TOS:*:*)
|
412
|
-
|
413
|
-
|
474
|
+
echo m68k-unknown-mint"$UNAME_RELEASE"
|
475
|
+
exit ;;
|
414
476
|
m68k:machten:*:*)
|
415
|
-
echo m68k-apple-machten$
|
477
|
+
echo m68k-apple-machten"$UNAME_RELEASE"
|
416
478
|
exit ;;
|
417
479
|
powerpc:machten:*:*)
|
418
|
-
echo powerpc-apple-machten$
|
480
|
+
echo powerpc-apple-machten"$UNAME_RELEASE"
|
419
481
|
exit ;;
|
420
482
|
RISC*:Mach:*:*)
|
421
483
|
echo mips-dec-mach_bsd4.3
|
422
484
|
exit ;;
|
423
485
|
RISC*:ULTRIX:*:*)
|
424
|
-
echo mips-dec-ultrix$
|
486
|
+
echo mips-dec-ultrix"$UNAME_RELEASE"
|
425
487
|
exit ;;
|
426
488
|
VAX*:ULTRIX*:*:*)
|
427
|
-
echo vax-dec-ultrix$
|
489
|
+
echo vax-dec-ultrix"$UNAME_RELEASE"
|
428
490
|
exit ;;
|
429
491
|
2020:CLIX:*:* | 2430:CLIX:*:*)
|
430
|
-
echo clipper-intergraph-clix$
|
492
|
+
echo clipper-intergraph-clix"$UNAME_RELEASE"
|
431
493
|
exit ;;
|
432
494
|
mips:*:*:UMIPS | mips:*:*:RISCos)
|
433
|
-
|
434
|
-
sed 's/^ //' << EOF
|
495
|
+
set_cc_for_build
|
496
|
+
sed 's/^ //' << EOF > "$dummy.c"
|
435
497
|
#ifdef __cplusplus
|
436
498
|
#include <stdio.h> /* for printf() prototype */
|
437
499
|
int main (int argc, char *argv[]) {
|
@@ -440,23 +502,23 @@ case "${UNAME_MACHINE}:${UNAME_SYSTEM}:${UNAME_RELEASE}:${UNAME_VERSION}" in
|
|
440
502
|
#endif
|
441
503
|
#if defined (host_mips) && defined (MIPSEB)
|
442
504
|
#if defined (SYSTYPE_SYSV)
|
443
|
-
printf ("mips-mips-riscos%ssysv
|
505
|
+
printf ("mips-mips-riscos%ssysv\\n", argv[1]); exit (0);
|
444
506
|
#endif
|
445
507
|
#if defined (SYSTYPE_SVR4)
|
446
|
-
printf ("mips-mips-riscos%ssvr4
|
508
|
+
printf ("mips-mips-riscos%ssvr4\\n", argv[1]); exit (0);
|
447
509
|
#endif
|
448
510
|
#if defined (SYSTYPE_BSD43) || defined(SYSTYPE_BSD)
|
449
|
-
printf ("mips-mips-riscos%sbsd
|
511
|
+
printf ("mips-mips-riscos%sbsd\\n", argv[1]); exit (0);
|
450
512
|
#endif
|
451
513
|
#endif
|
452
514
|
exit (-1);
|
453
515
|
}
|
454
516
|
EOF
|
455
|
-
$CC_FOR_BUILD -o $dummy $dummy.c &&
|
456
|
-
dummyarg=`echo "$
|
457
|
-
SYSTEM_NAME
|
517
|
+
$CC_FOR_BUILD -o "$dummy" "$dummy.c" &&
|
518
|
+
dummyarg=`echo "$UNAME_RELEASE" | sed -n 's/\([0-9]*\).*/\1/p'` &&
|
519
|
+
SYSTEM_NAME=`"$dummy" "$dummyarg"` &&
|
458
520
|
{ echo "$SYSTEM_NAME"; exit; }
|
459
|
-
echo mips-mips-riscos$
|
521
|
+
echo mips-mips-riscos"$UNAME_RELEASE"
|
460
522
|
exit ;;
|
461
523
|
Motorola:PowerMAX_OS:*:*)
|
462
524
|
echo powerpc-motorola-powermax
|
@@ -480,21 +542,21 @@ EOF
|
|
480
542
|
echo m88k-motorola-sysv3
|
481
543
|
exit ;;
|
482
544
|
AViiON:dgux:*:*)
|
483
|
-
|
484
|
-
|
485
|
-
if [ $UNAME_PROCESSOR = mc88100 ] || [ $UNAME_PROCESSOR = mc88110 ]
|
545
|
+
# DG/UX returns AViiON for all architectures
|
546
|
+
UNAME_PROCESSOR=`/usr/bin/uname -p`
|
547
|
+
if [ "$UNAME_PROCESSOR" = mc88100 ] || [ "$UNAME_PROCESSOR" = mc88110 ]
|
486
548
|
then
|
487
|
-
if [ $
|
488
|
-
[ $
|
549
|
+
if [ "$TARGET_BINARY_INTERFACE"x = m88kdguxelfx ] || \
|
550
|
+
[ "$TARGET_BINARY_INTERFACE"x = x ]
|
489
551
|
then
|
490
|
-
echo m88k-dg-dgux$
|
552
|
+
echo m88k-dg-dgux"$UNAME_RELEASE"
|
491
553
|
else
|
492
|
-
echo m88k-dg-dguxbcs$
|
554
|
+
echo m88k-dg-dguxbcs"$UNAME_RELEASE"
|
493
555
|
fi
|
494
556
|
else
|
495
|
-
echo i586-dg-dgux$
|
557
|
+
echo i586-dg-dgux"$UNAME_RELEASE"
|
496
558
|
fi
|
497
|
-
|
559
|
+
exit ;;
|
498
560
|
M88*:DolphinOS:*:*) # DolphinOS (SVR3)
|
499
561
|
echo m88k-dolphin-sysv3
|
500
562
|
exit ;;
|
@@ -509,7 +571,7 @@ EOF
|
|
509
571
|
echo m68k-tektronix-bsd
|
510
572
|
exit ;;
|
511
573
|
*:IRIX*:*:*)
|
512
|
-
echo mips-sgi-irix`echo $
|
574
|
+
echo mips-sgi-irix"`echo "$UNAME_RELEASE"|sed -e 's/-/_/g'`"
|
513
575
|
exit ;;
|
514
576
|
????????:AIX?:[12].1:2) # AIX 2.2.1 or AIX 2.1.1 is RT/PC AIX.
|
515
577
|
echo romp-ibm-aix # uname -m gives an 8 hex-code CPU id
|
@@ -521,14 +583,14 @@ EOF
|
|
521
583
|
if [ -x /usr/bin/oslevel ] ; then
|
522
584
|
IBM_REV=`/usr/bin/oslevel`
|
523
585
|
else
|
524
|
-
IBM_REV
|
586
|
+
IBM_REV="$UNAME_VERSION.$UNAME_RELEASE"
|
525
587
|
fi
|
526
|
-
echo $
|
588
|
+
echo "$UNAME_MACHINE"-ibm-aix"$IBM_REV"
|
527
589
|
exit ;;
|
528
590
|
*:AIX:2:3)
|
529
591
|
if grep bos325 /usr/include/stdio.h >/dev/null 2>&1; then
|
530
|
-
|
531
|
-
sed 's/^ //' << EOF
|
592
|
+
set_cc_for_build
|
593
|
+
sed 's/^ //' << EOF > "$dummy.c"
|
532
594
|
#include <sys/systemcfg.h>
|
533
595
|
|
534
596
|
main()
|
@@ -539,7 +601,7 @@ EOF
|
|
539
601
|
exit(0);
|
540
602
|
}
|
541
603
|
EOF
|
542
|
-
if $CC_FOR_BUILD -o $dummy $dummy.c && SYSTEM_NAME
|
604
|
+
if $CC_FOR_BUILD -o "$dummy" "$dummy.c" && SYSTEM_NAME=`"$dummy"`
|
543
605
|
then
|
544
606
|
echo "$SYSTEM_NAME"
|
545
607
|
else
|
@@ -551,28 +613,29 @@ EOF
|
|
551
613
|
echo rs6000-ibm-aix3.2
|
552
614
|
fi
|
553
615
|
exit ;;
|
554
|
-
*:AIX:*:[
|
616
|
+
*:AIX:*:[4567])
|
555
617
|
IBM_CPU_ID=`/usr/sbin/lsdev -C -c processor -S available | sed 1q | awk '{ print $1 }'`
|
556
|
-
if /usr/sbin/lsattr -El $
|
618
|
+
if /usr/sbin/lsattr -El "$IBM_CPU_ID" | grep ' POWER' >/dev/null 2>&1; then
|
557
619
|
IBM_ARCH=rs6000
|
558
620
|
else
|
559
621
|
IBM_ARCH=powerpc
|
560
622
|
fi
|
561
|
-
if [ -x /usr/bin/
|
562
|
-
IBM_REV=`/usr/bin/
|
623
|
+
if [ -x /usr/bin/lslpp ] ; then
|
624
|
+
IBM_REV=`/usr/bin/lslpp -Lqc bos.rte.libc |
|
625
|
+
awk -F: '{ print $3 }' | sed s/[0-9]*$/0/`
|
563
626
|
else
|
564
|
-
IBM_REV
|
627
|
+
IBM_REV="$UNAME_VERSION.$UNAME_RELEASE"
|
565
628
|
fi
|
566
|
-
echo $
|
629
|
+
echo "$IBM_ARCH"-ibm-aix"$IBM_REV"
|
567
630
|
exit ;;
|
568
631
|
*:AIX:*:*)
|
569
632
|
echo rs6000-ibm-aix
|
570
633
|
exit ;;
|
571
|
-
ibmrt:4.4BSD:*|romp-ibm:
|
634
|
+
ibmrt:4.4BSD:*|romp-ibm:4.4BSD:*)
|
572
635
|
echo romp-ibm-bsd4.4
|
573
636
|
exit ;;
|
574
637
|
ibmrt:*BSD:*|romp-ibm:BSD:*) # covers RT/PC BSD and
|
575
|
-
echo romp-ibm-bsd$
|
638
|
+
echo romp-ibm-bsd"$UNAME_RELEASE" # 4.3 with uname added to
|
576
639
|
exit ;; # report: romp-ibm BSD 4.3
|
577
640
|
*:BOSX:*:*)
|
578
641
|
echo rs6000-bull-bosx
|
@@ -587,67 +650,67 @@ EOF
|
|
587
650
|
echo m68k-hp-bsd4.4
|
588
651
|
exit ;;
|
589
652
|
9000/[34678]??:HP-UX:*:*)
|
590
|
-
HPUX_REV=`echo $
|
591
|
-
case "$
|
592
|
-
9000/31?
|
593
|
-
9000/[34]??
|
653
|
+
HPUX_REV=`echo "$UNAME_RELEASE"|sed -e 's/[^.]*.[0B]*//'`
|
654
|
+
case "$UNAME_MACHINE" in
|
655
|
+
9000/31?) HP_ARCH=m68000 ;;
|
656
|
+
9000/[34]??) HP_ARCH=m68k ;;
|
594
657
|
9000/[678][0-9][0-9])
|
595
658
|
if [ -x /usr/bin/getconf ]; then
|
596
659
|
sc_cpu_version=`/usr/bin/getconf SC_CPU_VERSION 2>/dev/null`
|
597
|
-
|
598
|
-
|
599
|
-
|
600
|
-
|
601
|
-
|
602
|
-
|
603
|
-
|
604
|
-
|
605
|
-
'') HP_ARCH=
|
606
|
-
|
607
|
-
|
660
|
+
sc_kernel_bits=`/usr/bin/getconf SC_KERNEL_BITS 2>/dev/null`
|
661
|
+
case "$sc_cpu_version" in
|
662
|
+
523) HP_ARCH=hppa1.0 ;; # CPU_PA_RISC1_0
|
663
|
+
528) HP_ARCH=hppa1.1 ;; # CPU_PA_RISC1_1
|
664
|
+
532) # CPU_PA_RISC2_0
|
665
|
+
case "$sc_kernel_bits" in
|
666
|
+
32) HP_ARCH=hppa2.0n ;;
|
667
|
+
64) HP_ARCH=hppa2.0w ;;
|
668
|
+
'') HP_ARCH=hppa2.0 ;; # HP-UX 10.20
|
669
|
+
esac ;;
|
670
|
+
esac
|
608
671
|
fi
|
609
|
-
if [ "$
|
610
|
-
|
611
|
-
sed 's/^
|
672
|
+
if [ "$HP_ARCH" = "" ]; then
|
673
|
+
set_cc_for_build
|
674
|
+
sed 's/^ //' << EOF > "$dummy.c"
|
612
675
|
|
613
|
-
|
614
|
-
|
615
|
-
|
676
|
+
#define _HPUX_SOURCE
|
677
|
+
#include <stdlib.h>
|
678
|
+
#include <unistd.h>
|
616
679
|
|
617
|
-
|
618
|
-
|
619
|
-
|
620
|
-
|
621
|
-
|
622
|
-
|
680
|
+
int main ()
|
681
|
+
{
|
682
|
+
#if defined(_SC_KERNEL_BITS)
|
683
|
+
long bits = sysconf(_SC_KERNEL_BITS);
|
684
|
+
#endif
|
685
|
+
long cpu = sysconf (_SC_CPU_VERSION);
|
623
686
|
|
624
|
-
|
625
|
-
|
626
|
-
|
627
|
-
|
628
|
-
|
629
|
-
|
630
|
-
|
631
|
-
|
632
|
-
|
633
|
-
|
634
|
-
|
635
|
-
|
636
|
-
|
637
|
-
|
638
|
-
|
639
|
-
|
640
|
-
|
641
|
-
|
642
|
-
|
687
|
+
switch (cpu)
|
688
|
+
{
|
689
|
+
case CPU_PA_RISC1_0: puts ("hppa1.0"); break;
|
690
|
+
case CPU_PA_RISC1_1: puts ("hppa1.1"); break;
|
691
|
+
case CPU_PA_RISC2_0:
|
692
|
+
#if defined(_SC_KERNEL_BITS)
|
693
|
+
switch (bits)
|
694
|
+
{
|
695
|
+
case 64: puts ("hppa2.0w"); break;
|
696
|
+
case 32: puts ("hppa2.0n"); break;
|
697
|
+
default: puts ("hppa2.0"); break;
|
698
|
+
} break;
|
699
|
+
#else /* !defined(_SC_KERNEL_BITS) */
|
700
|
+
puts ("hppa2.0"); break;
|
701
|
+
#endif
|
702
|
+
default: puts ("hppa1.0"); break;
|
703
|
+
}
|
704
|
+
exit (0);
|
705
|
+
}
|
643
706
|
EOF
|
644
|
-
(CCOPTS= $CC_FOR_BUILD -o $dummy $dummy.c 2>/dev/null) && HP_ARCH
|
707
|
+
(CCOPTS="" $CC_FOR_BUILD -o "$dummy" "$dummy.c" 2>/dev/null) && HP_ARCH=`"$dummy"`
|
645
708
|
test -z "$HP_ARCH" && HP_ARCH=hppa
|
646
709
|
fi ;;
|
647
710
|
esac
|
648
|
-
if [ $
|
711
|
+
if [ "$HP_ARCH" = hppa2.0w ]
|
649
712
|
then
|
650
|
-
|
713
|
+
set_cc_for_build
|
651
714
|
|
652
715
|
# hppa2.0w-hp-hpux* has a 64-bit kernel and a compiler generating
|
653
716
|
# 32-bit code. hppa64-hp-hpux* has the same kernel and a compiler
|
@@ -658,23 +721,23 @@ EOF
|
|
658
721
|
# $ CC_FOR_BUILD="cc +DA2.0w" ./config.guess
|
659
722
|
# => hppa64-hp-hpux11.23
|
660
723
|
|
661
|
-
if echo __LP64__ | (CCOPTS= $CC_FOR_BUILD -E - 2>/dev/null) |
|
724
|
+
if echo __LP64__ | (CCOPTS="" $CC_FOR_BUILD -E - 2>/dev/null) |
|
662
725
|
grep -q __LP64__
|
663
726
|
then
|
664
|
-
HP_ARCH=
|
727
|
+
HP_ARCH=hppa2.0w
|
665
728
|
else
|
666
|
-
HP_ARCH=
|
729
|
+
HP_ARCH=hppa64
|
667
730
|
fi
|
668
731
|
fi
|
669
|
-
echo $
|
732
|
+
echo "$HP_ARCH"-hp-hpux"$HPUX_REV"
|
670
733
|
exit ;;
|
671
734
|
ia64:HP-UX:*:*)
|
672
|
-
HPUX_REV=`echo $
|
673
|
-
echo ia64-hp-hpux$
|
735
|
+
HPUX_REV=`echo "$UNAME_RELEASE"|sed -e 's/[^.]*.[0B]*//'`
|
736
|
+
echo ia64-hp-hpux"$HPUX_REV"
|
674
737
|
exit ;;
|
675
738
|
3050*:HI-UX:*:*)
|
676
|
-
|
677
|
-
sed 's/^ //' << EOF
|
739
|
+
set_cc_for_build
|
740
|
+
sed 's/^ //' << EOF > "$dummy.c"
|
678
741
|
#include <unistd.h>
|
679
742
|
int
|
680
743
|
main ()
|
@@ -699,11 +762,11 @@ EOF
|
|
699
762
|
exit (0);
|
700
763
|
}
|
701
764
|
EOF
|
702
|
-
$CC_FOR_BUILD -o $dummy $dummy.c && SYSTEM_NAME
|
765
|
+
$CC_FOR_BUILD -o "$dummy" "$dummy.c" && SYSTEM_NAME=`"$dummy"` &&
|
703
766
|
{ echo "$SYSTEM_NAME"; exit; }
|
704
767
|
echo unknown-hitachi-hiuxwe2
|
705
768
|
exit ;;
|
706
|
-
9000/7??:4.3bsd:*:* | 9000/8?[79]:4.3bsd:*:*
|
769
|
+
9000/7??:4.3bsd:*:* | 9000/8?[79]:4.3bsd:*:*)
|
707
770
|
echo hppa1.1-hp-bsd
|
708
771
|
exit ;;
|
709
772
|
9000/8??:4.3bsd:*:*)
|
@@ -712,7 +775,7 @@ EOF
|
|
712
775
|
*9??*:MPE/iX:*:* | *3000*:MPE/iX:*:*)
|
713
776
|
echo hppa1.0-hp-mpeix
|
714
777
|
exit ;;
|
715
|
-
hp7??:OSF1:*:* | hp8?[79]:OSF1:*:*
|
778
|
+
hp7??:OSF1:*:* | hp8?[79]:OSF1:*:*)
|
716
779
|
echo hppa1.1-hp-osf
|
717
780
|
exit ;;
|
718
781
|
hp8??:OSF1:*:*)
|
@@ -720,9 +783,9 @@ EOF
|
|
720
783
|
exit ;;
|
721
784
|
i*86:OSF1:*:*)
|
722
785
|
if [ -x /usr/sbin/sysversion ] ; then
|
723
|
-
echo $
|
786
|
+
echo "$UNAME_MACHINE"-unknown-osf1mk
|
724
787
|
else
|
725
|
-
echo $
|
788
|
+
echo "$UNAME_MACHINE"-unknown-osf1
|
726
789
|
fi
|
727
790
|
exit ;;
|
728
791
|
parisc*:Lites*:*:*)
|
@@ -730,135 +793,140 @@ EOF
|
|
730
793
|
exit ;;
|
731
794
|
C1*:ConvexOS:*:* | convex:ConvexOS:C1*:*)
|
732
795
|
echo c1-convex-bsd
|
733
|
-
|
796
|
+
exit ;;
|
734
797
|
C2*:ConvexOS:*:* | convex:ConvexOS:C2*:*)
|
735
798
|
if getsysinfo -f scalar_acc
|
736
799
|
then echo c32-convex-bsd
|
737
800
|
else echo c2-convex-bsd
|
738
801
|
fi
|
739
|
-
|
802
|
+
exit ;;
|
740
803
|
C34*:ConvexOS:*:* | convex:ConvexOS:C34*:*)
|
741
804
|
echo c34-convex-bsd
|
742
|
-
|
805
|
+
exit ;;
|
743
806
|
C38*:ConvexOS:*:* | convex:ConvexOS:C38*:*)
|
744
807
|
echo c38-convex-bsd
|
745
|
-
|
808
|
+
exit ;;
|
746
809
|
C4*:ConvexOS:*:* | convex:ConvexOS:C4*:*)
|
747
810
|
echo c4-convex-bsd
|
748
|
-
|
811
|
+
exit ;;
|
749
812
|
CRAY*Y-MP:*:*:*)
|
750
|
-
echo ymp-cray-unicos$
|
813
|
+
echo ymp-cray-unicos"$UNAME_RELEASE" | sed -e 's/\.[^.]*$/.X/'
|
751
814
|
exit ;;
|
752
815
|
CRAY*[A-Z]90:*:*:*)
|
753
|
-
echo $
|
816
|
+
echo "$UNAME_MACHINE"-cray-unicos"$UNAME_RELEASE" \
|
754
817
|
| sed -e 's/CRAY.*\([A-Z]90\)/\1/' \
|
755
818
|
-e y/ABCDEFGHIJKLMNOPQRSTUVWXYZ/abcdefghijklmnopqrstuvwxyz/ \
|
756
819
|
-e 's/\.[^.]*$/.X/'
|
757
820
|
exit ;;
|
758
821
|
CRAY*TS:*:*:*)
|
759
|
-
echo t90-cray-unicos$
|
822
|
+
echo t90-cray-unicos"$UNAME_RELEASE" | sed -e 's/\.[^.]*$/.X/'
|
760
823
|
exit ;;
|
761
824
|
CRAY*T3E:*:*:*)
|
762
|
-
echo alphaev5-cray-unicosmk$
|
825
|
+
echo alphaev5-cray-unicosmk"$UNAME_RELEASE" | sed -e 's/\.[^.]*$/.X/'
|
763
826
|
exit ;;
|
764
827
|
CRAY*SV1:*:*:*)
|
765
|
-
echo sv1-cray-unicos$
|
828
|
+
echo sv1-cray-unicos"$UNAME_RELEASE" | sed -e 's/\.[^.]*$/.X/'
|
766
829
|
exit ;;
|
767
830
|
*:UNICOS/mp:*:*)
|
768
|
-
echo craynv-cray-unicosmp$
|
831
|
+
echo craynv-cray-unicosmp"$UNAME_RELEASE" | sed -e 's/\.[^.]*$/.X/'
|
769
832
|
exit ;;
|
770
833
|
F30[01]:UNIX_System_V:*:* | F700:UNIX_System_V:*:*)
|
771
|
-
FUJITSU_PROC=`uname -m | tr
|
772
|
-
|
773
|
-
|
774
|
-
|
775
|
-
|
834
|
+
FUJITSU_PROC=`uname -m | tr ABCDEFGHIJKLMNOPQRSTUVWXYZ abcdefghijklmnopqrstuvwxyz`
|
835
|
+
FUJITSU_SYS=`uname -p | tr ABCDEFGHIJKLMNOPQRSTUVWXYZ abcdefghijklmnopqrstuvwxyz | sed -e 's/\///'`
|
836
|
+
FUJITSU_REL=`echo "$UNAME_RELEASE" | sed -e 's/ /_/'`
|
837
|
+
echo "${FUJITSU_PROC}-fujitsu-${FUJITSU_SYS}${FUJITSU_REL}"
|
838
|
+
exit ;;
|
776
839
|
5000:UNIX_System_V:4.*:*)
|
777
|
-
|
778
|
-
|
779
|
-
|
840
|
+
FUJITSU_SYS=`uname -p | tr ABCDEFGHIJKLMNOPQRSTUVWXYZ abcdefghijklmnopqrstuvwxyz | sed -e 's/\///'`
|
841
|
+
FUJITSU_REL=`echo "$UNAME_RELEASE" | tr ABCDEFGHIJKLMNOPQRSTUVWXYZ abcdefghijklmnopqrstuvwxyz | sed -e 's/ /_/'`
|
842
|
+
echo "sparc-fujitsu-${FUJITSU_SYS}${FUJITSU_REL}"
|
780
843
|
exit ;;
|
781
844
|
i*86:BSD/386:*:* | i*86:BSD/OS:*:* | *:Ascend\ Embedded/OS:*:*)
|
782
|
-
echo $
|
845
|
+
echo "$UNAME_MACHINE"-pc-bsdi"$UNAME_RELEASE"
|
783
846
|
exit ;;
|
784
847
|
sparc*:BSD/OS:*:*)
|
785
|
-
echo sparc-unknown-bsdi$
|
848
|
+
echo sparc-unknown-bsdi"$UNAME_RELEASE"
|
786
849
|
exit ;;
|
787
850
|
*:BSD/OS:*:*)
|
788
|
-
echo $
|
851
|
+
echo "$UNAME_MACHINE"-unknown-bsdi"$UNAME_RELEASE"
|
852
|
+
exit ;;
|
853
|
+
arm:FreeBSD:*:*)
|
854
|
+
UNAME_PROCESSOR=`uname -p`
|
855
|
+
set_cc_for_build
|
856
|
+
if echo __ARM_PCS_VFP | $CC_FOR_BUILD -E - 2>/dev/null \
|
857
|
+
| grep -q __ARM_PCS_VFP
|
858
|
+
then
|
859
|
+
echo "${UNAME_PROCESSOR}"-unknown-freebsd"`echo ${UNAME_RELEASE}|sed -e 's/[-(].*//'`"-gnueabi
|
860
|
+
else
|
861
|
+
echo "${UNAME_PROCESSOR}"-unknown-freebsd"`echo ${UNAME_RELEASE}|sed -e 's/[-(].*//'`"-gnueabihf
|
862
|
+
fi
|
789
863
|
exit ;;
|
790
864
|
*:FreeBSD:*:*)
|
791
|
-
|
792
|
-
|
793
|
-
echo i386-unknown-freebsd`echo ${UNAME_RELEASE}|sed -e 's/[-(].*//'` ;;
|
865
|
+
UNAME_PROCESSOR=`/usr/bin/uname -p`
|
866
|
+
case "$UNAME_PROCESSOR" in
|
794
867
|
amd64)
|
795
|
-
|
796
|
-
|
797
|
-
|
868
|
+
UNAME_PROCESSOR=x86_64 ;;
|
869
|
+
i386)
|
870
|
+
UNAME_PROCESSOR=i586 ;;
|
798
871
|
esac
|
872
|
+
echo "$UNAME_PROCESSOR"-unknown-freebsd"`echo "$UNAME_RELEASE"|sed -e 's/[-(].*//'`"
|
799
873
|
exit ;;
|
800
874
|
i*:CYGWIN*:*)
|
801
|
-
echo $
|
875
|
+
echo "$UNAME_MACHINE"-pc-cygwin
|
876
|
+
exit ;;
|
877
|
+
*:MINGW64*:*)
|
878
|
+
echo "$UNAME_MACHINE"-pc-mingw64
|
802
879
|
exit ;;
|
803
880
|
*:MINGW*:*)
|
804
|
-
echo $
|
881
|
+
echo "$UNAME_MACHINE"-pc-mingw32
|
805
882
|
exit ;;
|
806
|
-
|
807
|
-
|
808
|
-
echo ${UNAME_MACHINE}-mingw32
|
883
|
+
*:MSYS*:*)
|
884
|
+
echo "$UNAME_MACHINE"-pc-msys
|
809
885
|
exit ;;
|
810
886
|
i*:PW*:*)
|
811
|
-
echo $
|
887
|
+
echo "$UNAME_MACHINE"-pc-pw32
|
812
888
|
exit ;;
|
813
889
|
*:Interix*:*)
|
814
|
-
|
890
|
+
case "$UNAME_MACHINE" in
|
815
891
|
x86)
|
816
|
-
echo i586-pc-interix$
|
892
|
+
echo i586-pc-interix"$UNAME_RELEASE"
|
817
893
|
exit ;;
|
818
894
|
authenticamd | genuineintel | EM64T)
|
819
|
-
echo x86_64-unknown-interix$
|
895
|
+
echo x86_64-unknown-interix"$UNAME_RELEASE"
|
820
896
|
exit ;;
|
821
897
|
IA64)
|
822
|
-
echo ia64-unknown-interix$
|
898
|
+
echo ia64-unknown-interix"$UNAME_RELEASE"
|
823
899
|
exit ;;
|
824
900
|
esac ;;
|
825
|
-
[345]86:Windows_95:* | [345]86:Windows_98:* | [345]86:Windows_NT:*)
|
826
|
-
echo i${UNAME_MACHINE}-pc-mks
|
827
|
-
exit ;;
|
828
|
-
8664:Windows_NT:*)
|
829
|
-
echo x86_64-pc-mks
|
830
|
-
exit ;;
|
831
|
-
i*:Windows_NT*:* | Pentium*:Windows_NT*:*)
|
832
|
-
# How do we know it's Interix rather than the generic POSIX subsystem?
|
833
|
-
# It also conflicts with pre-2.0 versions of AT&T UWIN. Should we
|
834
|
-
# UNAME_MACHINE based on the output of uname instead of i386?
|
835
|
-
echo i586-pc-interix
|
836
|
-
exit ;;
|
837
901
|
i*:UWIN*:*)
|
838
|
-
echo $
|
902
|
+
echo "$UNAME_MACHINE"-pc-uwin
|
839
903
|
exit ;;
|
840
904
|
amd64:CYGWIN*:*:* | x86_64:CYGWIN*:*:*)
|
841
|
-
echo x86_64-
|
842
|
-
exit ;;
|
843
|
-
p*:CYGWIN*:*)
|
844
|
-
echo powerpcle-unknown-cygwin
|
905
|
+
echo x86_64-pc-cygwin
|
845
906
|
exit ;;
|
846
907
|
prep*:SunOS:5.*:*)
|
847
|
-
echo powerpcle-unknown-solaris2`echo $
|
908
|
+
echo powerpcle-unknown-solaris2"`echo "$UNAME_RELEASE"|sed -e 's/[^.]*//'`"
|
848
909
|
exit ;;
|
849
910
|
*:GNU:*:*)
|
850
911
|
# the GNU system
|
851
|
-
echo `echo $
|
912
|
+
echo "`echo "$UNAME_MACHINE"|sed -e 's,[-/].*$,,'`-unknown-$LIBC`echo "$UNAME_RELEASE"|sed -e 's,/.*$,,'`"
|
852
913
|
exit ;;
|
853
914
|
*:GNU/*:*:*)
|
854
915
|
# other systems with GNU libc and userland
|
855
|
-
echo $
|
916
|
+
echo "$UNAME_MACHINE-unknown-`echo "$UNAME_SYSTEM" | sed 's,^[^/]*/,,' | tr "[:upper:]" "[:lower:]"``echo "$UNAME_RELEASE"|sed -e 's/[-(].*//'`-$LIBC"
|
917
|
+
exit ;;
|
918
|
+
*:Minix:*:*)
|
919
|
+
echo "$UNAME_MACHINE"-unknown-minix
|
856
920
|
exit ;;
|
857
|
-
|
858
|
-
echo $
|
921
|
+
aarch64:Linux:*:*)
|
922
|
+
echo "$UNAME_MACHINE"-unknown-linux-"$LIBC"
|
923
|
+
exit ;;
|
924
|
+
aarch64_be:Linux:*:*)
|
925
|
+
UNAME_MACHINE=aarch64_be
|
926
|
+
echo "$UNAME_MACHINE"-unknown-linux-"$LIBC"
|
859
927
|
exit ;;
|
860
928
|
alpha:Linux:*:*)
|
861
|
-
case `sed -n '/^cpu model/s/^.*: \(.*\)/\1/p'
|
929
|
+
case `sed -n '/^cpu model/s/^.*: \(.*\)/\1/p' /proc/cpuinfo 2>/dev/null` in
|
862
930
|
EV5) UNAME_MACHINE=alphaev5 ;;
|
863
931
|
EV56) UNAME_MACHINE=alphaev56 ;;
|
864
932
|
PCA56) UNAME_MACHINE=alphapca56 ;;
|
@@ -866,115 +934,181 @@ EOF
|
|
866
934
|
EV6) UNAME_MACHINE=alphaev6 ;;
|
867
935
|
EV67) UNAME_MACHINE=alphaev67 ;;
|
868
936
|
EV68*) UNAME_MACHINE=alphaev68 ;;
|
869
|
-
|
937
|
+
esac
|
870
938
|
objdump --private-headers /bin/sh | grep -q ld.so.1
|
871
|
-
if test "$?" = 0 ; then LIBC=
|
872
|
-
echo $
|
939
|
+
if test "$?" = 0 ; then LIBC=gnulibc1 ; fi
|
940
|
+
echo "$UNAME_MACHINE"-unknown-linux-"$LIBC"
|
941
|
+
exit ;;
|
942
|
+
arc:Linux:*:* | arceb:Linux:*:*)
|
943
|
+
echo "$UNAME_MACHINE"-unknown-linux-"$LIBC"
|
873
944
|
exit ;;
|
874
945
|
arm*:Linux:*:*)
|
875
|
-
|
946
|
+
set_cc_for_build
|
876
947
|
if echo __ARM_EABI__ | $CC_FOR_BUILD -E - 2>/dev/null \
|
877
948
|
| grep -q __ARM_EABI__
|
878
949
|
then
|
879
|
-
echo $
|
950
|
+
echo "$UNAME_MACHINE"-unknown-linux-"$LIBC"
|
880
951
|
else
|
881
|
-
echo $
|
952
|
+
if echo __ARM_PCS_VFP | $CC_FOR_BUILD -E - 2>/dev/null \
|
953
|
+
| grep -q __ARM_PCS_VFP
|
954
|
+
then
|
955
|
+
echo "$UNAME_MACHINE"-unknown-linux-"$LIBC"eabi
|
956
|
+
else
|
957
|
+
echo "$UNAME_MACHINE"-unknown-linux-"$LIBC"eabihf
|
958
|
+
fi
|
882
959
|
fi
|
883
960
|
exit ;;
|
884
961
|
avr32*:Linux:*:*)
|
885
|
-
echo $
|
962
|
+
echo "$UNAME_MACHINE"-unknown-linux-"$LIBC"
|
886
963
|
exit ;;
|
887
964
|
cris:Linux:*:*)
|
888
|
-
echo
|
965
|
+
echo "$UNAME_MACHINE"-axis-linux-"$LIBC"
|
889
966
|
exit ;;
|
890
967
|
crisv32:Linux:*:*)
|
891
|
-
echo
|
968
|
+
echo "$UNAME_MACHINE"-axis-linux-"$LIBC"
|
969
|
+
exit ;;
|
970
|
+
e2k:Linux:*:*)
|
971
|
+
echo "$UNAME_MACHINE"-unknown-linux-"$LIBC"
|
892
972
|
exit ;;
|
893
973
|
frv:Linux:*:*)
|
894
|
-
|
974
|
+
echo "$UNAME_MACHINE"-unknown-linux-"$LIBC"
|
975
|
+
exit ;;
|
976
|
+
hexagon:Linux:*:*)
|
977
|
+
echo "$UNAME_MACHINE"-unknown-linux-"$LIBC"
|
895
978
|
exit ;;
|
896
979
|
i*86:Linux:*:*)
|
897
|
-
LIBC
|
898
|
-
eval $set_cc_for_build
|
899
|
-
sed 's/^ //' << EOF >$dummy.c
|
900
|
-
#ifdef __dietlibc__
|
901
|
-
LIBC=dietlibc
|
902
|
-
#endif
|
903
|
-
EOF
|
904
|
-
eval `$CC_FOR_BUILD -E $dummy.c 2>/dev/null | grep '^LIBC'`
|
905
|
-
echo "${UNAME_MACHINE}-pc-linux-${LIBC}"
|
980
|
+
echo "$UNAME_MACHINE"-pc-linux-"$LIBC"
|
906
981
|
exit ;;
|
907
982
|
ia64:Linux:*:*)
|
908
|
-
echo $
|
983
|
+
echo "$UNAME_MACHINE"-unknown-linux-"$LIBC"
|
984
|
+
exit ;;
|
985
|
+
k1om:Linux:*:*)
|
986
|
+
echo "$UNAME_MACHINE"-unknown-linux-"$LIBC"
|
909
987
|
exit ;;
|
910
988
|
m32r*:Linux:*:*)
|
911
|
-
echo $
|
989
|
+
echo "$UNAME_MACHINE"-unknown-linux-"$LIBC"
|
912
990
|
exit ;;
|
913
991
|
m68*:Linux:*:*)
|
914
|
-
echo $
|
992
|
+
echo "$UNAME_MACHINE"-unknown-linux-"$LIBC"
|
915
993
|
exit ;;
|
916
994
|
mips:Linux:*:* | mips64:Linux:*:*)
|
917
|
-
|
918
|
-
|
995
|
+
set_cc_for_build
|
996
|
+
IS_GLIBC=0
|
997
|
+
test x"${LIBC}" = xgnu && IS_GLIBC=1
|
998
|
+
sed 's/^ //' << EOF > "$dummy.c"
|
919
999
|
#undef CPU
|
920
|
-
#undef
|
921
|
-
#undef
|
1000
|
+
#undef mips
|
1001
|
+
#undef mipsel
|
1002
|
+
#undef mips64
|
1003
|
+
#undef mips64el
|
1004
|
+
#if ${IS_GLIBC} && defined(_ABI64)
|
1005
|
+
LIBCABI=gnuabi64
|
1006
|
+
#else
|
1007
|
+
#if ${IS_GLIBC} && defined(_ABIN32)
|
1008
|
+
LIBCABI=gnuabin32
|
1009
|
+
#else
|
1010
|
+
LIBCABI=${LIBC}
|
1011
|
+
#endif
|
1012
|
+
#endif
|
1013
|
+
|
1014
|
+
#if ${IS_GLIBC} && defined(__mips64) && defined(__mips_isa_rev) && __mips_isa_rev>=6
|
1015
|
+
CPU=mipsisa64r6
|
1016
|
+
#else
|
1017
|
+
#if ${IS_GLIBC} && !defined(__mips64) && defined(__mips_isa_rev) && __mips_isa_rev>=6
|
1018
|
+
CPU=mipsisa32r6
|
1019
|
+
#else
|
1020
|
+
#if defined(__mips64)
|
1021
|
+
CPU=mips64
|
1022
|
+
#else
|
1023
|
+
CPU=mips
|
1024
|
+
#endif
|
1025
|
+
#endif
|
1026
|
+
#endif
|
1027
|
+
|
922
1028
|
#if defined(__MIPSEL__) || defined(__MIPSEL) || defined(_MIPSEL) || defined(MIPSEL)
|
923
|
-
|
1029
|
+
MIPS_ENDIAN=el
|
924
1030
|
#else
|
925
1031
|
#if defined(__MIPSEB__) || defined(__MIPSEB) || defined(_MIPSEB) || defined(MIPSEB)
|
926
|
-
|
1032
|
+
MIPS_ENDIAN=
|
927
1033
|
#else
|
928
|
-
|
1034
|
+
MIPS_ENDIAN=
|
929
1035
|
#endif
|
930
1036
|
#endif
|
931
1037
|
EOF
|
932
|
-
eval `$CC_FOR_BUILD -E $dummy.c 2>/dev/null | grep '^CPU'`
|
933
|
-
test x
|
1038
|
+
eval "`$CC_FOR_BUILD -E "$dummy.c" 2>/dev/null | grep '^CPU\|^MIPS_ENDIAN\|^LIBCABI'`"
|
1039
|
+
test "x$CPU" != x && { echo "$CPU${MIPS_ENDIAN}-unknown-linux-$LIBCABI"; exit; }
|
934
1040
|
;;
|
935
|
-
|
936
|
-
echo
|
1041
|
+
mips64el:Linux:*:*)
|
1042
|
+
echo "$UNAME_MACHINE"-unknown-linux-"$LIBC"
|
1043
|
+
exit ;;
|
1044
|
+
openrisc*:Linux:*:*)
|
1045
|
+
echo or1k-unknown-linux-"$LIBC"
|
1046
|
+
exit ;;
|
1047
|
+
or32:Linux:*:* | or1k*:Linux:*:*)
|
1048
|
+
echo "$UNAME_MACHINE"-unknown-linux-"$LIBC"
|
937
1049
|
exit ;;
|
938
1050
|
padre:Linux:*:*)
|
939
|
-
echo sparc-unknown-linux-
|
1051
|
+
echo sparc-unknown-linux-"$LIBC"
|
940
1052
|
exit ;;
|
941
1053
|
parisc64:Linux:*:* | hppa64:Linux:*:*)
|
942
|
-
echo hppa64-unknown-linux-
|
1054
|
+
echo hppa64-unknown-linux-"$LIBC"
|
943
1055
|
exit ;;
|
944
1056
|
parisc:Linux:*:* | hppa:Linux:*:*)
|
945
1057
|
# Look for CPU level
|
946
1058
|
case `grep '^cpu[^a-z]*:' /proc/cpuinfo 2>/dev/null | cut -d' ' -f2` in
|
947
|
-
PA7*) echo hppa1.1-unknown-linux-
|
948
|
-
PA8*) echo hppa2.0-unknown-linux-
|
949
|
-
*) echo hppa-unknown-linux-
|
1059
|
+
PA7*) echo hppa1.1-unknown-linux-"$LIBC" ;;
|
1060
|
+
PA8*) echo hppa2.0-unknown-linux-"$LIBC" ;;
|
1061
|
+
*) echo hppa-unknown-linux-"$LIBC" ;;
|
950
1062
|
esac
|
951
1063
|
exit ;;
|
952
1064
|
ppc64:Linux:*:*)
|
953
|
-
echo powerpc64-unknown-linux-
|
1065
|
+
echo powerpc64-unknown-linux-"$LIBC"
|
954
1066
|
exit ;;
|
955
1067
|
ppc:Linux:*:*)
|
956
|
-
echo powerpc-unknown-linux-
|
1068
|
+
echo powerpc-unknown-linux-"$LIBC"
|
1069
|
+
exit ;;
|
1070
|
+
ppc64le:Linux:*:*)
|
1071
|
+
echo powerpc64le-unknown-linux-"$LIBC"
|
1072
|
+
exit ;;
|
1073
|
+
ppcle:Linux:*:*)
|
1074
|
+
echo powerpcle-unknown-linux-"$LIBC"
|
1075
|
+
exit ;;
|
1076
|
+
riscv32:Linux:*:* | riscv64:Linux:*:*)
|
1077
|
+
echo "$UNAME_MACHINE"-unknown-linux-"$LIBC"
|
957
1078
|
exit ;;
|
958
1079
|
s390:Linux:*:* | s390x:Linux:*:*)
|
959
|
-
echo $
|
1080
|
+
echo "$UNAME_MACHINE"-ibm-linux-"$LIBC"
|
960
1081
|
exit ;;
|
961
1082
|
sh64*:Linux:*:*)
|
962
|
-
|
1083
|
+
echo "$UNAME_MACHINE"-unknown-linux-"$LIBC"
|
963
1084
|
exit ;;
|
964
1085
|
sh*:Linux:*:*)
|
965
|
-
echo $
|
1086
|
+
echo "$UNAME_MACHINE"-unknown-linux-"$LIBC"
|
966
1087
|
exit ;;
|
967
1088
|
sparc:Linux:*:* | sparc64:Linux:*:*)
|
968
|
-
echo $
|
1089
|
+
echo "$UNAME_MACHINE"-unknown-linux-"$LIBC"
|
1090
|
+
exit ;;
|
1091
|
+
tile*:Linux:*:*)
|
1092
|
+
echo "$UNAME_MACHINE"-unknown-linux-"$LIBC"
|
969
1093
|
exit ;;
|
970
1094
|
vax:Linux:*:*)
|
971
|
-
echo $
|
1095
|
+
echo "$UNAME_MACHINE"-dec-linux-"$LIBC"
|
972
1096
|
exit ;;
|
973
1097
|
x86_64:Linux:*:*)
|
974
|
-
|
1098
|
+
set_cc_for_build
|
1099
|
+
LIBCABI=$LIBC
|
1100
|
+
if [ "$CC_FOR_BUILD" != no_compiler_found ]; then
|
1101
|
+
if (echo '#ifdef __ILP32__'; echo IS_X32; echo '#endif') | \
|
1102
|
+
(CCOPTS="" $CC_FOR_BUILD -E - 2>/dev/null) | \
|
1103
|
+
grep IS_X32 >/dev/null
|
1104
|
+
then
|
1105
|
+
LIBCABI="$LIBC"x32
|
1106
|
+
fi
|
1107
|
+
fi
|
1108
|
+
echo "$UNAME_MACHINE"-pc-linux-"$LIBCABI"
|
975
1109
|
exit ;;
|
976
1110
|
xtensa*:Linux:*:*)
|
977
|
-
|
1111
|
+
echo "$UNAME_MACHINE"-unknown-linux-"$LIBC"
|
978
1112
|
exit ;;
|
979
1113
|
i*86:DYNIX/ptx:4*:*)
|
980
1114
|
# ptx 4.0 does uname -s correctly, with DYNIX/ptx in there.
|
@@ -983,54 +1117,54 @@ EOF
|
|
983
1117
|
echo i386-sequent-sysv4
|
984
1118
|
exit ;;
|
985
1119
|
i*86:UNIX_SV:4.2MP:2.*)
|
986
|
-
|
987
|
-
|
988
|
-
|
1120
|
+
# Unixware is an offshoot of SVR4, but it has its own version
|
1121
|
+
# number series starting with 2...
|
1122
|
+
# I am not positive that other SVR4 systems won't match this,
|
989
1123
|
# I just have to hope. -- rms.
|
990
|
-
|
991
|
-
echo $
|
1124
|
+
# Use sysv4.2uw... so that sysv4* matches it.
|
1125
|
+
echo "$UNAME_MACHINE"-pc-sysv4.2uw"$UNAME_VERSION"
|
992
1126
|
exit ;;
|
993
1127
|
i*86:OS/2:*:*)
|
994
1128
|
# If we were able to find `uname', then EMX Unix compatibility
|
995
1129
|
# is probably installed.
|
996
|
-
echo $
|
1130
|
+
echo "$UNAME_MACHINE"-pc-os2-emx
|
997
1131
|
exit ;;
|
998
1132
|
i*86:XTS-300:*:STOP)
|
999
|
-
echo $
|
1133
|
+
echo "$UNAME_MACHINE"-unknown-stop
|
1000
1134
|
exit ;;
|
1001
1135
|
i*86:atheos:*:*)
|
1002
|
-
echo $
|
1136
|
+
echo "$UNAME_MACHINE"-unknown-atheos
|
1003
1137
|
exit ;;
|
1004
1138
|
i*86:syllable:*:*)
|
1005
|
-
echo $
|
1139
|
+
echo "$UNAME_MACHINE"-pc-syllable
|
1006
1140
|
exit ;;
|
1007
1141
|
i*86:LynxOS:2.*:* | i*86:LynxOS:3.[01]*:* | i*86:LynxOS:4.[02]*:*)
|
1008
|
-
echo i386-unknown-lynxos$
|
1142
|
+
echo i386-unknown-lynxos"$UNAME_RELEASE"
|
1009
1143
|
exit ;;
|
1010
1144
|
i*86:*DOS:*:*)
|
1011
|
-
echo $
|
1145
|
+
echo "$UNAME_MACHINE"-pc-msdosdjgpp
|
1012
1146
|
exit ;;
|
1013
|
-
i*86:*:4.*:*
|
1014
|
-
UNAME_REL=`echo $
|
1147
|
+
i*86:*:4.*:*)
|
1148
|
+
UNAME_REL=`echo "$UNAME_RELEASE" | sed 's/\/MP$//'`
|
1015
1149
|
if grep Novell /usr/include/link.h >/dev/null 2>/dev/null; then
|
1016
|
-
echo $
|
1150
|
+
echo "$UNAME_MACHINE"-univel-sysv"$UNAME_REL"
|
1017
1151
|
else
|
1018
|
-
echo $
|
1152
|
+
echo "$UNAME_MACHINE"-pc-sysv"$UNAME_REL"
|
1019
1153
|
fi
|
1020
1154
|
exit ;;
|
1021
1155
|
i*86:*:5:[678]*)
|
1022
|
-
|
1156
|
+
# UnixWare 7.x, OpenUNIX and OpenServer 6.
|
1023
1157
|
case `/bin/uname -X | grep "^Machine"` in
|
1024
1158
|
*486*) UNAME_MACHINE=i486 ;;
|
1025
1159
|
*Pentium) UNAME_MACHINE=i586 ;;
|
1026
1160
|
*Pent*|*Celeron) UNAME_MACHINE=i686 ;;
|
1027
1161
|
esac
|
1028
|
-
echo $
|
1162
|
+
echo "$UNAME_MACHINE-unknown-sysv${UNAME_RELEASE}${UNAME_SYSTEM}${UNAME_VERSION}"
|
1029
1163
|
exit ;;
|
1030
1164
|
i*86:*:3.2:*)
|
1031
1165
|
if test -f /usr/options/cb.name; then
|
1032
1166
|
UNAME_REL=`sed -n 's/.*Version //p' </usr/options/cb.name`
|
1033
|
-
echo $
|
1167
|
+
echo "$UNAME_MACHINE"-pc-isc"$UNAME_REL"
|
1034
1168
|
elif /bin/uname -X 2>/dev/null >/dev/null ; then
|
1035
1169
|
UNAME_REL=`(/bin/uname -X|grep Release|sed -e 's/.*= //')`
|
1036
1170
|
(/bin/uname -X|grep i80486 >/dev/null) && UNAME_MACHINE=i486
|
@@ -1040,20 +1174,20 @@ EOF
|
|
1040
1174
|
&& UNAME_MACHINE=i686
|
1041
1175
|
(/bin/uname -X|grep '^Machine.*Pentium Pro' >/dev/null) \
|
1042
1176
|
&& UNAME_MACHINE=i686
|
1043
|
-
echo $
|
1177
|
+
echo "$UNAME_MACHINE"-pc-sco"$UNAME_REL"
|
1044
1178
|
else
|
1045
|
-
echo $
|
1179
|
+
echo "$UNAME_MACHINE"-pc-sysv32
|
1046
1180
|
fi
|
1047
1181
|
exit ;;
|
1048
1182
|
pc:*:*:*)
|
1049
1183
|
# Left here for compatibility:
|
1050
|
-
|
1051
|
-
|
1184
|
+
# uname -m prints for DJGPP always 'pc', but it prints nothing about
|
1185
|
+
# the processor, so we play safe by assuming i586.
|
1052
1186
|
# Note: whatever this is, it MUST be the same as what config.sub
|
1053
|
-
# prints for the "djgpp" host, or else GDB
|
1187
|
+
# prints for the "djgpp" host, or else GDB configure will decide that
|
1054
1188
|
# this is a cross-build.
|
1055
1189
|
echo i586-pc-msdosdjgpp
|
1056
|
-
|
1190
|
+
exit ;;
|
1057
1191
|
Intel:Mach:3*:*)
|
1058
1192
|
echo i386-pc-mach3
|
1059
1193
|
exit ;;
|
@@ -1062,9 +1196,9 @@ EOF
|
|
1062
1196
|
exit ;;
|
1063
1197
|
i860:*:4.*:*) # i860-SVR4
|
1064
1198
|
if grep Stardent /usr/include/sys/uadmin.h >/dev/null 2>&1 ; then
|
1065
|
-
echo i860-stardent-sysv$
|
1199
|
+
echo i860-stardent-sysv"$UNAME_RELEASE" # Stardent Vistra i860-SVR4
|
1066
1200
|
else # Add other i860-SVR4 vendors below as they are discovered.
|
1067
|
-
echo i860-unknown-sysv$
|
1201
|
+
echo i860-unknown-sysv"$UNAME_RELEASE" # Unknown i860-SVR4
|
1068
1202
|
fi
|
1069
1203
|
exit ;;
|
1070
1204
|
mini*:CTIX:SYS*5:*)
|
@@ -1084,39 +1218,39 @@ EOF
|
|
1084
1218
|
test -r /etc/.relid \
|
1085
1219
|
&& OS_REL=.`sed -n 's/[^ ]* [^ ]* \([0-9][0-9]\).*/\1/p' < /etc/.relid`
|
1086
1220
|
/bin/uname -p 2>/dev/null | grep 86 >/dev/null \
|
1087
|
-
&& { echo i486-ncr-sysv4.3$
|
1221
|
+
&& { echo i486-ncr-sysv4.3"$OS_REL"; exit; }
|
1088
1222
|
/bin/uname -p 2>/dev/null | /bin/grep entium >/dev/null \
|
1089
|
-
&& { echo i586-ncr-sysv4.3$
|
1223
|
+
&& { echo i586-ncr-sysv4.3"$OS_REL"; exit; } ;;
|
1090
1224
|
3[34]??:*:4.0:* | 3[34]??,*:*:4.0:*)
|
1091
|
-
|
1092
|
-
|
1225
|
+
/bin/uname -p 2>/dev/null | grep 86 >/dev/null \
|
1226
|
+
&& { echo i486-ncr-sysv4; exit; } ;;
|
1093
1227
|
NCR*:*:4.2:* | MPRAS*:*:4.2:*)
|
1094
1228
|
OS_REL='.3'
|
1095
1229
|
test -r /etc/.relid \
|
1096
1230
|
&& OS_REL=.`sed -n 's/[^ ]* [^ ]* \([0-9][0-9]\).*/\1/p' < /etc/.relid`
|
1097
1231
|
/bin/uname -p 2>/dev/null | grep 86 >/dev/null \
|
1098
|
-
&& { echo i486-ncr-sysv4.3$
|
1232
|
+
&& { echo i486-ncr-sysv4.3"$OS_REL"; exit; }
|
1099
1233
|
/bin/uname -p 2>/dev/null | /bin/grep entium >/dev/null \
|
1100
|
-
&& { echo i586-ncr-sysv4.3$
|
1234
|
+
&& { echo i586-ncr-sysv4.3"$OS_REL"; exit; }
|
1101
1235
|
/bin/uname -p 2>/dev/null | /bin/grep pteron >/dev/null \
|
1102
|
-
&& { echo i586-ncr-sysv4.3$
|
1236
|
+
&& { echo i586-ncr-sysv4.3"$OS_REL"; exit; } ;;
|
1103
1237
|
m68*:LynxOS:2.*:* | m68*:LynxOS:3.0*:*)
|
1104
|
-
echo m68k-unknown-lynxos$
|
1238
|
+
echo m68k-unknown-lynxos"$UNAME_RELEASE"
|
1105
1239
|
exit ;;
|
1106
1240
|
mc68030:UNIX_System_V:4.*:*)
|
1107
1241
|
echo m68k-atari-sysv4
|
1108
1242
|
exit ;;
|
1109
1243
|
TSUNAMI:LynxOS:2.*:*)
|
1110
|
-
echo sparc-unknown-lynxos$
|
1244
|
+
echo sparc-unknown-lynxos"$UNAME_RELEASE"
|
1111
1245
|
exit ;;
|
1112
1246
|
rs6000:LynxOS:2.*:*)
|
1113
|
-
echo rs6000-unknown-lynxos$
|
1247
|
+
echo rs6000-unknown-lynxos"$UNAME_RELEASE"
|
1114
1248
|
exit ;;
|
1115
1249
|
PowerPC:LynxOS:2.*:* | PowerPC:LynxOS:3.[01]*:* | PowerPC:LynxOS:4.[02]*:*)
|
1116
|
-
echo powerpc-unknown-lynxos$
|
1250
|
+
echo powerpc-unknown-lynxos"$UNAME_RELEASE"
|
1117
1251
|
exit ;;
|
1118
1252
|
SM[BE]S:UNIX_SV:*:*)
|
1119
|
-
echo mips-dde-sysv$
|
1253
|
+
echo mips-dde-sysv"$UNAME_RELEASE"
|
1120
1254
|
exit ;;
|
1121
1255
|
RM*:ReliantUNIX-*:*:*)
|
1122
1256
|
echo mips-sni-sysv4
|
@@ -1127,15 +1261,15 @@ EOF
|
|
1127
1261
|
*:SINIX-*:*:*)
|
1128
1262
|
if uname -p 2>/dev/null >/dev/null ; then
|
1129
1263
|
UNAME_MACHINE=`(uname -p) 2>/dev/null`
|
1130
|
-
echo $
|
1264
|
+
echo "$UNAME_MACHINE"-sni-sysv4
|
1131
1265
|
else
|
1132
1266
|
echo ns32k-sni-sysv
|
1133
1267
|
fi
|
1134
1268
|
exit ;;
|
1135
|
-
PENTIUM:*:4.0*:*)
|
1136
|
-
|
1137
|
-
|
1138
|
-
|
1269
|
+
PENTIUM:*:4.0*:*) # Unisys `ClearPath HMP IX 4000' SVR4/MP effort
|
1270
|
+
# says <Richard.M.Bartel@ccMail.Census.GOV>
|
1271
|
+
echo i586-unisys-sysv4
|
1272
|
+
exit ;;
|
1139
1273
|
*:UNIX_System_V:4*:FTX*)
|
1140
1274
|
# From Gerald Hewes <hewes@openmarket.com>.
|
1141
1275
|
# How about differentiating between stratus architectures? -djm
|
@@ -1147,25 +1281,25 @@ EOF
|
|
1147
1281
|
exit ;;
|
1148
1282
|
i*86:VOS:*:*)
|
1149
1283
|
# From Paul.Green@stratus.com.
|
1150
|
-
echo $
|
1284
|
+
echo "$UNAME_MACHINE"-stratus-vos
|
1151
1285
|
exit ;;
|
1152
1286
|
*:VOS:*:*)
|
1153
1287
|
# From Paul.Green@stratus.com.
|
1154
1288
|
echo hppa1.1-stratus-vos
|
1155
1289
|
exit ;;
|
1156
1290
|
mc68*:A/UX:*:*)
|
1157
|
-
echo m68k-apple-aux$
|
1291
|
+
echo m68k-apple-aux"$UNAME_RELEASE"
|
1158
1292
|
exit ;;
|
1159
1293
|
news*:NEWS-OS:6*:*)
|
1160
1294
|
echo mips-sony-newsos6
|
1161
1295
|
exit ;;
|
1162
1296
|
R[34]000:*System_V*:*:* | R4000:UNIX_SYSV:*:* | R*000:UNIX_SV:*:*)
|
1163
1297
|
if [ -d /usr/nec ]; then
|
1164
|
-
|
1298
|
+
echo mips-nec-sysv"$UNAME_RELEASE"
|
1165
1299
|
else
|
1166
|
-
|
1300
|
+
echo mips-unknown-sysv"$UNAME_RELEASE"
|
1167
1301
|
fi
|
1168
|
-
|
1302
|
+
exit ;;
|
1169
1303
|
BeBox:BeOS:*:*) # BeOS running on hardware made by Be, PPC only.
|
1170
1304
|
echo powerpc-be-beos
|
1171
1305
|
exit ;;
|
@@ -1178,63 +1312,101 @@ EOF
|
|
1178
1312
|
BePC:Haiku:*:*) # Haiku running on Intel PC compatible.
|
1179
1313
|
echo i586-pc-haiku
|
1180
1314
|
exit ;;
|
1315
|
+
x86_64:Haiku:*:*)
|
1316
|
+
echo x86_64-unknown-haiku
|
1317
|
+
exit ;;
|
1181
1318
|
SX-4:SUPER-UX:*:*)
|
1182
|
-
echo sx4-nec-superux$
|
1319
|
+
echo sx4-nec-superux"$UNAME_RELEASE"
|
1183
1320
|
exit ;;
|
1184
1321
|
SX-5:SUPER-UX:*:*)
|
1185
|
-
echo sx5-nec-superux$
|
1322
|
+
echo sx5-nec-superux"$UNAME_RELEASE"
|
1186
1323
|
exit ;;
|
1187
1324
|
SX-6:SUPER-UX:*:*)
|
1188
|
-
echo sx6-nec-superux$
|
1325
|
+
echo sx6-nec-superux"$UNAME_RELEASE"
|
1189
1326
|
exit ;;
|
1190
1327
|
SX-7:SUPER-UX:*:*)
|
1191
|
-
echo sx7-nec-superux$
|
1328
|
+
echo sx7-nec-superux"$UNAME_RELEASE"
|
1192
1329
|
exit ;;
|
1193
1330
|
SX-8:SUPER-UX:*:*)
|
1194
|
-
echo sx8-nec-superux$
|
1331
|
+
echo sx8-nec-superux"$UNAME_RELEASE"
|
1195
1332
|
exit ;;
|
1196
1333
|
SX-8R:SUPER-UX:*:*)
|
1197
|
-
echo sx8r-nec-superux$
|
1334
|
+
echo sx8r-nec-superux"$UNAME_RELEASE"
|
1335
|
+
exit ;;
|
1336
|
+
SX-ACE:SUPER-UX:*:*)
|
1337
|
+
echo sxace-nec-superux"$UNAME_RELEASE"
|
1198
1338
|
exit ;;
|
1199
1339
|
Power*:Rhapsody:*:*)
|
1200
|
-
echo powerpc-apple-rhapsody$
|
1340
|
+
echo powerpc-apple-rhapsody"$UNAME_RELEASE"
|
1201
1341
|
exit ;;
|
1202
1342
|
*:Rhapsody:*:*)
|
1203
|
-
echo $
|
1343
|
+
echo "$UNAME_MACHINE"-apple-rhapsody"$UNAME_RELEASE"
|
1344
|
+
exit ;;
|
1345
|
+
arm64:Darwin:*:*)
|
1346
|
+
echo aarch64-apple-darwin"$UNAME_RELEASE"
|
1204
1347
|
exit ;;
|
1205
1348
|
*:Darwin:*:*)
|
1206
|
-
UNAME_PROCESSOR=`uname -p`
|
1349
|
+
UNAME_PROCESSOR=`uname -p`
|
1207
1350
|
case $UNAME_PROCESSOR in
|
1208
|
-
i386)
|
1209
|
-
eval $set_cc_for_build
|
1210
|
-
if [ "$CC_FOR_BUILD" != 'no_compiler_found' ]; then
|
1211
|
-
if (echo '#ifdef __LP64__'; echo IS_64BIT_ARCH; echo '#endif') | \
|
1212
|
-
(CCOPTS= $CC_FOR_BUILD -E - 2>/dev/null) | \
|
1213
|
-
grep IS_64BIT_ARCH >/dev/null
|
1214
|
-
then
|
1215
|
-
UNAME_PROCESSOR="x86_64"
|
1216
|
-
fi
|
1217
|
-
fi ;;
|
1218
1351
|
unknown) UNAME_PROCESSOR=powerpc ;;
|
1219
1352
|
esac
|
1220
|
-
|
1353
|
+
if command -v xcode-select > /dev/null 2> /dev/null && \
|
1354
|
+
! xcode-select --print-path > /dev/null 2> /dev/null ; then
|
1355
|
+
# Avoid executing cc if there is no toolchain installed as
|
1356
|
+
# cc will be a stub that puts up a graphical alert
|
1357
|
+
# prompting the user to install developer tools.
|
1358
|
+
CC_FOR_BUILD=no_compiler_found
|
1359
|
+
else
|
1360
|
+
set_cc_for_build
|
1361
|
+
fi
|
1362
|
+
if [ "$CC_FOR_BUILD" != no_compiler_found ]; then
|
1363
|
+
if (echo '#ifdef __LP64__'; echo IS_64BIT_ARCH; echo '#endif') | \
|
1364
|
+
(CCOPTS="" $CC_FOR_BUILD -E - 2>/dev/null) | \
|
1365
|
+
grep IS_64BIT_ARCH >/dev/null
|
1366
|
+
then
|
1367
|
+
case $UNAME_PROCESSOR in
|
1368
|
+
i386) UNAME_PROCESSOR=x86_64 ;;
|
1369
|
+
powerpc) UNAME_PROCESSOR=powerpc64 ;;
|
1370
|
+
esac
|
1371
|
+
fi
|
1372
|
+
# On 10.4-10.6 one might compile for PowerPC via gcc -arch ppc
|
1373
|
+
if (echo '#ifdef __POWERPC__'; echo IS_PPC; echo '#endif') | \
|
1374
|
+
(CCOPTS="" $CC_FOR_BUILD -E - 2>/dev/null) | \
|
1375
|
+
grep IS_PPC >/dev/null
|
1376
|
+
then
|
1377
|
+
UNAME_PROCESSOR=powerpc
|
1378
|
+
fi
|
1379
|
+
elif test "$UNAME_PROCESSOR" = i386 ; then
|
1380
|
+
# uname -m returns i386 or x86_64
|
1381
|
+
UNAME_PROCESSOR=$UNAME_MACHINE
|
1382
|
+
fi
|
1383
|
+
echo "$UNAME_PROCESSOR"-apple-darwin"$UNAME_RELEASE"
|
1221
1384
|
exit ;;
|
1222
1385
|
*:procnto*:*:* | *:QNX:[0123456789]*:*)
|
1223
1386
|
UNAME_PROCESSOR=`uname -p`
|
1224
|
-
if test "$UNAME_PROCESSOR" =
|
1387
|
+
if test "$UNAME_PROCESSOR" = x86; then
|
1225
1388
|
UNAME_PROCESSOR=i386
|
1226
1389
|
UNAME_MACHINE=pc
|
1227
1390
|
fi
|
1228
|
-
echo $
|
1391
|
+
echo "$UNAME_PROCESSOR"-"$UNAME_MACHINE"-nto-qnx"$UNAME_RELEASE"
|
1229
1392
|
exit ;;
|
1230
1393
|
*:QNX:*:4*)
|
1231
1394
|
echo i386-pc-qnx
|
1232
1395
|
exit ;;
|
1233
|
-
|
1234
|
-
echo
|
1396
|
+
NEO-*:NONSTOP_KERNEL:*:*)
|
1397
|
+
echo neo-tandem-nsk"$UNAME_RELEASE"
|
1235
1398
|
exit ;;
|
1236
|
-
|
1237
|
-
echo
|
1399
|
+
NSE-*:NONSTOP_KERNEL:*:*)
|
1400
|
+
echo nse-tandem-nsk"$UNAME_RELEASE"
|
1401
|
+
exit ;;
|
1402
|
+
NSR-*:NONSTOP_KERNEL:*:*)
|
1403
|
+
echo nsr-tandem-nsk"$UNAME_RELEASE"
|
1404
|
+
exit ;;
|
1405
|
+
NSV-*:NONSTOP_KERNEL:*:*)
|
1406
|
+
echo nsv-tandem-nsk"$UNAME_RELEASE"
|
1407
|
+
exit ;;
|
1408
|
+
NSX-*:NONSTOP_KERNEL:*:*)
|
1409
|
+
echo nsx-tandem-nsk"$UNAME_RELEASE"
|
1238
1410
|
exit ;;
|
1239
1411
|
*:NonStop-UX:*:*)
|
1240
1412
|
echo mips-compaq-nonstopux
|
@@ -1243,18 +1415,19 @@ EOF
|
|
1243
1415
|
echo bs2000-siemens-sysv
|
1244
1416
|
exit ;;
|
1245
1417
|
DS/*:UNIX_System_V:*:*)
|
1246
|
-
echo $
|
1418
|
+
echo "$UNAME_MACHINE"-"$UNAME_SYSTEM"-"$UNAME_RELEASE"
|
1247
1419
|
exit ;;
|
1248
1420
|
*:Plan9:*:*)
|
1249
1421
|
# "uname -m" is not consistent, so use $cputype instead. 386
|
1250
1422
|
# is converted to i386 for consistency with other x86
|
1251
1423
|
# operating systems.
|
1252
|
-
|
1424
|
+
# shellcheck disable=SC2154
|
1425
|
+
if test "$cputype" = 386; then
|
1253
1426
|
UNAME_MACHINE=i386
|
1254
1427
|
else
|
1255
1428
|
UNAME_MACHINE="$cputype"
|
1256
1429
|
fi
|
1257
|
-
echo $
|
1430
|
+
echo "$UNAME_MACHINE"-unknown-plan9
|
1258
1431
|
exit ;;
|
1259
1432
|
*:TOPS-10:*:*)
|
1260
1433
|
echo pdp10-unknown-tops10
|
@@ -1275,14 +1448,14 @@ EOF
|
|
1275
1448
|
echo pdp10-unknown-its
|
1276
1449
|
exit ;;
|
1277
1450
|
SEI:*:*:SEIUX)
|
1278
|
-
|
1451
|
+
echo mips-sei-seiux"$UNAME_RELEASE"
|
1279
1452
|
exit ;;
|
1280
1453
|
*:DragonFly:*:*)
|
1281
|
-
echo $
|
1454
|
+
echo "$UNAME_MACHINE"-unknown-dragonfly"`echo "$UNAME_RELEASE"|sed -e 's/[-(].*//'`"
|
1282
1455
|
exit ;;
|
1283
1456
|
*:*VMS:*:*)
|
1284
|
-
|
1285
|
-
case "$
|
1457
|
+
UNAME_MACHINE=`(uname -p) 2>/dev/null`
|
1458
|
+
case "$UNAME_MACHINE" in
|
1286
1459
|
A*) echo alpha-dec-vms ; exit ;;
|
1287
1460
|
I*) echo ia64-dec-vms ; exit ;;
|
1288
1461
|
V*) echo vax-dec-vms ; exit ;;
|
@@ -1291,24 +1464,39 @@ EOF
|
|
1291
1464
|
echo i386-pc-xenix
|
1292
1465
|
exit ;;
|
1293
1466
|
i*86:skyos:*:*)
|
1294
|
-
echo $
|
1467
|
+
echo "$UNAME_MACHINE"-pc-skyos"`echo "$UNAME_RELEASE" | sed -e 's/ .*$//'`"
|
1295
1468
|
exit ;;
|
1296
1469
|
i*86:rdos:*:*)
|
1297
|
-
echo $
|
1470
|
+
echo "$UNAME_MACHINE"-pc-rdos
|
1298
1471
|
exit ;;
|
1299
1472
|
i*86:AROS:*:*)
|
1300
|
-
echo $
|
1473
|
+
echo "$UNAME_MACHINE"-pc-aros
|
1474
|
+
exit ;;
|
1475
|
+
x86_64:VMkernel:*:*)
|
1476
|
+
echo "$UNAME_MACHINE"-unknown-esx
|
1477
|
+
exit ;;
|
1478
|
+
amd64:Isilon\ OneFS:*:*)
|
1479
|
+
echo x86_64-unknown-onefs
|
1480
|
+
exit ;;
|
1481
|
+
*:Unleashed:*:*)
|
1482
|
+
echo "$UNAME_MACHINE"-unknown-unleashed"$UNAME_RELEASE"
|
1301
1483
|
exit ;;
|
1302
1484
|
esac
|
1303
1485
|
|
1304
|
-
#
|
1305
|
-
|
1306
|
-
|
1307
|
-
eval $set_cc_for_build
|
1308
|
-
cat >$dummy.c <<EOF
|
1486
|
+
# No uname command or uname output not recognized.
|
1487
|
+
set_cc_for_build
|
1488
|
+
cat > "$dummy.c" <<EOF
|
1309
1489
|
#ifdef _SEQUENT_
|
1310
|
-
#
|
1311
|
-
#
|
1490
|
+
#include <sys/types.h>
|
1491
|
+
#include <sys/utsname.h>
|
1492
|
+
#endif
|
1493
|
+
#if defined(ultrix) || defined(_ultrix) || defined(__ultrix) || defined(__ultrix__)
|
1494
|
+
#if defined (vax) || defined (__vax) || defined (__vax__) || defined(mips) || defined(__mips) || defined(__mips__) || defined(MIPS) || defined(__MIPS__)
|
1495
|
+
#include <signal.h>
|
1496
|
+
#if defined(_SIZE_T_) || defined(SIGLOST)
|
1497
|
+
#include <sys/utsname.h>
|
1498
|
+
#endif
|
1499
|
+
#endif
|
1312
1500
|
#endif
|
1313
1501
|
main ()
|
1314
1502
|
{
|
@@ -1321,22 +1509,14 @@ main ()
|
|
1321
1509
|
#include <sys/param.h>
|
1322
1510
|
printf ("m68k-sony-newsos%s\n",
|
1323
1511
|
#ifdef NEWSOS4
|
1324
|
-
|
1512
|
+
"4"
|
1325
1513
|
#else
|
1326
|
-
|
1514
|
+
""
|
1327
1515
|
#endif
|
1328
|
-
|
1516
|
+
); exit (0);
|
1329
1517
|
#endif
|
1330
1518
|
#endif
|
1331
1519
|
|
1332
|
-
#if defined (__arm) && defined (__acorn) && defined (__unix)
|
1333
|
-
printf ("arm-acorn-riscix\n"); exit (0);
|
1334
|
-
#endif
|
1335
|
-
|
1336
|
-
#if defined (hp300) && !defined (hpux)
|
1337
|
-
printf ("m68k-hp-bsd\n"); exit (0);
|
1338
|
-
#endif
|
1339
|
-
|
1340
1520
|
#if defined (NeXT)
|
1341
1521
|
#if !defined (__ARCHITECTURE__)
|
1342
1522
|
#define __ARCHITECTURE__ "m68k"
|
@@ -1376,39 +1556,54 @@ main ()
|
|
1376
1556
|
#endif
|
1377
1557
|
|
1378
1558
|
#if defined (_SEQUENT_)
|
1379
|
-
|
1380
|
-
|
1381
|
-
uname(&un);
|
1382
|
-
|
1383
|
-
if (strncmp(un.version, "V2", 2) == 0) {
|
1384
|
-
printf ("i386-sequent-ptx2\n"); exit (0);
|
1385
|
-
}
|
1386
|
-
if (strncmp(un.version, "V1", 2) == 0) { /* XXX is V1 correct? */
|
1387
|
-
printf ("i386-sequent-ptx1\n"); exit (0);
|
1388
|
-
}
|
1389
|
-
printf ("i386-sequent-ptx\n"); exit (0);
|
1559
|
+
struct utsname un;
|
1390
1560
|
|
1561
|
+
uname(&un);
|
1562
|
+
if (strncmp(un.version, "V2", 2) == 0) {
|
1563
|
+
printf ("i386-sequent-ptx2\n"); exit (0);
|
1564
|
+
}
|
1565
|
+
if (strncmp(un.version, "V1", 2) == 0) { /* XXX is V1 correct? */
|
1566
|
+
printf ("i386-sequent-ptx1\n"); exit (0);
|
1567
|
+
}
|
1568
|
+
printf ("i386-sequent-ptx\n"); exit (0);
|
1391
1569
|
#endif
|
1392
1570
|
|
1393
1571
|
#if defined (vax)
|
1394
|
-
#
|
1395
|
-
#
|
1396
|
-
#
|
1397
|
-
#
|
1398
|
-
|
1399
|
-
#
|
1400
|
-
#
|
1401
|
-
|
1402
|
-
#
|
1403
|
-
|
1404
|
-
#
|
1405
|
-
#
|
1406
|
-
#
|
1407
|
-
|
1408
|
-
#
|
1409
|
-
#
|
1410
|
-
|
1411
|
-
|
1572
|
+
#if !defined (ultrix)
|
1573
|
+
#include <sys/param.h>
|
1574
|
+
#if defined (BSD)
|
1575
|
+
#if BSD == 43
|
1576
|
+
printf ("vax-dec-bsd4.3\n"); exit (0);
|
1577
|
+
#else
|
1578
|
+
#if BSD == 199006
|
1579
|
+
printf ("vax-dec-bsd4.3reno\n"); exit (0);
|
1580
|
+
#else
|
1581
|
+
printf ("vax-dec-bsd\n"); exit (0);
|
1582
|
+
#endif
|
1583
|
+
#endif
|
1584
|
+
#else
|
1585
|
+
printf ("vax-dec-bsd\n"); exit (0);
|
1586
|
+
#endif
|
1587
|
+
#else
|
1588
|
+
#if defined(_SIZE_T_) || defined(SIGLOST)
|
1589
|
+
struct utsname un;
|
1590
|
+
uname (&un);
|
1591
|
+
printf ("vax-dec-ultrix%s\n", un.release); exit (0);
|
1592
|
+
#else
|
1593
|
+
printf ("vax-dec-ultrix\n"); exit (0);
|
1594
|
+
#endif
|
1595
|
+
#endif
|
1596
|
+
#endif
|
1597
|
+
#if defined(ultrix) || defined(_ultrix) || defined(__ultrix) || defined(__ultrix__)
|
1598
|
+
#if defined(mips) || defined(__mips) || defined(__mips__) || defined(MIPS) || defined(__MIPS__)
|
1599
|
+
#if defined(_SIZE_T_) || defined(SIGLOST)
|
1600
|
+
struct utsname *un;
|
1601
|
+
uname (&un);
|
1602
|
+
printf ("mips-dec-ultrix%s\n", un.release); exit (0);
|
1603
|
+
#else
|
1604
|
+
printf ("mips-dec-ultrix\n"); exit (0);
|
1605
|
+
#endif
|
1606
|
+
#endif
|
1412
1607
|
#endif
|
1413
1608
|
|
1414
1609
|
#if defined (alliant) && defined (i860)
|
@@ -1419,54 +1614,44 @@ main ()
|
|
1419
1614
|
}
|
1420
1615
|
EOF
|
1421
1616
|
|
1422
|
-
$CC_FOR_BUILD -o $dummy $dummy.c 2>/dev/null && SYSTEM_NAME=`$dummy` &&
|
1617
|
+
$CC_FOR_BUILD -o "$dummy" "$dummy.c" 2>/dev/null && SYSTEM_NAME=`$dummy` &&
|
1423
1618
|
{ echo "$SYSTEM_NAME"; exit; }
|
1424
1619
|
|
1425
1620
|
# Apollos put the system type in the environment.
|
1621
|
+
test -d /usr/apollo && { echo "$ISP-apollo-$SYSTYPE"; exit; }
|
1426
1622
|
|
1427
|
-
|
1623
|
+
echo "$0: unable to guess system type" >&2
|
1428
1624
|
|
1429
|
-
|
1625
|
+
case "$UNAME_MACHINE:$UNAME_SYSTEM" in
|
1626
|
+
mips:Linux | mips64:Linux)
|
1627
|
+
# If we got here on MIPS GNU/Linux, output extra information.
|
1628
|
+
cat >&2 <<EOF
|
1430
1629
|
|
1431
|
-
|
1432
|
-
|
1433
|
-
|
1434
|
-
|
1435
|
-
|
1436
|
-
exit ;;
|
1437
|
-
c2*)
|
1438
|
-
if getsysinfo -f scalar_acc
|
1439
|
-
then echo c32-convex-bsd
|
1440
|
-
else echo c2-convex-bsd
|
1441
|
-
fi
|
1442
|
-
exit ;;
|
1443
|
-
c34*)
|
1444
|
-
echo c34-convex-bsd
|
1445
|
-
exit ;;
|
1446
|
-
c38*)
|
1447
|
-
echo c38-convex-bsd
|
1448
|
-
exit ;;
|
1449
|
-
c4*)
|
1450
|
-
echo c4-convex-bsd
|
1451
|
-
exit ;;
|
1452
|
-
esac
|
1453
|
-
fi
|
1630
|
+
NOTE: MIPS GNU/Linux systems require a C compiler to fully recognize
|
1631
|
+
the system type. Please install a C compiler and try again.
|
1632
|
+
EOF
|
1633
|
+
;;
|
1634
|
+
esac
|
1454
1635
|
|
1455
1636
|
cat >&2 <<EOF
|
1456
|
-
$0: unable to guess system type
|
1457
1637
|
|
1458
|
-
This script
|
1459
|
-
|
1460
|
-
|
1638
|
+
This script (version $timestamp), has failed to recognize the
|
1639
|
+
operating system you are using. If your script is old, overwrite *all*
|
1640
|
+
copies of config.guess and config.sub with the latest versions from:
|
1461
1641
|
|
1462
|
-
|
1642
|
+
https://git.savannah.gnu.org/gitweb/?p=config.git;a=blob_plain;f=config.guess
|
1463
1643
|
and
|
1464
|
-
|
1644
|
+
https://git.savannah.gnu.org/gitweb/?p=config.git;a=blob_plain;f=config.sub
|
1645
|
+
EOF
|
1465
1646
|
|
1466
|
-
|
1467
|
-
|
1468
|
-
|
1469
|
-
|
1647
|
+
year=`echo $timestamp | sed 's,-.*,,'`
|
1648
|
+
# shellcheck disable=SC2003
|
1649
|
+
if test "`expr "\`date +%Y\`" - "$year"`" -lt 3 ; then
|
1650
|
+
cat >&2 <<EOF
|
1651
|
+
|
1652
|
+
If $0 has already been updated, send the following data and any
|
1653
|
+
information you think might be pertinent to config-patches@gnu.org to
|
1654
|
+
provide the necessary information to handle your system.
|
1470
1655
|
|
1471
1656
|
config.guess timestamp = $timestamp
|
1472
1657
|
|
@@ -1485,16 +1670,17 @@ hostinfo = `(hostinfo) 2>/dev/null`
|
|
1485
1670
|
/usr/bin/oslevel = `(/usr/bin/oslevel) 2>/dev/null`
|
1486
1671
|
/usr/convex/getsysinfo = `(/usr/convex/getsysinfo) 2>/dev/null`
|
1487
1672
|
|
1488
|
-
UNAME_MACHINE = $
|
1489
|
-
UNAME_RELEASE = $
|
1490
|
-
UNAME_SYSTEM = $
|
1491
|
-
UNAME_VERSION = $
|
1673
|
+
UNAME_MACHINE = "$UNAME_MACHINE"
|
1674
|
+
UNAME_RELEASE = "$UNAME_RELEASE"
|
1675
|
+
UNAME_SYSTEM = "$UNAME_SYSTEM"
|
1676
|
+
UNAME_VERSION = "$UNAME_VERSION"
|
1492
1677
|
EOF
|
1678
|
+
fi
|
1493
1679
|
|
1494
1680
|
exit 1
|
1495
1681
|
|
1496
1682
|
# Local variables:
|
1497
|
-
# eval: (add-hook '
|
1683
|
+
# eval: (add-hook 'before-save-hook 'time-stamp)
|
1498
1684
|
# time-stamp-start: "timestamp='"
|
1499
1685
|
# time-stamp-format: "%:y-%02m-%02d"
|
1500
1686
|
# time-stamp-end: "'"
|