updating a port locally how to?

userxbw

Member

Reaction score: 4
Messages: 57

I got a few this one for example that I am already trying to "update" locally, but editing the make files and what other files I find in its dir to use the current version . I did this before, I forget what app it was, it did not work. But I am doing it again.

it is bender, the current one is 2.79b and blender is now 2.8 so I changed the files

Code:
root@FreeBSD64:/usr/ports/graphics/blender # ls
Makefile            distinfo
Makefile.options        distinfo.orginal
Makefile.options.orginal    files
Makefile.orginal        pkg-descr
Makefile.versions        pkg-plist
Makefile.versions.orginal
changing the verion to 2.8
Code:
PORTNAME=    blender
PORTVERSION=    2.8
PORTREVISION=    14
that portversion=14 is that going to be an issue.

and is this even a valid way to get an update?

I remember other one I tried needed an address to the source and i tried giving it a current address to the current version of source and that caused it to fail. I do not remember the particular other than that.

Anyways, what is if there is a correct way to do this, what is it?
 

SirDice

Administrator
Staff member
Administrator
Moderator

Reaction score: 7,672
Messages: 30,574

What I normally do in a situation like this
Code:
pkg install blender
pkg delete blender
This looks like a no-op but the first install will also install all required run dependencies. You then remove only the blender package itself. That way you don't have to build a ton of dependencies too.

In your modified port directory do make missing. You may need to install a few build dependencies first.
Change the version first, then run make makesum. This will download the source code and generate the hash for distfiles.
Run a make patch. This will extract the source and apply any patches from files/ or in the Makefile itself. You may need to fix any patching issues that come up.
Then a loop of make clean and make until you get it to build cleanly, fixing issues as they come up.
mv pkg-plist pkg-plist.orig and run make makeplist > pkg-plist. EDIT pkg-plist! Compare it with the .orig.
 
OP
OP
userxbw

userxbw

Member

Reaction score: 4
Messages: 57

What I normally do in a situation like this
Code:
pkg install blender
pkg delete blender
This looks like a no-op but the first install will also install all required run dependencies. You then remove only the blender package itself. That way you don't have to build a ton of dependencies too.

In your modified port directory do make missing. You may need to install a few build dependencies first.
Change the version first, then run make makesum. This will download the source code and generate the hash for distfiles.
Run a make patch. This will extract the source and apply any patches from files/ or in the Makefile itself. You may need to fix any patching issues that come up.
Then a loop of make clean and make until you get it to build cleanly, fixing issues as they come up.
mv pkg-plist pkg-plist.orig and run make makeplist > pkg-plist. EDIT pkg-plist! Compare it with the .orig.
ok now I am stuck, what am I to write here to get the patch to work?
Code:
root@FreeBSD64:/usr/ports/graphics/blender # cat distinfo
TIMESTAMP = 1565732070
SHA256 (blender-2.80.tar.gz) = cd9d7e505c1f6e63a4f72366ed04d446859977eeb34cde21283aaea6a304a5c0
SIZE (blender-2.80.tar.gz) = 54216321
root@FreeBSD64:/usr/ports/graphics/blender # make patch
===>  Patching for blender-2.80
===>  Applying FreeBSD patches for blender-2.80
File to patch: Makefile
No file found--skip this patch? [n] 
patch: **** can't find Makefile
=> FreeBSD patch patch-ffmpeg4 failed to apply cleanly.
*** Error code 1

Stop.
make[1]: stopped in /usr/ports/graphics/blender
*** Error code 1

Stop.
make: stopped in /usr/ports/graphics/blender
root@FreeBSD64:/usr/ports/graphics/blender # make patch
===>  Patching for blender-2.80
===>  Applying FreeBSD patches for blender-2.80
File to patch: ffmpeg4
No file found--skip this patch? [n] 
patch: **** can't find ffmpeg4
=> FreeBSD patch patch-ffmpeg4 failed to apply cleanly.
*** Error code 1

Stop.
make[1]: stopped in /usr/ports/graphics/blender
*** Error code 1

Stop.
make: stopped in /usr/ports/graphics/blender
 
Top