diff --git a/CHANGELOG.md b/CHANGELOG.md index 0f74e5d9e..99b691106 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -2,6 +2,8 @@ ## master (unreleased) +## v1.7.3 + ### Changes * Improve support for xp and mingw @@ -279,6 +281,8 @@ ## master (开发中) +## v1.7.3 + ### 改进 * 改进对 xp 和 mingw 的支持 diff --git a/configure b/configure index 4f9cbfd89..a0f42ae4e 100755 --- a/configure +++ b/configure @@ -2841,6 +2841,18 @@ toolchain "i686_w64_mingw32" set_toolset "ar" "i686-w64-mingw32-ar" "ar" toolchain_end +# aarch64 toolchain (aarch64) +toolchain "aarch64_linux_gnu" + set_toolset "as" "aarch64-linux-gnu-gcc" + set_toolset "cc" "aarch64-linux-gnu-gcc" + set_toolset "cxx" "aarch64-linux-gnu-gcc" "aarch64-linux-gnu-g++" + set_toolset "mm" "aarch64-linux-gnu-gcc" + set_toolset "mxx" "aarch64-linux-gnu-gcc" "aarch64-linux-gnu-g++" + set_toolset "ld" "aarch64-linux-gnu-g++" "aarch64-linux-gnu-gcc" + set_toolset "sh" "aarch64-linux-gnu-g++" "aarch64-linux-gnu-gcc" + set_toolset "ar" "aarch64-linux-gnu-ar" "ar" +toolchain_end + # check platform _check_platform() { if test "x${_target_plat}" = "x"; then @@ -3157,6 +3169,11 @@ _toolchain_detect() { else toolchains="x86_64_w64_mingw32" fi + elif is_plat "linux" && ! is_arch "${os_arch}"; then + toolchains="envs" + if is_arch "arm64"; then + toolchains="${toolchains} aarch64_linux_gnu" + fi else toolchains="envs gcc clang" fi @@ -3715,18 +3732,19 @@ _gmake_add_switches() { echo "INSTALLDIR:=\$(DESTDIR)" >> "${xmake_sh_makefile}" echo "endif" >> "${xmake_sh_makefile}" echo "" >> "${xmake_sh_makefile}" + echo "ifeq (\$(PREFIX),)" >> "${xmake_sh_makefile}" + echo "PREFIX=${_install_prefix_default}" >> "${xmake_sh_makefile}" + echo "endif" >> "${xmake_sh_makefile}" + echo "" >> "${xmake_sh_makefile}" echo "ifneq (\$(PREFIX),)" >> "${xmake_sh_makefile}" echo "ifneq (\$(INSTALLDIR),)" >> "${xmake_sh_makefile}" - echo "INSTALLDIR:=\$(INSTALLDIR)/\$(PREFIX)" >> "${xmake_sh_makefile}" + echo "PREFIX_:=\$(patsubst /%,%,\$(PREFIX))" >> "${xmake_sh_makefile}" + echo "INSTALLDIR:=\$(INSTALLDIR)/\$(PREFIX_)" >> "${xmake_sh_makefile}" echo "else" >> "${xmake_sh_makefile}" echo "INSTALLDIR:=\$(PREFIX)" >> "${xmake_sh_makefile}" echo "endif" >> "${xmake_sh_makefile}" echo "endif" >> "${xmake_sh_makefile}" echo "" >> "${xmake_sh_makefile}" - echo "ifeq (\$(INSTALLDIR),)" >> "${xmake_sh_makefile}" - echo "INSTALLDIR=${_install_prefix_default}" >> "${xmake_sh_makefile}" - echo "endif" >> "${xmake_sh_makefile}" - echo "" >> "${xmake_sh_makefile}" } _gmake_add_flags() { @@ -3957,10 +3975,12 @@ _gmake_add_install_target() { _get_target_item "${target}" "kind"; local targetkind="${_ret}" if test_eq "${targetkind}" "binary"; then string_replace "${_install_bindir_default}" "\${prefix}" "${installdir}"; _install_bindir_default="${_ret}" + print "\t@echo installing ${targetfile} to ${_install_bindir_default}" >> "${xmake_sh_makefile}" print "\t@mkdir -p ${_install_bindir_default}" >> "${xmake_sh_makefile}" print "\t@cp -p ${targetfile} ${_install_bindir_default}/${filename}" >> "${xmake_sh_makefile}" elif test_eq "${targetkind}" "static" || test_eq "${targetkind}" "shared"; then string_replace "${_install_libdir_default}" "\${prefix}" "${installdir}"; _install_libdir_default="${_ret}" + print "\t@echo installing ${targetfile} to ${_install_libdir_default}" >> "${xmake_sh_makefile}" print "\t@mkdir -p ${_install_libdir_default}" >> "${xmake_sh_makefile}" print "\t@cp -p ${targetfile} ${_install_libdir_default}/${filename}" >> "${xmake_sh_makefile}" fi diff --git a/src/xmake.sh b/src/xmake.sh index 652a627a7..3c9a83a75 100755 --- a/src/xmake.sh +++ b/src/xmake.sh @@ -1,7 +1,7 @@ #!/bin/sh set_project "tbox" -set_version "1.7.2" "%Y%m%d" +set_version "1.7.3" "%Y%m%d" # set warning all as error set_warnings "all" "error" diff --git a/xmake.lua b/xmake.lua index f01f8aa8e..20d8b6f28 100644 --- a/xmake.lua +++ b/xmake.lua @@ -5,7 +5,7 @@ set_project("tbox") set_xmakever("2.6.1") -- set project version -set_version("1.7.2", {build = "%Y%m%d"}) +set_version("1.7.3", {build = "%Y%m%d"}) -- set warning all as error set_warnings("all", "error")