File tree Expand file tree Collapse file tree 1 file changed +8
-0
lines changed Expand file tree Collapse file tree 1 file changed +8
-0
lines changed Original file line number Diff line number Diff line change @@ -243,6 +243,12 @@ else
243
243
GLIBC_SRC_GIT :=
244
244
endif
245
245
246
+ ifneq ("$(wildcard $(GCC_SRCDIR ) /.git) ","")
247
+ GCCPKGVER := g$(shell git -C $(GCC_SRCDIR ) describe --always --dirty --exclude '* ')
248
+ else
249
+ GCCPKGVER :=
250
+ endif
251
+
246
252
$(srcdir ) /% /.git :
247
253
cd $(srcdir ) && \
248
254
flock ` git rev-parse --git-dir` /config git submodule init $(dir $@ ) && \
@@ -396,6 +402,7 @@ stamps/build-gcc-linux-stage2: $(GCC_SRCDIR) $(GCC_SRC_GIT) $(addprefix stamps/b
396
402
$(CONFIGURE_HOST) \
397
403
--prefix=$(INSTALL_DIR) \
398
404
--with-sysroot=$(SYSROOT) \
405
+ --with-pkgversion="$(GCCPKGVER)" \
399
406
@with_system_zlib@ \
400
407
--enable-shared \
401
408
--enable-tls \
@@ -621,6 +628,7 @@ stamps/build-gcc-newlib-stage2: $(GCC_SRCDIR) $(GCC_SRC_GIT) stamps/build-newlib
621
628
--disable-shared \
622
629
--disable-threads \
623
630
--enable-languages=c,c++ \
631
+ --with-pkgversion=" $( GCCPKGVER) " \
624
632
@with_system_zlib@ \
625
633
--enable-tls \
626
634
--with-newlib \
You can’t perform that action at this time.
0 commit comments