# # Copyright (c) 2004-2005 rPath, Inc. # This file is distributed under the terms of the MIT License. # A copy is available at http://www.rpath.com/permanent/mit-license.html # loadSuperClass('rpmpackage.recipe') class Nc(RPMPackageRecipe, CPackageRecipe): name = 'nc' version = '1.84' buildRequires = [ 'pkgconfig:devel', 'glib:devel', 'glib:devellib' ] rpmRelease = '4' rpmPatches = [ 'nc-1.84-glib.patch', 'nc-1.78-pollhup.patch', 'nc-1.82-reuseaddr.patch', 'nc-gcc_signess.patch', 'nc-1.84-connect_with_timeout.patch' ] def setup(r): r.unpack() # FIXME: upstream no longer feels the need to include a makefile r.Run('%(cc)s %(cflags)s -Werror `pkg-config --cflags --libs glib-2.0` \ netcat.c atomicio.c socks.c -o %(name)s') r.Install('nc', '%(bindir)s/nc') r.Copy('nc.1', '%(mandir)s/man1/') r.AutoDoc('scripts/')