Forums

Skip to content

Advanced search
  • Quick links
    • Unanswered topics
    • Active topics
    • Search
  • FAQ
  • Login
  • Register
  • Board index Assistance Portage & Programming
  • Search

Creating an ebuild for an inactive Github repository

Problems with emerge or ebuilds? Have a basic programming question about C, PHP, Perl, BASH or something else?
Post Reply
Advanced search
11 posts • Page 1 of 1
Author
Message
tenkuusaru
n00b
n00b
Posts: 5
Joined: Fri Mar 27, 2026 11:45 am

Creating an ebuild for an inactive Github repository

  • Quote

Post by tenkuusaru » Fri Mar 27, 2026 7:50 pm

Hi all,

I am looking to create an ebuild and package for Portage to manage a window manager I would like to use on my Gentoo install (this package does not currently exist anywhere when searching the gpo). I have not ever used ebuilds or anything like it, so I am a little lost (though thank you to sam_ for the help I received on the IRC).

The repository in question is here and I have managed to get something of an ebuild going by using the guide here and grabbing a snapshot using the last commit to the repository.

I then followed the guide here, using my own 'local' repo in /var/db/repos.

Running the following command as root seems to work and create a Manifest.

Code: Select all

# GENTOO_MIRRORS="" ebuild ./scrub-2.6.1.ebuild manifest clean unpack
When it comes to running the test install, however, I receive an error.

Code: Select all

# ebuild progman-1_p20260326.ebuild clean test install
The build.log is available below. I believe the issue is something to do with how the Makefile from the Github repository calls gdk-pixbuf but I am very new to this and so am not really familiar with either the Makefile or how to fix this in the ebuild.

Code: Select all

[32m * [39;49;00mPackage:    x11-wm/progman-1_p20260326:0
[32m * [39;49;00mRepository: local
[32m * [39;49;00mUSE:        abi_x86_64 amd64 elibc_glibc kernel_linux
[32m * [39;49;00mFEATURES:   network-sandbox preserve-libs sandbox test userpriv usersandbox
[32m * [39;49;00mPackage:    x11-wm/progman-1_p20260326:0
[32m * [39;49;00mRepository: local
[32m * [39;49;00mUSE:        abi_x86_64 amd64 elibc_glibc kernel_linux
[32m * [39;49;00mFEATURES:   network-sandbox preserve-libs sandbox test userpriv usersandbox
>>> Unpacking source...
>>> Unpacking 'dba2dc691b97a182d233412f022de4643ca83eae.tar.gz' to /var/tmp/portage/x11-wm/progman-1_p20260326/work
>>> Source unpacked in /var/tmp/portage/x11-wm/progman-1_p20260326/work
>>> Preparing source in /var/tmp/portage/x11-wm/progman-1_p20260326/work/progman-dba2dc691b97a182d233412f022de4643ca83eae ...
>>> Source prepared.
>>> Configuring source in /var/tmp/portage/x11-wm/progman-1_p20260326/work/progman-dba2dc691b97a182d233412f022de4643ca83eae ...
>>> Source configured.
>>> Compiling source in /var/tmp/portage/x11-wm/progman-1_p20260326/work/progman-dba2dc691b97a182d233412f022de4643ca83eae ...
make -j8 
xxd -i progman.ini > progman_ini.h || (rm -f progman_ini.h; exit 1)
cc -march=skylake -O2 -pipe -O2 -Wall -Wunused -Wunused -Wmissing-prototypes -Wstrict-prototypes -Wpointer-sign `pkg-config --cflags x11 xft xext xpm gdk-pixbuf-xlib-2.0` -DUSE_GDK_PIXBUF -g   -c -o atom.o atom.c
Package gdk-pixbuf-xlib-2.0 was not found in the pkg-config search path.
Perhaps you should add the directory containing `gdk-pixbuf-xlib-2.0.pc'
to the PKG_CONFIG_PATH environment variable
Package 'gdk-pixbuf-xlib-2.0' not found
In file included from progman.h:27,
                 from atom.c:28:
/usr/include/X11/Xft/Xft.h:40:10: fatal error: ft2build.h: No such file or directory
   40 | #include <ft2build.h>
      |          ^~~~~~~~~~~~
compilation terminated.
make: *** [<builtin>: atom.o] Error 1
make: *** Waiting for unfinished jobs....
cc -march=skylake -O2 -pipe -O2 -Wall -Wunused -Wunused -Wmissing-prototypes -Wstrict-prototypes -Wpointer-sign `pkg-config --cflags x11 xft xext xpm gdk-pixbuf-xlib-2.0` -DUSE_GDK_PIXBUF -g   -c -o manage.o manage.c
Package gdk-pixbuf-xlib-2.0 was not found in the pkg-config search path.
Perhaps you should add the directory containing `gdk-pixbuf-xlib-2.0.pc'
to the PKG_CONFIG_PATH environment variable
Package 'gdk-pixbuf-xlib-2.0' not found
In file included from progman.h:27,
                 from manage.c:31:
/usr/include/X11/Xft/Xft.h:40:10: fatal error: ft2build.h: No such file or directory
   40 | #include <ft2build.h>
      |          ^~~~~~~~~~~~
compilation terminated.
make: *** [<builtin>: manage.o] Error 1
cc -march=skylake -O2 -pipe -O2 -Wall -Wunused -Wunused -Wmissing-prototypes -Wstrict-prototypes -Wpointer-sign `pkg-config --cflags x11 xft xext xpm gdk-pixbuf-xlib-2.0` -DUSE_GDK_PIXBUF -g   -c -o client.o client.c
Package gdk-pixbuf-xlib-2.0 was not found in the pkg-config search path.
Perhaps you should add the directory containing `gdk-pixbuf-xlib-2.0.pc'
to the PKG_CONFIG_PATH environment variable
Package 'gdk-pixbuf-xlib-2.0' not found
client.c:32:10: fatal error: gdk-pixbuf-xlib/gdk-pixbuf-xlib.h: No such file or directory
   32 | #include <gdk-pixbuf-xlib/gdk-pixbuf-xlib.h>
      |          ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
compilation terminated.
make: *** [<builtin>: client.o] Error 1
cc -march=skylake -O2 -pipe -O2 -Wall -Wunused -Wunused -Wmissing-prototypes -Wstrict-prototypes -Wpointer-sign `pkg-config --cflags x11 xft xext xpm gdk-pixbuf-xlib-2.0` -DUSE_GDK_PIXBUF -g   -c -o keyboard.o keyboard.c
Package gdk-pixbuf-xlib-2.0 was not found in the pkg-config search path.
Perhaps you should add the directory containing `gdk-pixbuf-xlib-2.0.pc'
to the PKG_CONFIG_PATH environment variable
Package 'gdk-pixbuf-xlib-2.0' not found
In file included from progman.h:27,
                 from keyboard.c:28:
/usr/include/X11/Xft/Xft.h:40:10: fatal error: ft2build.h: No such file or directory
   40 | #include <ft2build.h>
      |          ^~~~~~~~~~~~
compilation terminated.
make: *** [<builtin>: keyboard.o] Error 1
cc -march=skylake -O2 -pipe -O2 -Wall -Wunused -Wunused -Wmissing-prototypes -Wstrict-prototypes -Wpointer-sign `pkg-config --cflags x11 xft xext xpm gdk-pixbuf-xlib-2.0` -DUSE_GDK_PIXBUF -g   -c -o launcher.o launcher.c
Package gdk-pixbuf-xlib-2.0 was not found in the pkg-config search path.
Perhaps you should add the directory containing `gdk-pixbuf-xlib-2.0.pc'
to the PKG_CONFIG_PATH environment variable
Package 'gdk-pixbuf-xlib-2.0' not found
In file included from progman.h:27,
                 from launcher.c:25:
/usr/include/X11/Xft/Xft.h:40:10: fatal error: ft2build.h: No such file or directory
   40 | #include <ft2build.h>
      |          ^~~~~~~~~~~~
compilation terminated.
make: *** [<builtin>: launcher.o] Error 1
cc -march=skylake -O2 -pipe -O2 -Wall -Wunused -Wunused -Wmissing-prototypes -Wstrict-prototypes -Wpointer-sign `pkg-config --cflags x11 xft xext xpm gdk-pixbuf-xlib-2.0` -DUSE_GDK_PIXBUF -g   -c -o events.o events.c
Package gdk-pixbuf-xlib-2.0 was not found in the pkg-config search path.
Perhaps you should add the directory containing `gdk-pixbuf-xlib-2.0.pc'
to the PKG_CONFIG_PATH environment variable
Package 'gdk-pixbuf-xlib-2.0' not found
In file included from progman.h:27,
                 from events.c:28:
/usr/include/X11/Xft/Xft.h:40:10: fatal error: ft2build.h: No such file or directory
   40 | #include <ft2build.h>
      |          ^~~~~~~~~~~~
compilation terminated.
make: *** [<builtin>: events.o] Error 1
cc -march=skylake -O2 -pipe -O2 -Wall -Wunused -Wunused -Wmissing-prototypes -Wstrict-prototypes -Wpointer-sign `pkg-config --cflags x11 xft xext xpm gdk-pixbuf-xlib-2.0` -DUSE_GDK_PIXBUF -g   -c -o progman.o progman.c
Package gdk-pixbuf-xlib-2.0 was not found in the pkg-config search path.
Perhaps you should add the directory containing `gdk-pixbuf-xlib-2.0.pc'
to the PKG_CONFIG_PATH environment variable
Package 'gdk-pixbuf-xlib-2.0' not found
progman.c:41:10: fatal error: gdk-pixbuf-xlib/gdk-pixbuf-xlib.h: No such file or directory
   41 | #include <gdk-pixbuf-xlib/gdk-pixbuf-xlib.h>
      |          ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
compilation terminated.
make: *** [<builtin>: progman.o] Error 1
 [31;01m*[0m ERROR: x11-wm/progman-1_p20260326::local failed (compile phase):
 [31;01m*[0m   emake failed
 [31;01m*[0m 
 [31;01m*[0m If you need support, post the output of `emerge --info '=x11-wm/progman-1_p20260326::local'`,
 [31;01m*[0m the complete build log and the output of `emerge -pqv '=x11-wm/progman-1_p20260326::local'`.
 [31;01m*[0m The complete build log is located at '/var/tmp/portage/x11-wm/progman-1_p20260326/temp/build.log'.
 [31;01m*[0m The ebuild environment file is located at '/var/tmp/portage/x11-wm/progman-1_p20260326/temp/environment'.
 [31;01m*[0m Working directory: '/var/tmp/portage/x11-wm/progman-1_p20260326/work/progman-dba2dc691b97a182d233412f022de4643ca83eae'
 [31;01m*[0m S: '/var/tmp/portage/x11-wm/progman-1_p20260326/work/progman-dba2dc691b97a182d233412f022de4643ca83eae'
Also available here. To be sure, I have installed both freetype and gdk-pixbuf (as binaries) on the system, but still yield the same error above.

Any help would be greatly appreciated, thank you.
Top
grknight
Retired Dev
Retired Dev
Posts: 2564
Joined: Fri Feb 20, 2015 9:36 pm

  • Quote

Post by grknight » Fri Mar 27, 2026 8:08 pm

Needs x11-libs/gdk-pixbuf-xlib as a dependency installed first (and possibly other things). If you specify it in the ebuild, then emerge --onlydeps x11-wm/progman would install it for testing.
Top
tenkuusaru
n00b
n00b
Posts: 5
Joined: Fri Mar 27, 2026 11:45 am

  • Quote

Post by tenkuusaru » Fri Mar 27, 2026 8:19 pm

grknight wrote:Needs x11-libs/gdk-pixbuf-xlib as a dependency installed first (and possibly other things). If you specify it in the ebuild, then emerge --onlydeps x11-wm/progman would install it for testing.
Thank you for this! I installed this package just now (as a binary) and must have confused a similarly named package earlier, thinking it had been installed. Now the test phase runs but it unfortunately fails in the install phase due to 'ACCESS DENIED', though I did su to root when running the command. sam_ did mention there may be an issue with how the Makefile installs and that I would need to make changes to the src_install DESTDIR but I am not quite sure exactly where the install should instead go from the wiki article, if you could please point me in the correct direction? I have provided my build.log below.

Code: Select all

[32m * [39;49;00mPackage:    x11-wm/progman-1_p20260326:0
[32m * [39;49;00mRepository: local
[32m * [39;49;00mUSE:        abi_x86_64 amd64 elibc_glibc kernel_linux
[32m * [39;49;00mFEATURES:   network-sandbox preserve-libs sandbox test userpriv usersandbox
[32m * [39;49;00mPackage:    x11-wm/progman-1_p20260326:0
[32m * [39;49;00mRepository: local
[32m * [39;49;00mUSE:        abi_x86_64 amd64 elibc_glibc kernel_linux
[32m * [39;49;00mFEATURES:   network-sandbox preserve-libs sandbox test userpriv usersandbox
>>> Unpacking source...
>>> Unpacking 'dba2dc691b97a182d233412f022de4643ca83eae.tar.gz' to /var/tmp/portage/x11-wm/progman-1_p20260326/work
>>> Source unpacked in /var/tmp/portage/x11-wm/progman-1_p20260326/work
>>> Preparing source in /var/tmp/portage/x11-wm/progman-1_p20260326/work/progman-dba2dc691b97a182d233412f022de4643ca83eae ...
>>> Source prepared.
>>> Configuring source in /var/tmp/portage/x11-wm/progman-1_p20260326/work/progman-dba2dc691b97a182d233412f022de4643ca83eae ...
>>> Source configured.
>>> Compiling source in /var/tmp/portage/x11-wm/progman-1_p20260326/work/progman-dba2dc691b97a182d233412f022de4643ca83eae ...
make -j8 
xxd -i progman.ini > progman_ini.h || (rm -f progman_ini.h; exit 1)
cc -march=skylake -O2 -pipe -O2 -Wall -Wunused -Wunused -Wmissing-prototypes -Wstrict-prototypes -Wpointer-sign `pkg-config --cflags x11 xft xext xpm gdk-pixbuf-xlib-2.0` -DUSE_GDK_PIXBUF -g   -c -o keyboard.o keyboard.c
cc -march=skylake -O2 -pipe -O2 -Wall -Wunused -Wunused -Wmissing-prototypes -Wstrict-prototypes -Wpointer-sign `pkg-config --cflags x11 xft xext xpm gdk-pixbuf-xlib-2.0` -DUSE_GDK_PIXBUF -g   -c -o launcher.o launcher.c
cc -march=skylake -O2 -pipe -O2 -Wall -Wunused -Wunused -Wmissing-prototypes -Wstrict-prototypes -Wpointer-sign `pkg-config --cflags x11 xft xext xpm gdk-pixbuf-xlib-2.0` -DUSE_GDK_PIXBUF -g   -c -o atom.o atom.c
cc -march=skylake -O2 -pipe -O2 -Wall -Wunused -Wunused -Wmissing-prototypes -Wstrict-prototypes -Wpointer-sign `pkg-config --cflags x11 xft xext xpm gdk-pixbuf-xlib-2.0` -DUSE_GDK_PIXBUF -g   -c -o events.o events.c
cc -march=skylake -O2 -pipe -O2 -Wall -Wunused -Wunused -Wmissing-prototypes -Wstrict-prototypes -Wpointer-sign `pkg-config --cflags x11 xft xext xpm gdk-pixbuf-xlib-2.0` -DUSE_GDK_PIXBUF -g   -c -o util.o util.c
cc -march=skylake -O2 -pipe -O2 -Wall -Wunused -Wunused -Wmissing-prototypes -Wstrict-prototypes -Wpointer-sign `pkg-config --cflags x11 xft xext xpm gdk-pixbuf-xlib-2.0` -DUSE_GDK_PIXBUF -g   -c -o parser.o parser.c
cc -march=skylake -O2 -pipe -O2 -Wall -Wunused -Wunused -Wmissing-prototypes -Wstrict-prototypes -Wpointer-sign `pkg-config --cflags x11 xft xext xpm gdk-pixbuf-xlib-2.0` -DUSE_GDK_PIXBUF -g   -c -o progman.o progman.c
cc -march=skylake -O2 -pipe -O2 -Wall -Wunused -Wunused -Wmissing-prototypes -Wstrict-prototypes -Wpointer-sign `pkg-config --cflags x11 xft xext xpm gdk-pixbuf-xlib-2.0` -DUSE_GDK_PIXBUF -g   -c -o manage.o manage.c
cc -march=skylake -O2 -pipe -O2 -Wall -Wunused -Wunused -Wmissing-prototypes -Wstrict-prototypes -Wpointer-sign `pkg-config --cflags x11 xft xext xpm gdk-pixbuf-xlib-2.0` -DUSE_GDK_PIXBUF -g   -c -o client.o client.c
cc -o progman atom.o client.o events.o keyboard.o launcher.o manage.o parser.o progman.o util.o -Wl,-O1 -Wl,--as-needed -Wl,-z,pack-relative-relocs `pkg-config --libs x11 xft xext xpm gdk-pixbuf-xlib-2.0`
>>> Source compiled.
>>> Test phase: x11-wm/progman-1_p20260326
>>> Completed testing x11-wm/progman-1_p20260326

>>> Install x11-wm/progman-1_p20260326 into /var/tmp/portage/x11-wm/progman-1_p20260326/image
make -j8 DESTDIR=/var/tmp/portage/x11-wm/progman-1_p20260326/image install 
mkdir -p /usr/local/bin 
 [31;01m*[0m [31;01mACCESS DENIED[0m:  open_wr_creat:      /usr/local/bin/progman
install -s progman /usr/local/bin
install: cannot create regular file '/usr/local/bin/progman': Permission denied
make: *** [Makefile:73: install] Error 1
 [31;01m*[0m ERROR: x11-wm/progman-1_p20260326::local failed (install phase):
 [31;01m*[0m   emake failed
 [31;01m*[0m 
 [31;01m*[0m If you need support, post the output of `emerge --info '=x11-wm/progman-1_p20260326::local'`,
 [31;01m*[0m the complete build log and the output of `emerge -pqv '=x11-wm/progman-1_p20260326::local'`.
 [31;01m*[0m The complete build log is located at '/var/tmp/portage/x11-wm/progman-1_p20260326/temp/build.log'.
 [31;01m*[0m The ebuild environment file is located at '/var/tmp/portage/x11-wm/progman-1_p20260326/temp/environment'.
 [31;01m*[0m Working directory: '/var/tmp/portage/x11-wm/progman-1_p20260326/work/progman-dba2dc691b97a182d233412f022de4643ca83eae'
 [31;01m*[0m S: '/var/tmp/portage/x11-wm/progman-1_p20260326/work/progman-dba2dc691b97a182d233412f022de4643ca83eae'
 [31;01m*[0m ----------------------- SANDBOX ACCESS VIOLATION SUMMARY -----------------------
 [31;01m*[0m LOG FILE: "/var/tmp/portage/x11-wm/progman-1_p20260326/temp/sandbox.log"
 [31;01m*[0m 
VERSION 1.0
FORMAT: F - Function called
FORMAT: S - Access Status
FORMAT: P - Path as passed to function
FORMAT: A - Absolute Path (not canonical)
FORMAT: R - Canonical Path
FORMAT: C - Command Line

F: open_wr_creat
S: deny
P: progman
A: /usr/local/bin/progman
R: /usr/local/bin/progman
C: /usr/bin/install -s progman /usr/local/bin 
 [31;01m*[0m --------------------------------------------------------------------------------
Also available here. Thank you again for your help.
Top
Hu
Administrator
Administrator
Posts: 24395
Joined: Tue Mar 06, 2007 5:38 am

  • Quote

Post by Hu » Fri Mar 27, 2026 9:10 pm

As I read the upstream Makefile, the install target has two very common defects, each of which make it unsuitable for you to use. Fortunately, the Makefile is so simple that you could skip invoking make install and instead have the ebuild's src_install do the equivalent work correctly. The only thing make install does is create two directories (one of which it then does not use), and copy (with stripping) the built program into BINDIR. For an ebuild, you want those directories to be under $D (and the Makefile does not provide a clean way to do so), and you want not to strip the built program. See DevManual: Trivial Installs for an example of how to do this without using the upstream Makefile. Post back if you need more specific guidance.
Top
grknight
Retired Dev
Retired Dev
Posts: 2564
Joined: Fri Feb 20, 2015 9:36 pm

  • Quote

Post by grknight » Fri Mar 27, 2026 9:55 pm

In addition, I would suggest adding tc-export CC from the toolchain-funcs eclass before make is invoked so that the correct CC binary is called and not a generic.
Top
tenkuusaru
n00b
n00b
Posts: 5
Joined: Fri Mar 27, 2026 11:45 am

  • Quote

Post by tenkuusaru » Fri Mar 27, 2026 9:57 pm

Hu wrote:As I read the upstream Makefile, the install target has two very common defects, each of which make it unsuitable for you to use. Fortunately, the Makefile is so simple that you could skip invoking make install and instead have the ebuild's src_install do the equivalent work correctly. The only thing make install does is create two directories (one of which it then does not use), and copy (with stripping) the built program into BINDIR. For an ebuild, you want those directories to be under $D (and the Makefile does not provide a clean way to do so), and you want not to strip the built program. See DevManual: Trivial Installs for an example of how to do this without using the upstream Makefile. Post back if you need more specific guidance.
Hi Hu, thank you very much for this, it is really helpful! Seeing the BINDIR in the Makefile appears to be /usr/local/bin, I have amended my ebuild accordingly to be as follows.

Code: Select all

# Copyright 2026 Gentoo Authors
# Distributed under the terms of the GNU General Public License v2

EAPI=8

PROGMAN_COMMIT="dba2dc691b97a182d233412f022de4643ca83eae"

DESCRIPTION="progman is a simple X11 window manager modelled after the Windows 3 era."
HOMEPAGE="https://github.com/jcs/progman"
SRC_URI="https://github.com/jcs/progman/archive/${PROGMAN_COMMIT}.tar.gz"
S="${WORKDIR}/${PN}-${PROGMAN_COMMIT}"

LICENSE="MIT"
SLOT="0"
KEYWORDS="~amd64"

DEPEND="x11-libs/gdk-pixbuf
media-libs/freetype"
RDEPEND="${DEPEND}"
BDEPEND=""

src_install() {
dodir /usr/local/bin/progman
cp -R "${S}/" "${D}/" || die "install failed!"
}
Also available here.

This seems to work! As in, the install phase passes, but I do get a QA notice in the build.log, posted below.

Code: Select all

[32m * [39;49;00mPackage:    x11-wm/progman-1_p20260326:0
[32m * [39;49;00mRepository: local
[32m * [39;49;00mUSE:        abi_x86_64 amd64 elibc_glibc kernel_linux
[32m * [39;49;00mFEATURES:   network-sandbox preserve-libs sandbox test userpriv usersandbox
[32m * [39;49;00mPackage:    x11-wm/progman-1_p20260326:0
[32m * [39;49;00mRepository: local
[32m * [39;49;00mUSE:        abi_x86_64 amd64 elibc_glibc kernel_linux
[32m * [39;49;00mFEATURES:   network-sandbox preserve-libs sandbox test userpriv usersandbox
>>> Unpacking source...
>>> Unpacking 'dba2dc691b97a182d233412f022de4643ca83eae.tar.gz' to /var/tmp/portage/x11-wm/progman-1_p20260326/work
>>> Source unpacked in /var/tmp/portage/x11-wm/progman-1_p20260326/work
>>> Preparing source in /var/tmp/portage/x11-wm/progman-1_p20260326/work/progman-dba2dc691b97a182d233412f022de4643ca83eae ...
>>> Source prepared.
>>> Configuring source in /var/tmp/portage/x11-wm/progman-1_p20260326/work/progman-dba2dc691b97a182d233412f022de4643ca83eae ...
>>> Source configured.
>>> Compiling source in /var/tmp/portage/x11-wm/progman-1_p20260326/work/progman-dba2dc691b97a182d233412f022de4643ca83eae ...
make -j8 
xxd -i progman.ini > progman_ini.h || (rm -f progman_ini.h; exit 1)
cc -march=skylake -O2 -pipe -O2 -Wall -Wunused -Wunused -Wmissing-prototypes -Wstrict-prototypes -Wpointer-sign `pkg-config --cflags x11 xft xext xpm gdk-pixbuf-xlib-2.0` -DUSE_GDK_PIXBUF -g   -c -o launcher.o launcher.c
cc -march=skylake -O2 -pipe -O2 -Wall -Wunused -Wunused -Wmissing-prototypes -Wstrict-prototypes -Wpointer-sign `pkg-config --cflags x11 xft xext xpm gdk-pixbuf-xlib-2.0` -DUSE_GDK_PIXBUF -g   -c -o keyboard.o keyboard.c
cc -march=skylake -O2 -pipe -O2 -Wall -Wunused -Wunused -Wmissing-prototypes -Wstrict-prototypes -Wpointer-sign `pkg-config --cflags x11 xft xext xpm gdk-pixbuf-xlib-2.0` -DUSE_GDK_PIXBUF -g   -c -o atom.o atom.c
cc -march=skylake -O2 -pipe -O2 -Wall -Wunused -Wunused -Wmissing-prototypes -Wstrict-prototypes -Wpointer-sign `pkg-config --cflags x11 xft xext xpm gdk-pixbuf-xlib-2.0` -DUSE_GDK_PIXBUF -g   -c -o events.o events.c
cc -march=skylake -O2 -pipe -O2 -Wall -Wunused -Wunused -Wmissing-prototypes -Wstrict-prototypes -Wpointer-sign `pkg-config --cflags x11 xft xext xpm gdk-pixbuf-xlib-2.0` -DUSE_GDK_PIXBUF -g   -c -o parser.o parser.c
cc -march=skylake -O2 -pipe -O2 -Wall -Wunused -Wunused -Wmissing-prototypes -Wstrict-prototypes -Wpointer-sign `pkg-config --cflags x11 xft xext xpm gdk-pixbuf-xlib-2.0` -DUSE_GDK_PIXBUF -g   -c -o util.o util.c
cc -march=skylake -O2 -pipe -O2 -Wall -Wunused -Wunused -Wmissing-prototypes -Wstrict-prototypes -Wpointer-sign `pkg-config --cflags x11 xft xext xpm gdk-pixbuf-xlib-2.0` -DUSE_GDK_PIXBUF -g   -c -o progman.o progman.c
cc -march=skylake -O2 -pipe -O2 -Wall -Wunused -Wunused -Wmissing-prototypes -Wstrict-prototypes -Wpointer-sign `pkg-config --cflags x11 xft xext xpm gdk-pixbuf-xlib-2.0` -DUSE_GDK_PIXBUF -g   -c -o manage.o manage.c
cc -march=skylake -O2 -pipe -O2 -Wall -Wunused -Wunused -Wmissing-prototypes -Wstrict-prototypes -Wpointer-sign `pkg-config --cflags x11 xft xext xpm gdk-pixbuf-xlib-2.0` -DUSE_GDK_PIXBUF -g   -c -o client.o client.c
cc -o progman atom.o client.o events.o keyboard.o launcher.o manage.o parser.o progman.o util.o -Wl,-O1 -Wl,--as-needed -Wl,-z,pack-relative-relocs `pkg-config --libs x11 xft xext xpm gdk-pixbuf-xlib-2.0`
>>> Source compiled.
>>> Test phase: x11-wm/progman-1_p20260326
>>> Completed testing x11-wm/progman-1_p20260326

>>> Install x11-wm/progman-1_p20260326 into /var/tmp/portage/x11-wm/progman-1_p20260326/image
>>> Completed installing x11-wm/progman-1_p20260326 into /var/tmp/portage/x11-wm/progman-1_p20260326/image

 [32m*[0m Final size of build directory: 1152 KiB (1.1 MiB)
 [32m*[0m Final size of installed tree:  1152 KiB (1.1 MiB)

 [33m*[0m QA Notice: The ebuild is installing to one or more unexpected directories:
 [33m*[0m 
 [33m*[0m   /progman-dba2dc691b97a182d233412f022de4643ca83eae
 [33m*[0m   /usr/local
 [33m*[0m 
 [33m*[0m Please fix the ebuild to use correct FHS/Gentoo policy paths.
strip: x86_64-pc-linux-gnu-strip --strip-unneeded -N __gentoo_check_ldflags__ -R .comment -R .GCC.command.line -R .note.gnu.gold-version
   /progman-dba2dc691b97a182d233412f022de4643ca83eae/atom.o
   /progman-dba2dc691b97a182d233412f022de4643ca83eae/keyboard.o
   /progman-dba2dc691b97a182d233412f022de4643ca83eae/launcher.o
   /progman-dba2dc691b97a182d233412f022de4643ca83eae/manage.o
   /progman-dba2dc691b97a182d233412f022de4643ca83eae/client.o
   /progman-dba2dc691b97a182d233412f022de4643ca83eae/parser.o
   /progman-dba2dc691b97a182d233412f022de4643ca83eae/events.o
   /progman-dba2dc691b97a182d233412f022de4643ca83eae/progman.o
   /progman-dba2dc691b97a182d233412f022de4643ca83eae/util.o
   /progman-dba2dc691b97a182d233412f022de4643ca83eae/progman
Also available here. Once this is rectified, would I simply do emerge --ask x11-wm/progman to get it actually installed? Thank you again for your help!
Top
grknight
Retired Dev
Retired Dev
Posts: 2564
Joined: Fri Feb 20, 2015 9:36 pm

  • Quote

Post by grknight » Fri Mar 27, 2026 10:00 pm

tenkuusaru wrote:

Code: Select all

src_install() {
dodir /usr/local/bin/progman
cp -R "${S}/" "${D}/" || die "install failed!"
}
This should be

Code: Select all

src_install() {
   dobin progman
}
Blindly installing S to D is wrong when building from source
Top
tenkuusaru
n00b
n00b
Posts: 5
Joined: Fri Mar 27, 2026 11:45 am

  • Quote

Post by tenkuusaru » Fri Mar 27, 2026 10:08 pm

grknight wrote:
tenkuusaru wrote:

Code: Select all

src_install() {
dodir /usr/local/bin/progman
cp -R "${S}/" "${D}/" || die "install failed!"
}
This should be

Code: Select all

src_install() {
   dobin progman
}
Blindly installing S to D is wrong when building from source
Thank you for that, I have amended the ebuild accordingly and do not have the same notice any longer. Could I also ask, further to your earlier comment, would specifying the toolchain occur under src_compile? I am looking at the pages here and here in the devmanual for guidance but was not entirely sure.
Top
grknight
Retired Dev
Retired Dev
Posts: 2564
Joined: Fri Feb 20, 2015 9:36 pm

  • Quote

Post by grknight » Fri Mar 27, 2026 10:13 pm

Very good research. You're right about where I would put it and the docs to support it.

I am suggesting

Code: Select all

src_compile() {
  tc-export CC
  default
}
along with the necessary inherit above the function

Edit: This may work if the above does not

Code: Select all

src_compile() {
	emake CC="$(tc-getCC)" 
}
Again with the inherit
Top
tenkuusaru
n00b
n00b
Posts: 5
Joined: Fri Mar 27, 2026 11:45 am

  • Quote

Post by tenkuusaru » Fri Mar 27, 2026 10:25 pm

grknight wrote:Very good research. You're right about where I would put it and the docs to support it.

I am suggesting

Code: Select all

src_compile() {
  tc-export CC
  default
}
along with the necessary inherit above the function

Edit: This may work if the above does not

Code: Select all

src_compile() {
	emake CC="$(tc-getCC)" 
}
Again with the inherit
Thank you for that, and the encouragement! I have tried the following ebuild here (copied below) and it seems to work with no errors.

Code: Select all

# Copyright 2026 Gentoo Authors
# Distributed under the terms of the GNU General Public License v2

EAPI=8

PROGMAN_COMMIT="dba2dc691b97a182d233412f022de4643ca83eae"

DESCRIPTION="progman is a simple X11 window manager modelled after the Windows 3 era."
HOMEPAGE="https://github.com/jcs/progman"
SRC_URI="https://github.com/jcs/progman/archive/${PROGMAN_COMMIT}.tar.gz"
S="${WORKDIR}/${PN}-${PROGMAN_COMMIT}"

LICENSE="MIT"
SLOT="0"
KEYWORDS="~amd64"

DEPEND="x11-libs/gdk-pixbuf
media-libs/freetype"
RDEPEND="${DEPEND}"
BDEPEND=""

inherit toolchain-funcs

src_compile() {
	tc-export CC
	default
}

src_install() {
	dobin progman
}
Would it now be a case of emerge --ask x11-wm/progman to get it installed on my system?
Top
Hu
Administrator
Administrator
Posts: 24395
Joined: Tue Mar 06, 2007 5:38 am

  • Quote

Post by Hu » Sat Mar 28, 2026 2:37 pm

Yes, try an emerge and see if you like the result. I see no obvious problems with the latest iteration of your ebuild.
Top
Post Reply

11 posts • Page 1 of 1

Return to “Portage & Programming”

Jump to
  • Assistance
  • ↳   News & Announcements
  • ↳   Frequently Asked Questions
  • ↳   Installing Gentoo
  • ↳   Multimedia
  • ↳   Desktop Environments
  • ↳   Networking & Security
  • ↳   Kernel & Hardware
  • ↳   Portage & Programming
  • ↳   Gamers & Players
  • ↳   Other Things Gentoo
  • ↳   Unsupported Software
  • Discussion & Documentation
  • ↳   Documentation, Tips & Tricks
  • ↳   Gentoo Chat
  • ↳   Gentoo Forums Feedback
  • ↳   Duplicate Threads
  • International Gentoo Users
  • ↳   中文 (Chinese)
  • ↳   Dutch
  • ↳   Finnish
  • ↳   French
  • ↳   Deutsches Forum (German)
  • ↳   Diskussionsforum
  • ↳   Deutsche Dokumentation
  • ↳   Greek
  • ↳   Forum italiano (Italian)
  • ↳   Forum di discussione italiano
  • ↳   Risorse italiane (documentazione e tools)
  • ↳   Polskie forum (Polish)
  • ↳   Instalacja i sprzęt
  • ↳   Polish OTW
  • ↳   Portuguese
  • ↳   Documentação, Ferramentas e Dicas
  • ↳   Russian
  • ↳   Scandinavian
  • ↳   Spanish
  • ↳   Other Languages
  • Architectures & Platforms
  • ↳   Gentoo on ARM
  • ↳   Gentoo on PPC
  • ↳   Gentoo on Sparc
  • ↳   Gentoo on Alternative Architectures
  • ↳   Gentoo on AMD64
  • ↳   Gentoo for Mac OS X (Portage for Mac OS X)
  • Board index
  • All times are UTC
  • Delete cookies

© 2001–2026 Gentoo Foundation, Inc.

Powered by phpBB® Forum Software © phpBB Limited

Privacy Policy

 

 

magic