pkgsrc-Users archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

Applying patches after configuration during bootstrap.



Hello,

Is there a way to continue a bootstrap from where it stops?

# ./bootstrap --full --prefer-pkgsrc=yes

I have patches to devel/m4/patches/ that all apply automatically in

patch-xinuos-m4-1.14.19

It stops with this error.

../lib/libm4.a(asyncsafe-spin.o): In function `asyncsafe_spin_lock':
asyncsafe-spin.c:(.text+0x43): undefined reference to `__atomic_compare_exchange_4'
../lib/libm4.a(asyncsafe-spin.o): In function `asyncsafe_spin_unlock':
asyncsafe-spin.c:(.text+0x6f): undefined reference to `__atomic_compare_exchange_4'
collect2: error: ld returned 1 exit status
*** [m4] Error code 1

I manually edit:

/home/build/pkgsrc/bootstrap/work/wrk/devel/m4/work/m4-1.4.19/src/Makefile

and create this patch

--- Makefile.orig 2021-12-08 10:31:46.486652474 -0700
+++ Makefile      2021-12-08 10:24:20.000000000 -0700
--- m4-1.4.19/src/Makefile.orig 2021-12-08 10:31:46.486652474 -0700
+++ m4-1.4.19/src/Makefile      2021-12-08 10:24:20.000000000 -0700
@@ -302,7 +302,7 @@
 am__v_CC_ = $(am__v_CC_$(AM_DEFAULT_VERBOSITY))
 am__v_CC_0 = @echo "  CC      " $@;
 am__v_CC_1 =
-CCLD = $(CC)
+CCLD = $(CC) -latomic
 LINK = $(CCLD) $(AM_CFLAGS) $(CFLAGS) $(AM_LDFLAGS) $(LDFLAGS) -o $@
 AM_V_CCLD = $(am__v_CCLD_$(V))
 am__v_CCLD_ = $(am__v_CCLD_$(AM_DEFAULT_VERBOSITY))

Is it possible to continue the bootstrap?

# cd /home/build/pkgsrc/bootstrap/work/wrk/devel/m4/work/m4-1.4.19/src/

Patch the file with the -latomic as above run the below I get m4 program.

# /home/build/pkgsrc/bootstrap/work/bmake/bmake

I created devel/m4/patches/patch-xinuos-m4-1.14.19_src_Makefile.diff and tried many combinations of the path to the file like. Also the full path. It appears to be trying to install the patch before the Makefile is created.


How do I patch the resulting Makefile created during bootstrap in

/home/build/pkgsrc/bootstrap/work/wrk/devel/m4/work/m4-1.4.19/src/

I want to automatically use the patch during boostrap after configure has been run and created the Makefile. I have been going through the pkgsrc documenation. I must be missing something.


Regards,

--
Boyd Gerber <gerberb%zenez.com@localhost> 801 849-0213
ZENEZ   1042 East Fort Union #135, Midvale Utah  84047



Home | Main Index | Thread Index | Old Index