Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 7717987
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 1, 20262026-06-01T03:02:59+00:00 2026-06-01T03:02:59+00:00

Is there a way to configure a binary to be installed as SUID using

  • 0

Is there a way to configure a binary to be installed as “SUID” using automake/autoconf?
Is there any magick that can lead a make install to set the suid bit of a given binary target?

NOTE:
I am running a “fakerooted” make install inside a script to create a tar file.

I tried:

# Makefile.am

bin_PROGRAMS = my_bin

#...

install-exec-hook:
    echo    "#### Setting SUID for my_bin. ####"
    ls -l $(DESTDIR)$(bindir)/my_bin
    chmod 4755 $(DESTDIR)$(bindir)/my_bin
    ls -l $(DESTDIR)$(bindir)/my_bin
    echo    "####-------------------------------####"

But with no success.

During make install I see:

#### Setting SUID for sudo_script. ####
-rwxr-xr-x 1 root root 8704 Mar 28 13:30 /install.pak/usr/bin/my_bin
-rwsr-xr-x 1 root root 8704 Mar 28 13:30 /install.pak/usr/bin/my_bin
####-------------------------------####

So one could think it is a problem with fakeroot, but if I move the chmod out of Makefile.am to my packaging script, it works. This is enough to convince me fakeroot is doing its job.

Thanks.

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-01T03:03:01+00:00Added an answer on June 1, 2026 at 3:03 am

    GAHH!!

    Someone unconsciously put in my script, after $FAKEROOT make install:

    $FAKEROOT chmod 755 $PAK_DIR/usr/bin/*
    

    replacing all the permissions writen by make install.

    Removing this line the install-exec-hook works as expected and the SUID bit is preserved…

    (Were did I put my ax?…)

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

Is there a way that I can configure Visual Studio 2008 to understand CamelCase?
Can anyone say is there any way to configure request filtering for WCF get
Is there any way to configure IIS or Web app to automatically open a
Is there any way to configure Doxygen to include the log from SVN for
Is there a way to configure hg com so that in the commit message
Is there a way to configure JAXB to so that a generated class implements
Is there any way to configure NLog to log information per application session? As
Is there any way to configure a SQL server instance to not permit updates
Is there a way to configure a mysql table so that writing and reading
Is there a way to configure an application shortcut so that a Windows shell

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.