giflib: define prefix and libversion also when building (#25263)
This commit is contained in:
parent
2738bc17a1
commit
8c8b934fd8
@ -24,14 +24,24 @@ class Giflib(MakefilePackage, SourceforgePackage):
|
|||||||
|
|
||||||
patch('bsd-head.patch')
|
patch('bsd-head.patch')
|
||||||
|
|
||||||
|
def prefix_and_libversion_args(self):
|
||||||
|
args = []
|
||||||
|
if self.spec.satisfies('@5.2.0:'):
|
||||||
|
args.extend([
|
||||||
|
'PREFIX={0}'.format(self.spec.prefix),
|
||||||
|
'LIBMAJOR={0}'.format(self.spec.version.up_to(1)),
|
||||||
|
'LIBVER={0}'.format(self.spec.version)
|
||||||
|
])
|
||||||
|
return args
|
||||||
|
|
||||||
|
@property
|
||||||
|
def build_targets(self):
|
||||||
|
targets = ['all'] + self.prefix_and_libversion_args()
|
||||||
|
return targets
|
||||||
|
|
||||||
@property
|
@property
|
||||||
def install_targets(self):
|
def install_targets(self):
|
||||||
targets = ['install']
|
targets = ['install'] + self.prefix_and_libversion_args()
|
||||||
if self.spec.satisfies('@5.2.0:'):
|
|
||||||
targets.append('PREFIX={0}'.format(self.spec.prefix))
|
|
||||||
targets.append('LIBMAJOR={0}'.format(self.spec.version.up_to(1)))
|
|
||||||
targets.append('LIBVER={0}'.format(self.spec.version))
|
|
||||||
|
|
||||||
return targets
|
return targets
|
||||||
|
|
||||||
def check(self):
|
def check(self):
|
||||||
|
Loading…
Reference in New Issue
Block a user