> On 19 Oct 2021, at 6:03 PM, Mark Adams <[email protected]> wrote:
> 
> Matt, (cc'ing Matt M.).
> Thanks, that looks pretty straight forward.
> 
> Matt M: I'm not very familiar with the configuration system. It might be best 
> for you to ask questions directly instead of me hacking this up.
> 
> mmg.py (appended) and AMReX.py are in 
> petsc/config/BuildSystem/config/packages. I'm guessing it will be easiest to 
> prune and clone AMReX.py (150 LOC)

I’d advise _not_ to use AMReX.py, as it is one of those weird packages that 
have self.builtafterpetsc = 1, and thus require a lot of unneeded LOC that you 
shouldn’t need for AMGx.
mmg.py has probably one of the lightest configure script indeed, alongside 
eigen.py (you’ll see they look similar, there is just the bare minimum).

Thanks,
Pierre

> I have rebased the branch over main and am testing it now.
> 
> Thanks,
> Mark
> 
> import config.package
> import os
> 
> class Configure(config.package.CMakePackage):
>   def __init__(self, framework):
>     config.package.CMakePackage.__init__(self, framework)
>     self.gitcommit        = '5fc1b2c76fe1d6787387f5c9600759d4cbf26a88' # 
> jolivet/feature-mmg-install-3.16.0 sep-29-2021
>     self.download         = ['git://https://github.com/prj-/mmg.git 
> <https://github.com/prj-/mmg.git>','https://github.com/prj-/mmg/archive/'+self.gitcommit+'.tar.gz
>  <https://github.com/prj-/mmg/archive/'+self.gitcommit+'.tar.gz>']
>     self.versionname      = 'MMG_VERSION_RELEASE'
>     self.includes         = ['mmg/libmmg.h']
>     self.liblist          = [['libmmg.a','libmmg3d.a']]
>     self.functions        = ['MMG5_paramUsage1']
>     self.precisions       = ['double']
>     return
> 
>   def setupDependencies(self, framework):
>     config.package.CMakePackage.setupDependencies(self, framework)
>     self.externalpackagesdir = 
> framework.require('PETSc.options.externalpackagesdir',self)
>     self.compilerFlags = framework.require('config.compilerFlags',self)
>     self.mathlib       = framework.require('config.packages.mathlib',self)
>     self.ptscotch      = framework.require('config.packages.PTScotch',self)
>     self.deps          = [self.mathlib,self.ptscotch]
>     return
> 
>   def formCMakeConfigureArgs(self):
>     args = config.package.CMakePackage.formCMakeConfigureArgs(self)
>     args.append('-DUSE_ELAS=OFF')
>     args.append('-DUSE_VTK=OFF')
>     args.append('-DUSE_POINTMAP=ON')
>     args.append('-DSCOTCH_DIR:STRING="'+self.ptscotch.directory+'"')
>     return args
> 
>   def configureLibrary(self):
>     config.package.CMakePackage.configureLibrary(self)
> 
> 
> On Tue, Oct 19, 2021 at 9:34 AM Matthew Knepley <[email protected] 
> <mailto:[email protected]>> wrote:
> On Tue, Oct 19, 2021 at 9:32 AM Mark Adams <[email protected] 
> <mailto:[email protected]>> wrote:
> cmake
> 
> barf. Clone one of those, like mmg.py or AMReX.py
> 
>   Thanks,
> 
>     Matt
>  
> On Tue, Oct 19, 2021 at 9:26 AM Matthew Knepley <[email protected] 
> <mailto:[email protected]>> wrote:
> On Tue, Oct 19, 2021 at 8:17 AM Mark Adams <[email protected] 
> <mailto:[email protected]>> wrote:
> We (Matt Martineau and I) are ready to work on the AMGx integration and I 
> want to start by getting the AMGx download working.
> 
> I'm looking for advice on how to proceed.
> 
> Should I look at a simple example and clone it?
> 
> What build system does it use?
> 
>   Thanks,
> 
>     Matt
>  
> Thanks,
> Mark
> 
> 
> 
> -- 
> What most experimenters take for granted before they begin their experiments 
> is infinitely more interesting than any results to which their experiments 
> lead.
> -- Norbert Wiener
> 
> https://www.cse.buffalo.edu/~knepley/ <http://www.cse.buffalo.edu/~knepley/>
> 
> 
> -- 
> What most experimenters take for granted before they begin their experiments 
> is infinitely more interesting than any results to which their experiments 
> lead.
> -- Norbert Wiener
> 
> https://www.cse.buffalo.edu/~knepley/ <http://www.cse.buffalo.edu/~knepley/>

Reply via email to