{"thread":{"id":"12500","subject":"t4109-apply-multifrag.sh problem on solaris -- looks like problem w/ solaris patch cmd","startedAt":"2008-03-04T16:22:58Z","lastAt":"2008-03-04T19:32:20Z","messageCount":2,"participants":["Whit Armstrong","Junio C Hamano"],"isPatch":false,"patchVersion":null,"patchTotal":null},"messages":[{"id":"70974","messageId":"8ec76080803040822n5e463b50sff6639777246de7b@mail.gmail.com","threadId":"12500","inReplyTo":null,"subject":"t4109-apply-multifrag.sh problem on solaris -- looks like problem w/ solaris patch cmd","fromName":"Whit Armstrong","fromEmail":"armstrong.whit@gmail.com","sentAt":"2008-03-04T16:22:58Z","receivedAt":"2008-03-04T16:22:58Z","isPatch":false,"sender":{"key":"armstrong.whit@gmail.com","avatar":"https://gravatar.com/avatar/3977f2e287db4d4de47839714313edee1222fa9d68677e1de922ec243da4b77d?d=mp&s=160"},"body":"using git current: c95b3ad9ea310ec89e31a21edecaaf2c374e2c46\n\nxs5-trd-p1.grn:warmstro> sh t4109-apply-multifrag.sh -v -i\n* expecting success: git apply patch1.patch patch2.patch\n*   ok 1: S = git apply (1)\n\n* expecting success: cat patch1.patch patch2.patch | patch -p1\n  Looks like a unified context diff.\nFile to patch: ^CFATAL: Unexpected exit with code 3\nxs5-trd-p1.grn:warmstro> sh t4109-apply-multifrag.sh -i -v\n* expecting success: git apply patch1.patch patch2.patch\n*   ok 1: S = git apply (1)\n\n* expecting success: cat patch1.patch patch2.patch | patch -p1\n  Looks like a unified context diff.\nFile to patch: ^CFATAL: Unexpected exit with code 3\nxs5-trd-p1.grn:warmstro>\n\nthe test just hangs at \"File to patch:\" and I have to C^ to exit.\n\nand that's exactly what I get executing the patch command myself:\n\nxs5-trd-p1.grn:warmstro> cd trash/\nxs5-trd-p1.grn:warmstro> cat patch1.patch patch4.patch | patch -p1\n  Looks like a unified context diff.\nFile to patch:\nNo file found -- skip this patch? [no]\nFile to patch:\nNo file found -- skip this patch? [no] yes\nSkipping patch...\n  The next patch looks like a unified context diff.\nFile to patch: ^Cxs5-trd-p1.grn:warmstro>\nxs5-trd-p1.grn:warmstro>\n\n\nbut with GNU patch-2.5.4 the test works (not sure what the failure is\nat the end, but it looks like all the individual tests pass):\n\n\nxs5-trd-p1.grn:warmstro> sh t4109-apply-multifrag.sh -i -v\n* expecting success: git apply patch1.patch patch2.patch\n*   ok 1: S = git apply (1)\n\n* expecting success: cat patch1.patch patch2.patch | patch -p1\npatching file main.c\npatching file main.c\n*   ok 2: S = patch (1)\n\n* expecting success: cmp main.c.git main.c\n*   ok 3: S = cmp (1)\n\n* expecting success: git apply patch1.patch patch2.patch patch3.patch\n*   ok 4: S = git apply (2)\n\n* expecting success: cat patch1.patch patch2.patch patch3.patch | patch -p1\npatching file main.c\npatching file main.c\npatching file main.c\n*   ok 5: S = patch (2)\n\n* expecting success: cmp main.c.git main.c\n*   ok 6: S = cmp (2)\n\n* expecting success: git apply patch1.patch patch4.patch\n*   ok 7: S = git apply (3)\n\n* expecting success: cat patch1.patch patch4.patch | patch -p1\npatching file main.c\npatching file main.c\n*   ok 8: S = patch (3)\n\n* expecting success: cmp main.c.git main.c\n*   ok 9: S = cmp (3)\n\n* passed all 9 test(s)\nFATAL: Unexpected exit with code 0\nxs5-trd-p1.grn:warmstro>\n\n\nAgain, this is on a Solaris 5.9 machine:\nxs5-trd-p1.grn:warmstro> uname -a\nSunOS xs5-trd-p1.grn.tudor.com 5.9 Generic_118558-38 sun4u sparc\nSUNW,Sun-Fire-V240 Solaris\nxs5-trd-p1.grn:warmstro>\n\nIs the answer to use GNU patch? Or is there a trick to make the\nSolaris version of patch work?\n\nThanks,\nWhit\n"},{"id":"70986","messageId":"7v3ar670aj.fsf@gitster.siamese.dyndns.org","threadId":"12500","inReplyTo":"8ec76080803040822n5e463b50sff6639777246de7b@mail.gmail.com","subject":"Re: t4109-apply-multifrag.sh problem on solaris -- looks like problem w/ solaris patch cmd","fromName":"Junio C Hamano","fromEmail":"gitster@pobox.com","sentAt":"2008-03-04T19:32:20Z","receivedAt":"2008-03-04T19:32:20Z","isPatch":false,"sender":{"key":"gitster@pobox.com","avatar":"https://avatars.githubusercontent.com/u/54884?v=4"},"body":"\"Whit Armstrong\" <armstrong.whit@gmail.com> writes:\n\n> * expecting success: git apply patch1.patch patch2.patch patch3.patch\n> *   ok 4: S = git apply (2)\n>\n> * expecting success: cat patch1.patch patch2.patch patch3.patch | patch -p1\n> patching file main.c\n> patching file main.c\n> patching file main.c\n> *   ok 5: S = patch (2)\n> ...\n>\n> Is the answer to use GNU patch? Or is there a trick to make the\n> Solaris version of patch work?\n\nIf we are reasonably sure that we will not be needing to change these test\nvectors (and because \"git apply\" is now solid, I think we are), I think\nthe best way to address this is to prepare a new t/t4109 directory, store\nthe expected output in there, and compare output from \"git apply\" that is\nbeing tested with the precomputed test vectors.\n\n\n"}]}