From 51bc61a96e64a7f2815a0d7d1e8c4871c25866fe Mon Sep 17 00:00:00 2001 From: Garrett Barter Date: Thu, 23 May 2024 05:23:32 -0600 Subject: [PATCH 1/5] trying to improve conda and pypi builds --- .github/workflows/Publish_ROSCO.yml | 34 +++- pyproject.toml | 4 + rosco/controller/src/ROSCO_IO.f90 | 14 +- .../controller/src/SysFiles/SysLLVMLinux.f90 | 190 ++++++++++++++++++ rosco/controller/src/SysFiles/SysLLVMWin.f90 | 184 +++++++++++++++++ 5 files changed, 414 insertions(+), 12 deletions(-) create mode 100644 rosco/controller/src/SysFiles/SysLLVMLinux.f90 create mode 100644 rosco/controller/src/SysFiles/SysLLVMWin.f90 diff --git a/.github/workflows/Publish_ROSCO.yml b/.github/workflows/Publish_ROSCO.yml index 0f5e5c96..738561b7 100644 --- a/.github/workflows/Publish_ROSCO.yml +++ b/.github/workflows/Publish_ROSCO.yml @@ -12,7 +12,7 @@ jobs: strategy: fail-fast: false matrix: - os: [ubuntu-latest, windows-latest, macos-13, macos-14] + os: [ubuntu-latest, windows-latest, macos-12, macos-13, macos-14] steps: - name: Setup GNU Fortran @@ -51,16 +51,40 @@ jobs: - name: Checkout uses: actions/checkout@v4 - - name: Build wheels mac and linux - if: false == contains( matrix.os, 'windows') - uses: pypa/cibuildwheel@v2.17.0 + - name: Build wheels linux + if: contains( matrix.os, 'ubuntu') + uses: pypa/cibuildwheel@v2.18.1 + env: + CC: ${{ steps.install_cc.outputs.cc }} + CXX: ${{ steps.install_cc.outputs.cxx }} + + - name: Build wheels mac-12 + if: contains( matrix.os, 'macos-12') + uses: pypa/cibuildwheel@v2.18.1 + env: + CC: ${{ steps.install_cc.outputs.cc }} + CXX: ${{ steps.install_cc.outputs.cxx }} + CIBW_ENVIRONMENT_MACOS: MACOSX_DEPLOYMENT_TARGET="12.0" + + - name: Build wheels mac-13 + if: contains( matrix.os, 'macos-13') + uses: pypa/cibuildwheel@v2.18.1 + env: + CC: ${{ steps.install_cc.outputs.cc }} + CXX: ${{ steps.install_cc.outputs.cxx }} + CIBW_ENVIRONMENT_MACOS: MACOSX_DEPLOYMENT_TARGET="13.0" + + - name: Build wheels mac-14 + if: contains( matrix.os, 'macos-14') + uses: pypa/cibuildwheel@v2.18.1 env: CC: ${{ steps.install_cc.outputs.cc }} CXX: ${{ steps.install_cc.outputs.cxx }} + CIBW_ENVIRONMENT_MACOS: MACOSX_DEPLOYMENT_TARGET="14.0" - name: Build wheels windows if: contains( matrix.os, 'windows') - uses: pypa/cibuildwheel@v2.17.0 + uses: pypa/cibuildwheel@v2.18.1 - uses: actions/upload-artifact@v4 with: diff --git a/pyproject.toml b/pyproject.toml index 5b0f21cf..7604ada7 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -149,3 +149,7 @@ environment = { PKG_CONFIG_PATH="c:/opt/64/lib/pkgconfig" } [tool.cibuildwheel.windows] repair-wheel-command = "bash .github/tools/cibw_repair_wheel_command_windows.sh {wheel} {dest_dir}" +# On an Linux Intel runner with qemu installed, build Intel and ARM wheels (aarch64) for Docker. Ignoring: ppc64le s390x +[tool.cibuildwheel.linux] +archs = ["auto", "aarch64"] +before-all = "yum install -y czmq-devel czmq" diff --git a/rosco/controller/src/ROSCO_IO.f90 b/rosco/controller/src/ROSCO_IO.f90 index a4f44283..c537f9b4 100644 --- a/rosco/controller/src/ROSCO_IO.f90 +++ b/rosco/controller/src/ROSCO_IO.f90 @@ -904,20 +904,20 @@ SUBROUTINE Debug(LocalVar, CntrPar, DebugVar, ErrVar, avrSWAP, RootName, size_av ! Process DebugOutData, LocalVarOutData ! Remove very small numbers that cause ******** outputs DO I = 1,SIZE(DebugOutData) - IF (ABS(DebugOutData(I)) < 1E-99) THEN + IF (ABS(DebugOutData(I)) < 1D-99) THEN DebugOutData(I) = 0 END IF - IF (ABS(DebugOutData(I)) > 1E+99) THEN - DebugOutData(I) = 1E+99 + IF (ABS(DebugOutData(I)) > 1D+99) THEN + DebugOutData(I) = 1D+99 END IF END DO DO I = 1,SIZE(LocalVarOutData) - IF (ABS(LocalVarOutData(I)) < 1E-99) THEN + IF (ABS(LocalVarOutData(I)) < 1D-99) THEN LocalVarOutData(I) = 0 END IF - IF (ABS(LocalVarOutData(I)) > 1E+99) THEN - LocalVarOutData(I) = 1E+99 + IF (ABS(LocalVarOutData(I)) > 1D+99) THEN + LocalVarOutData(I) = 1D+99 END IF END DO @@ -945,4 +945,4 @@ SUBROUTINE Debug(LocalVar, CntrPar, DebugVar, ErrVar, avrSWAP, RootName, size_av ENDIF END SUBROUTINE Debug -END MODULE ROSCO_IO \ No newline at end of file +END MODULE ROSCO_IO diff --git a/rosco/controller/src/SysFiles/SysLLVMLinux.f90 b/rosco/controller/src/SysFiles/SysLLVMLinux.f90 new file mode 100644 index 00000000..0b9a9775 --- /dev/null +++ b/rosco/controller/src/SysFiles/SysLLVMLinux.f90 @@ -0,0 +1,190 @@ +!********************************************************************************************************************************** +! LICENSING +! Copyright (C) 2021 National Renewable Energy Laboratory +! +! This file is part of ROSCO. +! +! Licensed under the Apache License, Version 2.0 (the "License"); +! you may not use this file except in compliance with the License. +! You may obtain a copy of the License at +! +! http://www.apache.org/licenses/LICENSE-2.0 +! +! Unless required by applicable law or agreed to in writing, software +! distributed under the License is distributed on an "AS IS" BASIS, +! WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +! See the License for the specific language governing permissions and +! limitations under the License. +!********************************************************************************************************************************** +MODULE SysSubs + + USE ROSCO_Types + USE Constants + + + IMPLICIT NONE + + +! This module contains routines with system-specific logic and references, including all references to the console unit, CU. +! It also contains standard (but not system-specific) routines it uses. +! SysGnuLinux.f90 is specifically for the GNU Fortran (gfortran) compiler on Linux and macOS. + + INTEGER, PARAMETER :: ConRecL = 120 ! The record length for console output. + INTEGER, PARAMETER :: CU = 6 ! The I/O unit for the console. Unit 6 causes ADAMS to crash. + INTEGER, PARAMETER :: MaxWrScrLen = 98 ! The maximum number of characters allowed to be written to a line in WrScr + LOGICAL, PARAMETER :: KBInputOK = .TRUE. ! A flag to tell the program that keyboard input is allowed in the environment. + CHARACTER(*), PARAMETER :: NewLine = ACHAR(10) ! The delimiter for New Lines [ Windows is CHAR(13)//CHAR(10); MAC is CHAR(13); Unix is CHAR(10) {CHAR(13)=\r is a line feed, CHAR(10)=\n is a new line}] + CHARACTER(*), PARAMETER :: OS_Desc = 'LLVM Fortran for Linux' ! Description of the language/OS + CHARACTER( 1), PARAMETER :: PathSep = '/' ! The path separator. + CHARACTER( 1), PARAMETER :: SwChar = '-' ! The switch character for command-line options. + CHARACTER(11), PARAMETER :: UnfForm = 'UNFORMATTED' ! The string to specify unformatted I/O files. + + + CONTAINS +!================================================================================================================= + SUBROUTINE LoadDynamicLib ( DLL, ErrStat, ErrMsg ) + + ! This SUBROUTINE is used to dynamically load a DLL. + + TYPE (ExtDLL_Type), INTENT(INOUT) :: DLL ! The DLL to be loaded. + INTEGER(IntKi), INTENT( OUT) :: ErrStat ! Error status of the operation + CHARACTER(*), INTENT( OUT) :: ErrMsg ! Error message if ErrStat /= ErrID_None + + + !bjj: these are values I found on the web; I have no idea if they actually work... + !bjj: hopefully we can find them pre-defined in a header somewhere + INTEGER(C_INT), PARAMETER :: RTLD_LAZY=1 ! "Perform lazy binding. Only resolve symbols as the code that references them is executed. If the symbol is never referenced, then it is never resolved. (Lazy binding is only performed for function references; references to variables are always immediately bound when the library is loaded.) " + INTEGER(C_INT), PARAMETER :: RTLD_NOW=2 ! "If this value is specified, or the environment variable LD_BIND_NOW is set to a nonempty string, all undefined symbols in the library are resolved before dlopen() returns. If this cannot be done, an error is returned." + INTEGER(C_INT), PARAMETER :: RTLD_GLOBAL=256 ! "The symbols defined by this library will be made available for symbol resolution of subsequently loaded libraries" + INTEGER(C_INT), PARAMETER :: RTLD_LOCAL=0 ! "This is the converse of RTLD_GLOBAL, and the default if neither flag is specified. Symbols defined in this library are not made available to resolve references in subsequently loaded libraries." + + INTERFACE !linux API routines + !bjj see http://linux.die.net/man/3/dlopen + ! and https://developer.apple.com/library/mac/documentation/Darwin/Reference/ManPages/man3/dlopen.3.html + + FUNCTION dlOpen(filename,mode) BIND(C,NAME="dlopen") + ! void *dlopen(const char *filename, int mode); + USE ISO_C_BINDING + IMPLICIT NONE + TYPE(C_PTR) :: dlOpen + CHARACTER(C_CHAR), INTENT(IN) :: filename(*) + INTEGER(C_INT), VALUE :: mode + END FUNCTION + + END INTERFACE + + ErrStat = 0 + ErrMsg = '' + + ! Load the DLL and get the file address: + + DLL%FileAddrX = dlOpen( TRIM(DLL%FileName)//C_NULL_CHAR, RTLD_LAZY ) !the "C_NULL_CHAR" converts the Fortran string to a C-type string (i.e., adds //CHAR(0) to the end) + + IF( .NOT. C_ASSOCIATED(DLL%FileAddrX) ) THEN + ErrStat = -1 + ! WRITE(ErrMsg,'(I2)') BITS_IN_ADDR + ErrMsg = 'The dynamic library '//TRIM(DLL%FileName)//' could not be loaded. Check that the file '// & + 'exists in the specified location and that it is compiled for '//TRIM(ErrMsg)//'-bit applications.' + RETURN + END IF + + ! Get the procedure address: + + CALL LoadDynamicLibProc ( DLL, ErrStat, ErrMsg ) + + RETURN + END SUBROUTINE LoadDynamicLib + !======================================================================= + SUBROUTINE LoadDynamicLibProc ( DLL, ErrStat, ErrMsg ) + + ! This SUBROUTINE is used to dynamically load a procedure from a DLL. + + TYPE (ExtDLL_Type), INTENT(INOUT) :: DLL ! The DLL to be loaded. + INTEGER(IntKi), INTENT( OUT) :: ErrStat ! Error status of the operation + CHARACTER(*), INTENT( OUT) :: ErrMsg ! Error message if ErrStat /= ErrID_None + INTEGER(IntKi) :: i + + + INTERFACE !linux API routines + + !bjj see http://linux.die.net/man/3/dlsym + ! and https://developer.apple.com/library/mac/documentation/Darwin/Reference/ManPages/man3/dlsym.3.html + + FUNCTION dlSym(handle,name) BIND(C,NAME="dlsym") + ! void *dlsym(void *handle, const char *name); + USE ISO_C_BINDING + IMPLICIT NONE + TYPE(C_FUNPTR) :: dlSym ! A function pointer + TYPE(C_PTR), VALUE :: handle + CHARACTER(C_CHAR), INTENT(IN) :: name(*) + END FUNCTION + + END INTERFACE + + ErrStat = ErrID_None + ErrMsg = '' + + do i=1,NWTC_MAX_DLL_PROC + if ( len_trim( DLL%ProcName(i) ) > 0 ) then + + DLL%ProcAddr(i) = dlSym( DLL%FileAddrX, TRIM(DLL%ProcName(i))//C_NULL_CHAR ) !the "C_NULL_CHAR" converts the Fortran string to a C-type string (i.e., adds //CHAR(0) to the end) + + IF(.NOT. C_ASSOCIATED(DLL%ProcAddr(i))) THEN + ErrStat = ErrID_Fatal + ErrMsg = 'The procedure '//TRIM(DLL%ProcName(i))//' in file '//TRIM(DLL%FileName)//' could not be loaded.' + RETURN + END IF + + end if + end do + + RETURN + END SUBROUTINE LoadDynamicLibProc + !======================================================================= + SUBROUTINE FreeDynamicLib ( DLL, ErrStat, ErrMsg ) + + ! This SUBROUTINE is used to free a dynamically loaded DLL (loaded in LoadDynamicLib). + + TYPE (ExtDLL_Type), INTENT(INOUT) :: DLL ! The DLL to be freed. + INTEGER(IntKi), INTENT( OUT) :: ErrStat ! Error status of the operation + CHARACTER(*), INTENT( OUT) :: ErrMsg ! Error message if ErrStat /= ErrID_None + INTEGER(C_INT) :: Success ! Whether or not the call to dlClose was successful + INTEGER(C_INT), PARAMETER :: TRUE = 0 + + !bjj: note that this is not tested. + + INTERFACE !linux API routine + !bjj see http://linux.die.net/man/3/dlclose + ! and https://developer.apple.com/library/mac/documentation/Darwin/Reference/ManPages/man3/dlclose.3.html + + FUNCTION dlClose(handle) BIND(C,NAME="dlclose") + ! int dlclose(void *handle); + USE ISO_C_BINDING + IMPLICIT NONE + INTEGER(C_INT) :: dlClose + TYPE(C_PTR), VALUE :: handle + END FUNCTION + + END INTERFACE + + ! Close the library: + + IF( .NOT. C_ASSOCIATED(DLL%FileAddrX) ) RETURN + Success = dlClose( DLL%FileAddrX ) !The function dlclose() returns 0 on success, and nonzero on error. + + IF ( Success /= TRUE ) THEN !bjj: note that this is not the same as LOGICAL .TRUE. + ErrStat = ErrID_Fatal + ErrMsg = 'The dynamic library could not be freed.' + RETURN + ELSE + ErrStat = ErrID_None + ErrMsg = '' + DLL%FileAddrX = C_NULL_PTR + END IF + + + RETURN + END SUBROUTINE FreeDynamicLib + !======================================================================= + +END MODULE SysSubs diff --git a/rosco/controller/src/SysFiles/SysLLVMWin.f90 b/rosco/controller/src/SysFiles/SysLLVMWin.f90 new file mode 100644 index 00000000..395814aa --- /dev/null +++ b/rosco/controller/src/SysFiles/SysLLVMWin.f90 @@ -0,0 +1,184 @@ +!********************************************************************************************************************************** +! LICENSING +! Copyright (C) 2021 National Renewable Energy Laboratory +! +! This file is part of ROSCO. +! +! Licensed under the Apache License, Version 2.0 (the "License"); +! you may not use this file except in compliance with the License. +! You may obtain a copy of the License at +! +! http://www.apache.org/licenses/LICENSE-2.0 +! +! Unless required by applicable law or agreed to in writing, software +! distributed under the License is distributed on an "AS IS" BASIS, +! WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +! See the License for the specific language governing permissions and +! limitations under the License. +!********************************************************************************************************************************** +MODULE SysSubs + + USE ROSCO_Types + USE Constants + + + IMPLICIT NONE + + + + + +! This module contains routines with system-specific logic and references, including all references to the console unit, CU. +! It also contains standard (but not system-specific) routines it uses. +! SysGnuLinux.f90 is specifically for the GNU Fortran (gfortran) compiler on Linux and macOS. + + INTEGER, PARAMETER :: ConRecL = 120 ! The record length for console output. + INTEGER, PARAMETER :: CU = 6 ! The I/O unit for the console. Unit 6 causes ADAMS to crash. + INTEGER, PARAMETER :: MaxWrScrLen = 98 ! The maximum number of characters allowed to be written to a line in WrScr + LOGICAL, PARAMETER :: KBInputOK = .TRUE. ! A flag to tell the program that keyboard input is allowed in the environment. + CHARACTER(*), PARAMETER :: NewLine = ACHAR(10) ! The delimiter for New Lines [ Windows is CHAR(13)//CHAR(10); MAC is CHAR(13); Unix is CHAR(10) {CHAR(13)=\r is a line feed, CHAR(10)=\n is a new line}] + CHARACTER(*), PARAMETER :: OS_Desc = 'LLVM Fortran for Windows' ! Description of the language/OS + CHARACTER( 1), PARAMETER :: PathSep = '\' ! The path separator. + CHARACTER( 1), PARAMETER :: SwChar = '/' ! The switch character for command-line options. + CHARACTER(11), PARAMETER :: UnfForm = 'UNFORMATTED' ! The string to specify unformatted I/O files. + + + CONTAINS +!======================================================================= + SUBROUTINE LoadDynamicLib ( DLL, ErrStat, ErrMsg ) + + ! This SUBROUTINE is used to dynamically load a DLL. + + TYPE (ExtDLL_Type), INTENT(INOUT) :: DLL ! The DLL to be loaded. + INTEGER(IntKi), INTENT( OUT) :: ErrStat ! Error status of the operation + CHARACTER(*), INTENT( OUT) :: ErrMsg ! Error message if ErrStat /= ErrID_None + + INTERFACE ! Definitions of Windows API routines + + !........................... + !bjj: I have been unable to find a solution that works with both IVF and gfortran... + !bjj: note that "Intel Fortran does not support use of STDCALL with BIND(C) at this time" + ! See this link: http://software.intel.com/en-us/articles/replacing-intel-fortran-attributes-with-c-interoperability-features + !bjj: Until this is fixed, Intel uses kernel32.f90 definitions instead of the interface below: + !........................... + + FUNCTION LoadLibrary(lpFileName) BIND(C,NAME='LoadLibraryA') + USE, INTRINSIC :: ISO_C_BINDING + IMPLICIT NONE + !GCC$ ATTRIBUTES STDCALL :: LoadLibrary + INTEGER(C_INTPTR_T) :: LoadLibrary + CHARACTER(KIND=C_CHAR) :: lpFileName(*) + END FUNCTION LoadLibrary + + END INTERFACE + + ErrStat = ErrID_None + ErrMsg = '' + + ! Load the DLL and get the file address: + DLL%FileAddr = LoadLibrary( TRIM(DLL%FileName)//C_NULL_CHAR ) !the "C_NULL_CHAR" converts the Fortran string to a C-type string (i.e., adds //CHAR(0) to the end) + IF ( DLL%FileAddr == INT(0,C_INTPTR_T) ) THEN + ErrStat = ErrID_Fatal + ! WRITE(ErrMsg,'(I2)') BITS_IN_ADDR + ErrMsg = 'The dynamic library '//TRIM(DLL%FileName)//' could not be loaded. Check that the file '// & + 'exists in the specified location and that it is compiled for '//TRIM(ErrMsg)//'-bit applications.' + RETURN + END IF + + ! Get the procedure address: + CALL LoadDynamicLibProc ( DLL, ErrStat, ErrMsg ) + + RETURN + END SUBROUTINE LoadDynamicLib + !======================================================================= + SUBROUTINE LoadDynamicLibProc ( DLL, ErrStat, ErrMsg ) + + ! This SUBROUTINE is used to dynamically load a procedure in a DLL. + + TYPE (ExtDLL_Type), INTENT(INOUT) :: DLL ! The DLL to be loaded. + INTEGER(IntKi), INTENT( OUT) :: ErrStat ! Error status of the operation + CHARACTER(*), INTENT( OUT) :: ErrMsg ! Error message if ErrStat /= ErrID_None + INTEGER(IntKi) :: i + + INTERFACE ! Definitions of Windows API routines + + !........................... + !bjj: I have been unable to find a solution that works with both IVF and gfortran... + !bjj: note that "Intel Fortran does not support use of STDCALL with BIND(C) at this time" + ! See this link: http://software.intel.com/en-us/articles/replacing-intel-fortran-attributes-with-c-interoperability-features + !bjj: Until this is fixed, Intel uses kernel32.f90 definitions instead of the interface below: + !........................... + + FUNCTION GetProcAddress(hModule, lpProcName) BIND(C, NAME='GetProcAddress') + USE, INTRINSIC :: ISO_C_BINDING + IMPLICIT NONE + !GCC$ ATTRIBUTES STDCALL :: GetProcAddress + TYPE(C_FUNPTR) :: GetProcAddress + INTEGER(C_INTPTR_T),VALUE :: hModule + CHARACTER(KIND=C_CHAR) :: lpProcName(*) + END FUNCTION GetProcAddress + + END INTERFACE + + ErrStat = ErrID_None + ErrMsg = '' + + ! Get the procedure addresses: + do i=1,NWTC_MAX_DLL_PROC + if ( len_trim( DLL%ProcName(i) ) > 0 ) then + DLL%ProcAddr(i) = GetProcAddress( DLL%FileAddr, TRIM(DLL%ProcName(i))//C_NULL_CHAR ) !the "C_NULL_CHAR" converts the Fortran string to a C-type string (i.e., adds //CHAR(0) to the end) + IF(.NOT. C_ASSOCIATED(DLL%ProcAddr(i))) THEN + ErrStat = ErrID_Fatal + i - 1 + ErrMsg = 'The procedure '//TRIM(DLL%ProcName(i))//' in file '//TRIM(DLL%FileName)//' could not be loaded.' + RETURN + END IF + end if + end do + + RETURN + END SUBROUTINE LoadDynamicLibProc + !======================================================================= + SUBROUTINE FreeDynamicLib ( DLL, ErrStat, ErrMsg ) + + ! This SUBROUTINE is used to free a dynamically loaded DLL (loaded in LoadDynamicLib). + + TYPE (ExtDLL_Type), INTENT(INOUT) :: DLL ! The DLL to be freed. + INTEGER(IntKi), INTENT( OUT) :: ErrStat ! Error status of the operation + CHARACTER(*), INTENT( OUT) :: ErrMsg ! Error message if ErrStat /= ErrID_None + + ! Local variable: + INTEGER(C_INT) :: Success ! Whether or not the call to FreeLibrary was successful + INTEGER(C_INT), PARAMETER :: FALSE = 0 + + INTERFACE ! Definitions of Windows API routines + + FUNCTION FreeLibrary(hLibModule) BIND(C, NAME='FreeLibrary') + USE, INTRINSIC :: ISO_C_BINDING + IMPLICIT NONE + !GCC$ ATTRIBUTES STDCALL :: FreeLibrary + INTEGER(C_INT) :: FreeLibrary ! BOOL + INTEGER(C_INTPTR_T),VALUE :: hLibModule ! HMODULE hLibModule + END FUNCTION + + END INTERFACE + + ! Free the DLL: + IF ( DLL%FileAddr == INT(0,C_INTPTR_T) ) RETURN + + Success = FreeLibrary( DLL%FileAddr ) !If the function succeeds, the return value is nonzero. If the function fails, the return value is zero. + + IF ( Success == FALSE ) THEN !BJJ: note that this isn't the same as the Fortran LOGICAL .FALSE. + ErrStat = ErrID_Fatal + ErrMsg = 'The dynamic library could not be freed.' + RETURN + ELSE + ErrStat = ErrID_None + ErrMsg = '' + DLL%FileAddr = INT(0,C_INTPTR_T) + END IF + + RETURN + END SUBROUTINE FreeDynamicLib + !======================================================================= + +END MODULE SysSubs From 2dba5f08b70d75ec32cd21a2227cd484d5083cf2 Mon Sep 17 00:00:00 2001 From: Garrett Barter Date: Thu, 23 May 2024 08:03:36 -0600 Subject: [PATCH 2/5] adding wheel to cibuild prep --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 7604ada7..cb8a0469 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -138,7 +138,7 @@ atomic = true [tool.cibuildwheel] skip = ["pp*", "cp36-*", "cp37-*", "cp38-*", "*-win32", "*-win_arm64"] #, "*-musllinux*"] build-frontend = { name = "build", args = ["-w","-n"] } -before-build = "pip install setuptools cmake numpy pyzmq cmake-build-extension" +before-build = "pip install setuptools cmake numpy pyzmq cmake-build-extension wheel" build-verbosity = "3" # https://github.com/pdfo/pdfo From 8bb400f93cbb858300b96e74af12c49e7abc2abd Mon Sep 17 00:00:00 2001 From: Garrett Barter Date: Thu, 23 May 2024 09:46:25 -0600 Subject: [PATCH 3/5] overkill on linux libraries --- pyproject.toml | 1 - 1 file changed, 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index cb8a0469..c70b6ce3 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -152,4 +152,3 @@ repair-wheel-command = "bash .github/tools/cibw_repair_wheel_command_windows.sh # On an Linux Intel runner with qemu installed, build Intel and ARM wheels (aarch64) for Docker. Ignoring: ppc64le s390x [tool.cibuildwheel.linux] archs = ["auto", "aarch64"] -before-all = "yum install -y czmq-devel czmq" From 89590aaef754270eb6b225a50b0401964083dc4a Mon Sep 17 00:00:00 2001 From: Garrett Barter Date: Thu, 23 May 2024 16:29:48 -0600 Subject: [PATCH 4/5] forgot a step --- .github/workflows/Publish_ROSCO.yml | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/.github/workflows/Publish_ROSCO.yml b/.github/workflows/Publish_ROSCO.yml index 738561b7..2202c5fe 100644 --- a/.github/workflows/Publish_ROSCO.yml +++ b/.github/workflows/Publish_ROSCO.yml @@ -15,6 +15,12 @@ jobs: os: [ubuntu-latest, windows-latest, macos-12, macos-13, macos-14] steps: + - name: Set up QEMU + if: runner.os == 'Linux' + uses: docker/setup-qemu-action@v3 + with: + platforms: all + - name: Setup GNU Fortran if: false == contains( matrix.os, 'windows') uses: awvwgk/setup-fortran@v1 From 3092a5198982f2d32b6fd3c4a234cbeae9c2dea9 Mon Sep 17 00:00:00 2001 From: Garrett Barter Date: Fri, 24 May 2024 09:51:45 -0600 Subject: [PATCH 5/5] removing musl aarch64, but don't understand why it fails --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index c70b6ce3..4031f482 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -136,7 +136,7 @@ atomic = true #src_paths=isort,test [tool.cibuildwheel] -skip = ["pp*", "cp36-*", "cp37-*", "cp38-*", "*-win32", "*-win_arm64"] #, "*-musllinux*"] +skip = ["pp*", "cp36-*", "cp37-*", "cp38-*", "*-win32", "*-win_arm64", "*-musllinux_aarch64"] build-frontend = { name = "build", args = ["-w","-n"] } before-build = "pip install setuptools cmake numpy pyzmq cmake-build-extension wheel" build-verbosity = "3"