2014-10-17 10:32:08 -04:00
|
|
|
/* See LICENSE file for copyright and license details. */
|
|
|
|
#include <unistd.h>
|
2014-11-13 12:29:30 -05:00
|
|
|
|
2014-10-17 10:32:08 -04:00
|
|
|
#include "util.h"
|
|
|
|
|
2015-02-28 13:42:26 -05:00
|
|
|
static void
|
|
|
|
usage(void)
|
|
|
|
{
|
|
|
|
eprintf("usage: %s target name\n", argv0);
|
|
|
|
}
|
|
|
|
|
2014-10-17 10:32:08 -04:00
|
|
|
int
|
|
|
|
main(int argc, char *argv[])
|
|
|
|
{
|
2019-06-28 03:18:48 -04:00
|
|
|
ARGBEGIN {
|
|
|
|
default:
|
|
|
|
usage();
|
|
|
|
} ARGEND
|
2014-10-17 10:32:08 -04:00
|
|
|
|
2015-02-28 13:42:26 -05:00
|
|
|
if (argc != 2)
|
|
|
|
usage();
|
2015-02-28 14:05:22 -05:00
|
|
|
|
2015-02-28 13:42:26 -05:00
|
|
|
if (link(argv[0], argv[1]) < 0)
|
2014-10-17 10:32:08 -04:00
|
|
|
eprintf("link:");
|
2015-02-28 13:42:26 -05:00
|
|
|
|
2014-10-17 10:32:08 -04:00
|
|
|
return 0;
|
|
|
|
}
|