Trouble with installation on Mac

62 views
Skip to first unread message

Jacob Krebs

unread,
Feb 15, 2023, 3:45:43 PM2/15/23
to enzo-dev
Been butting my head against the wall trying to figure this out. I followed the steps in the terminal successfully through "make machine-darwin". When I type "make" the following error occurs and I am not sure how to fix it:

-e

Updating DEPEND

make: [dep] Error 127 (ignored)

make: [dep] Error 127 (ignored)

make: [dep] Error 127 (ignored)

make: [dep] Error 127 (ignored)

make: [dep] Error 127 (ignored)

make: [dep] Error 127 (ignored)

make: [dep] Error 127 (ignored)

Compiling enzo.C


mpic++  -c -o enzo.o -DLINUX -DH5_USE_16_API   -D__max_subgrids=100000 -D__max_baryons=30 -D__max_cpu_per_node=8 -D__memory_pool_size=100000 -DINITS64 -DLARGE_INTS -DCONFIG_PINT_8 -DIO_32    -DUSE_MPI   -DCONFIG_PFLOAT_8 -DCONFIG_BFLOAT_8  -DUSE_HDF5_GROUPS   -DTRANSFER   -DNEW_GRID_IO -DFAST_SIB      -DENZO_PERFORMANCE    -DUSE_UUID -DSAB  -g -I/include -I/Developer/CUDA/common/inc -I/usr/local/include           -I. enzo.C


In file included from enzo.C:30:

./EnzoTiming.h:209:7: warning: 'sprintf' is deprecated: This function is provided for compatibility reasons only.  Due to security concerns inherent in the design of sprintf(3), it is highly recommended that you use snprintf(3) instead. [-Wdeprecated-declarations]

      sprintf(level_name, "Level_%02d", level);

      ^

/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/stdio.h:188:1: note: 'sprintf' has been explicitly marked deprecated here

__deprecated_msg("This function is provided for compatibility reasons only.  Due to security concerns inherent in the design of sprintf(3), it is highly recommended that you use snprintf(3) instead.")

^

/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/sys/cdefs.h:215:48: note: expanded from macro '__deprecated_msg'

        #define __deprecated_msg(_msg) __attribute__((__deprecated__(_msg)))

                                                      ^

In file included from enzo.C:34:

In file included from ./typedefs.h:16:

./EquilibriumTable.h:5:1: warning: '/*' within block comment [-Wcomment]

/*****************************************/

^

In file included from enzo.C:41:

In file included from ./Grid.h:20:

./AMRH5writer.h:24:10: fatal error: 'hdf5.h' file not found

#include <hdf5.h>

         ^~~~~~~~

2 warnings and 1 error generated.


make: *** [enzo.o] Error 1



I brew installed hdf5 and that did not resolve the issue. Anyone have any ideas?

John Wise

unread,
Feb 17, 2023, 4:43:27 PM2/17/23
to enzo...@googlegroups.com

Hi Jacob,

You can ignore all of those warnings about sprintf and the "[dep] Error 127" lines.  The issue that's causing your build to fail is the last thing that's outputted. Here it's telling you that it can't find the hdf5.h header file that's associated with HDF, which is used for I/O.

You need to change the LOCAL_HDF5_INSTALL line in the Make.mach.darwin file to point to the directory where HDF5 is installed.  Have you installed this package?  If not, you can use a package manager like Homebrew to install it on macOS, which should install things in /usr/local/Cellar/.

Thanks,
John

--
You received this message because you are subscribed to the Google Groups "enzo-dev" group.
To unsubscribe from this group and stop receiving emails from it, send an email to enzo-dev+u...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/enzo-dev/547f2b89-be02-459b-977c-1351f3866ecbn%40googlegroups.com.
-- 
John Wise
Director, Center for Relativistic Astrophysics
Professor, School of Physics
Georgia Institute of Technology
http://cosmo.gatech.edu

Jacob Krebs

unread,
Feb 21, 2023, 3:30:44 PM2/21/23
to enzo-dev
Thank you for the response.

I home-brewed the package already and tried used sublime text editor to try to change the line. The script I used was:

export PATH="/opt/homebrew/opt/qt@5/bin:$PATH"
export PATH="/Applications/Sublime Text.app/Contents/SharedSupport/bin:$PATH"

PATH_QT5="/opt/homebrew/Cellar/hdf5/1.12.2_2"
PATH_SUBLIME="/Applications/Sublime Text.app/Contents/SharedSupport/bin"
LOCAL_HDF5_INSTALL=/home/enzo-user/local/hdf5
export PATH="$LOCAL_HDF5_INSTALL:$PATH_QT5:$PATH_SUBLIME:$PATH"


but it did not seem to help. I tried to follow along with the FAQ which goes over this as well but am still getting the same error. Any ideas? Thanks.

Jacob

Jacob Krebs

unread,
Feb 21, 2023, 3:56:44 PM2/21/23
to enzo-dev
When I do that the new error is:

-e

Updating DEPEND

make: [dep] Error 127 (ignored)

make: [dep] Error 127 (ignored)

make: [dep] Error 127 (ignored)

make: [dep] Error 127 (ignored)

make: [dep] Error 127 (ignored)

make: [dep] Error 127 (ignored)

make: [dep] Error 127 (ignored)

Compiling enzo.C


mpic++  -c -o enzo.o -DLINUX -DH5_USE_16_API   -D__max_subgrids=100000 -D__max_baryons=30 -D__max_cpu_per_node=8 -D__memory_pool_size=100000 -DINITS64 -DLARGE_INTS -DCONFIG_PINT_8 -DIO_32    -DUSE_MPI   -DCONFIG_PFLOAT_8 -DCONFIG_BFLOAT_8  -DUSE_HDF5_GROUPS   -DTRANSFER   -DNEW_GRID_IO -DFAST_SIB      -DENZO_PERFORMANCE    -DUSE_UUID -DSAB  -g -I/opt/homebrew/Cellar/hdf5/1.12.2_2 /include -I/Developer/CUDA/common/inc -I/usr/local/include           -I. enzo.C


clang: error: no such file or directory: '/include'; did you mean '-include'?




John Wise

unread,
Feb 21, 2023, 5:27:41 PM2/21/23
to enzo...@googlegroups.com

Hi Jacob,

Are the lines in your first email a standalone script that you ran, or did you add those lines to the Make.mach.darwin file?  In any case, you should set

LOCAL_HDF5_INSTALL=/opt/homebrew/Cellar/hdf5/1.12.2_2

in Make.mach.darwin.  There's no reason to set anything with Sublime Text's and QT5's directories in any Enzo files.

About your second email, it looks like you have a trailing space in your HDF5 directory variable, looking at the error message and directories given in the compiler call

"-I/opt/homebrew/Cellar/hdf5/1.12.2_2 /include"

where the compiler would take "/include" as its own argument instead of being part of the directory.

Thanks,
John

Jacob Krebs

unread,
Feb 27, 2023, 4:07:36 PM2/27/23
to enzo-dev
I appreciate your patience and help John. I changed the make file and that error has gone away but now it is back to saying the hdf5.h can't be found. Here is the make file, I changed line 44.

Screenshot 2023-02-27 at 3.04.43 PM.png



-e

Updating DEPEND

make: [dep] Error 127 (ignored)

make: [dep] Error 127 (ignored)

make: [dep] Error 127 (ignored)

make: [dep] Error 127 (ignored)

make: [dep] Error 127 (ignored)

make: [dep] Error 127 (ignored)

make: [dep] Error 127 (ignored)

Compiling enzo.C


mpic++  -c -o enzo.o -DLINUX -DH5_USE_16_API   -D__max_subgrids=100000 -D__max_baryons=30 -D__max_cpu_per_node=8 -D__memory_pool_size=100000 -DINITS64 -DLARGE_INTS -DCONFIG_PINT_8 -DIO_32    -DUSE_MPI   -DCONFIG_PFLOAT_8 -DCONFIG_BFLOAT_8  -DUSE_HDF5_GROUPS   -DTRANSFER   -DNEW_GRID_IO -DFAST_SIB      -DENZO_PERFORMANCE    -DUSE_UUID -DSAB  -g -I/usr/local/Cellar/hdf5/1.12.2_2/include -I/Developer/CUDA/common/inc -I/usr/local/include           -I. enzo.C


In file included from enzo.C:30:

./EnzoTiming.h:209:7: warning: 'sprintf' is deprecated: This function is provided for compatibility reasons only.  Due to security concerns inherent in the design of sprintf(3), it is highly recommended that you use snprintf(3) instead. [-Wdeprecated-declarations]

      sprintf(level_name, "Level_%02d", level);

      ^

/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/stdio.h:188:1: note: 'sprintf' has been explicitly marked deprecated here

__deprecated_msg("This function is provided for compatibility reasons only.  Due to security concerns inherent in the design of sprintf(3), it is highly recommended that you use snprintf(3) instead.")

^

/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/sys/cdefs.h:215:48: note: expanded from macro '__deprecated_msg'

        #define __deprecated_msg(_msg) __attribute__((__deprecated__(_msg)))

                                                      ^

In file included from enzo.C:34:

In file included from ./typedefs.h:16:

./EquilibriumTable.h:5:1: warning: '/*' within block comment [-Wcomment]

/*****************************************/

^

In file included from enzo.C:41:

In file included from ./Grid.h:20:

./AMRH5writer.h:24:10: fatal error: 'hdf5.h' file not found

#include <hdf5.h>

         ^~~~~~~~

2 warnings and 1 error generated.


make: *** [enzo.o] Error 1



I'm trying but this is above my computer knowledge at this time.

Jacob

Jacob Krebs

unread,
Feb 27, 2023, 4:48:59 PM2/27/23
to enzo-dev
As far as I have gotten is the make to compile without that error.but am getting this when I run make:

-e

Updating DEPEND

make: [dep] Error 127 (ignored)

make: [dep] Error 127 (ignored)

make: [dep] Error 127 (ignored)

make: [dep] Error 127 (ignored)

make: [dep] Error 127 (ignored)

make: [dep] Error 127 (ignored)

make: [dep] Error 127 (ignored)

Compiling enzo.C

Compiling MHDLoopInit.C

Compiling Grid_MHDLoopInitGrid.C

Compiling acml_st1.F

Compiling ActiveParticle.C

Compiling ActiveParticleDepositMass.C

Compiling ActiveParticleFinalize.C

Compiling ActiveParticleFindAll.C

Compiling ActiveParticleInitialize.C

Compiling ActiveParticleResetAccelerations.C

Compiling ActiveParticleRoutines.C

Compiling ActiveParticle_AccretingParticle.C

Compiling ActiveParticle_CenOstriker.C

Compiling ActiveParticle_DisableParticle.C

Compiling ActiveParticle_GalaxyParticle.C

Compiling ActiveParticle_Kravtsov.C

Compiling ActiveParticle_MirrorToParticle.C

Compiling ActiveParticle_PopIII.C

Compiling ActiveParticle_RadiationParticle.C

Compiling ActiveParticle_Skeleton.C

Compiling ActiveParticle_SmartStar.C

Compiling ActiveParticle_SphereContained.C

Compiling ActiveParticle_SpringelHernquist.C

Compiling AdiabaticExpansionInitialize.C

Compiling AdjustRefineRegion.C

Compiling AdjustMustRefineParticlesRefineToLevel.C

Compiling AMRH5writer.C

Compiling AnalysisBaseClass.C

Compiling AnalysisBaseClass_HDF5Utils.C

Compiling arccosh.C

Compiling arcsinh.C

Compiling AssignActiveParticlesToGrids.C

Compiling AssignGridToTaskMap.C

Compiling auto_show_config.C

Compiling auto_show_flags.C

Compiling auto_show_version.C

Compiling BlockSolve.F


gfortran  -c -o BlockSolve.o -fno-second-underscore -m64 -g -DLINUX -DH5_USE_16_API   -D__max_subgrids=100000 -D__max_baryons=30 -D__max_cpu_per_node=8 -D__memory_pool_size=100000 -DINITS64 -DLARGE_INTS -DCONFIG_PINT_8 -DIO_32    -DUSE_MPI   -DCONFIG_PFLOAT_8 -DCONFIG_BFLOAT_8  -DUSE_HDF5_GROUPS   -DTRANSFER   -DNEW_GRID_IO -DFAST_SIB      -DENZO_PERFORMANCE    -DUSE_UUID -DSAB BlockSolve.F


BlockSolve.F:1070:11:


 1070 |       NB = ILAENV( 1, 'UGETRF', ' ', M, N, -1, -1 )

      |           1

Error: Type mismatch in argument 'ispec' at (1); passed INTEGER(4) to INTEGER(8)

BlockSolve.F:1070:11:


 1070 |       NB = ILAENV( 1, 'UGETRF', ' ', M, N, -1, -1 )

      |           1

Error: Type mismatch in argument 'n3' at (1); passed INTEGER(4) to INTEGER(8)

BlockSolve.F:1070:11:


 1070 |       NB = ILAENV( 1, 'UGETRF', ' ', M, N, -1, -1 )

      |           1

Error: Type mismatch in argument 'n4' at (1); passed INTEGER(4) to INTEGER(8)

BlockSolve.F:932:30:


  932 |          JP = J - 1 + e_idamax( M-J+1, A( J, J ), 1 )

      |                              1

Error: Type mismatch in argument 'incx' at (1); passed INTEGER(4) to INTEGER(8)

BlockSolve.F:2628:18:


 2628 |          ILAENV = IEEECK( 0, 0._RKIND, 1._RKIND )

      |                  1

Error: Type mismatch in argument 'ispec' at (1); passed INTEGER(4) to INTEGER(8)

BlockSolve.F:2639:18:


 2639 |          ILAENV = IEEECK( 1, 0._RKIND, 1._RKIND )

      |                  1

Error: Type mismatch in argument 'ispec' at (1); passed INTEGER(4) to INTEGER(8)


make: *** [BlockSolve.o] Error 1:



John Wise

unread,
Feb 28, 2023, 10:23:34 AM2/28/23
to enzo...@googlegroups.com
Hi Jacob,

This error can be avoided by providing the option "-std=legacy" to the
MMACH_FFLAGS parameter in the machine file. It's an outstanding issue
(https://github.com/enzo-project/enzo-dev/issues/167) with
incompatibility with legacy code and newer Fortran compilers.

Thanks,
John
> *BlockSolve.F:1070:11:*
>
>
>  1070 |       NB = ILAENV( 1, 'UGETRF', ' ', M, N, -1, -1 )
>
>       | *1*
>
> *Error:* Type mismatch in argument '*ispec*' at *(1)*; passed INTEGER(4)
> to INTEGER(8)
>
> *BlockSolve.F:1070:11:*
>
>
>  1070 |       NB = ILAENV( 1, 'UGETRF', ' ', M, N, -1, -1 )
>
>       | *1*
>
> *Error:* Type mismatch in argument '*n3*' at *(1)*; passed INTEGER(4) to
> INTEGER(8)
>
> *BlockSolve.F:1070:11:*
>
>
>  1070 |       NB = ILAENV( 1, 'UGETRF', ' ', M, N, -1, -1 )
>
>       | *1*
>
> *Error:* Type mismatch in argument '*n4*' at *(1)*; passed INTEGER(4) to
> INTEGER(8)
>
> *BlockSolve.F:932:30:*
>
>
>   932 |          JP = J - 1 + e_idamax( M-J+1, A( J, J ), 1 )
>
>       | *1*
>
> *Error:* Type mismatch in argument '*incx*' at *(1)*; passed INTEGER(4)
> to INTEGER(8)
>
> *BlockSolve.F:2628:18:*
>
>
>  2628 |          ILAENV = IEEECK( 0, 0._RKIND, 1._RKIND )
>
>       | *1*
>
> *Error:* Type mismatch in argument '*ispec*' at *(1)*; passed INTEGER(4)
> to INTEGER(8)
>
> *BlockSolve.F:2639:18:*
>
>
>  2639 |          ILAENV = IEEECK( 1, 0._RKIND, 1._RKIND )
>
>       | *1*
>
> *Error:* Type mismatch in argument '*ispec*' at *(1)*; passed INTEGER(4)
> to INTEGER(8)
>
>
> make: *** [BlockSolve.o] Error 1:
>
>
>
> On Monday, February 27, 2023 at 3:07:36 PM UTC-6 Jacob Krebs wrote:
>
> I appreciate your patience and help John. I changed the make file
> and that error has gone away but now it is back to saying the hdf5.h
> can't be found. Here is the make file, I changed line 44.
>
> Screenshot 2023-02-27 at 3.04.43 PM.png
>
>
>
> -e
>
> Updating DEPEND
>
> make: [dep] Error 127 (ignored)
>
> make: [dep] Error 127 (ignored)
>
> make: [dep] Error 127 (ignored)
>
> make: [dep] Error 127 (ignored)
>
> make: [dep] Error 127 (ignored)
>
> make: [dep] Error 127 (ignored)
>
> make: [dep] Error 127 (ignored)
>
> Compiling enzo.C
>
>
> mpic++  -c -o enzo.o -DLINUX -DH5_USE_16_API
> -D__max_subgrids=100000 -D__max_baryons=30 -D__max_cpu_per_node=8
> -D__memory_pool_size=100000 -DINITS64 -DLARGE_INTS -DCONFIG_PINT_8
> -DIO_32    -DUSE_MPI   -DCONFIG_PFLOAT_8 -DCONFIG_BFLOAT_8
> -DUSE_HDF5_GROUPS   -DTRANSFER   -DNEW_GRID_IO -DFAST_SIB
> -DENZO_PERFORMANCE    -DUSE_UUID -DSAB  -g
> -I/usr/local/Cellar/hdf5/1.12.2_2/include
> -I/Developer/CUDA/common/inc -I/usr/local/include           -I. enzo.C
>
>
> In file included from enzo.C:30:
>
> *./EnzoTiming.h:209:7: **warning: **'sprintf' is deprecated: This
> function is provided for compatibility reasons only.  Due to
> security concerns inherent in the design of sprintf(3), it is highly
> recommended that you use snprintf(3) instead.
> [-Wdeprecated-declarations]*
>
>       sprintf(level_name, "Level_%02d", level);
>
> *      ^*
>
> */Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/stdio.h:188:1: note: *'sprintf' has been explicitly marked deprecated here
>
> __deprecated_msg("This function is provided for compatibility
> reasons only.  Due to security concerns inherent in the design of
> sprintf(3), it is highly recommended that you use snprintf(3) instead.")
>
> *^*
>
> */Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/sys/cdefs.h:215:48: note: *expanded from macro '__deprecated_msg'
>
>         #define __deprecated_msg(_msg)
> __attribute__((__deprecated__(_msg)))
>
> *                                                      ^*
>
> In file included from enzo.C:34:
>
> In file included from ./typedefs.h:16:
>
> *./EquilibriumTable.h:5:1: **warning: **'/*' within block comment
> [-Wcomment]*
>
> /*****************************************/
>
> *^*
>
> In file included from enzo.C:41:
>
> In file included from ./Grid.h:20:
>
> *./AMRH5writer.h:24:10: **fatal error: **'hdf5.h' file not found*
>
> #include <hdf5.h>
>
> *         ^~~~~~~~*
>> clang: *error: **no such file or directory: '/include'; did
>> you mean '-include'?*
>>> *./EnzoTiming.h:209:7: **warning: **'sprintf' is
>>> deprecated: This function is provided for
>>> compatibility reasons only.  Due to security concerns
>>> inherent in the design of sprintf(3), it is highly
>>> recommended that you use snprintf(3) instead.
>>> [-Wdeprecated-declarations]*
>>>
>>>       sprintf(level_name, "Level_%02d", level);
>>>
>>> *      ^*
>>>
>>> */Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/stdio.h:188:1: note: *'sprintf' has been explicitly marked deprecated here
>>>
>>> __deprecated_msg("This function is provided for
>>> compatibility reasons only.  Due to security concerns
>>> inherent in the design of sprintf(3), it is highly
>>> recommended that you use snprintf(3) instead.")
>>>
>>> *^*
>>>
>>> */Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/sys/cdefs.h:215:48: note: *expanded from macro '__deprecated_msg'
>>>
>>>         #define __deprecated_msg(_msg)
>>> __attribute__((__deprecated__(_msg)))
>>>
>>> *        ^*
>>>
>>> In file included from enzo.C:34:
>>>
>>> In file included from ./typedefs.h:16:
>>>
>>> *./EquilibriumTable.h:5:1: **warning: **'/*' within
>>> block comment [-Wcomment]*
>>>
>>> /*****************************************/
>>>
>>> *^*
>>>
>>> In file included from enzo.C:41:
>>>
>>> In file included from ./Grid.h:20:
>>>
>>> *./AMRH5writer.h:24:10: **fatal error: **'hdf5.h'
>>> file not found*
>>>
>>> #include <hdf5.h>
>>>
>>> *         ^~~~~~~~*
>>>
>>> 2 warnings and 1 error generated.
>>>
>>>
>>> make: *** [enzo.o] Error 1
>>>
>>>
>>>
>>> I brew installed hdf5 and that did not resolve the
>>> issue. Anyone have any ideas?
>>>
>>> --
>>> You received this message because you are subscribed
>>> to the Google Groups "enzo-dev" group.
>>> To unsubscribe from this group and stop receiving
>>> emails from it, send an email to
>>> enzo-dev+u...@googlegroups.com.
>>> To view this discussion on the web visit
>>> https://groups.google.com/d/msgid/enzo-dev/547f2b89-be02-459b-977c-1351f3866ecbn%40googlegroups.com <https://groups.google.com/d/msgid/enzo-dev/547f2b89-be02-459b-977c-1351f3866ecbn%40googlegroups.com?utm_medium=email&utm_source=footer>.
>>
>> --
>> John Wise
>> Director, Center for Relativistic Astrophysics
>> Professor, School of Physics
>> Georgia Institute of Technology
>> http://cosmo.gatech.edu <http://cosmo.gatech.edu>
>>
>> --
>> You received this message because you are subscribed to the
>> Google Groups "enzo-dev" group.
>> To unsubscribe from this group and stop receiving emails from
>> it, send an email to enzo-dev+u...@googlegroups.com.
>> To view this discussion on the web visit
>> https://groups.google.com/d/msgid/enzo-dev/10900903-5eed-4c45-bfc0-8cf88d8f34ben%40googlegroups.com <https://groups.google.com/d/msgid/enzo-dev/10900903-5eed-4c45-bfc0-8cf88d8f34ben%40googlegroups.com?utm_medium=email&utm_source=footer>.
>
> --
> John Wise
> Director, Center for Relativistic Astrophysics
> Professor, School of Physics
> Georgia Institute of Technology
> http://cosmo.gatech.edu <http://cosmo.gatech.edu>
>
> --
> You received this message because you are subscribed to the Google
> Groups "enzo-dev" group.
> To unsubscribe from this group and stop receiving emails from it, send
> an email to enzo-dev+u...@googlegroups.com
> <mailto:enzo-dev+u...@googlegroups.com>.
> To view this discussion on the web visit
> https://groups.google.com/d/msgid/enzo-dev/acb76d19-aa9f-453d-a45b-29b3858b7139n%40googlegroups.com <https://groups.google.com/d/msgid/enzo-dev/acb76d19-aa9f-453d-a45b-29b3858b7139n%40googlegroups.com?utm_medium=email&utm_source=footer>.
Reply all
Reply to author
Forward
0 new messages