Small in big

I have a big vi in labview 6.0. When I print the prpgram, some sequences contain code that are too small. Can I increase the size of the contents in the sequence without changing the size of the sequence frame in labview 6.0? I do not want to change the size of the sequence because it might corrupt the program. The vi is attached.
Attachments:
forum RTF1.rtf ‏711 KB

you can capture the image of that sequence (only the portion you want) and print out the image.
or you can copy that code into a new vi with a new sequence and print the new VI.
-Joe

Similar Messages

  • Small and big album art not matching

    I bought an 5G iPod only ten days or so ago, and I have recently finished to transfer all my song database.
    I'm seeing something strange happens with the album art. Sometimes I take a look on the screen, and it correctly displays the song info: artist, album, song title and also the small album pic are OK. But when I push the central button to see the enlarged album art, sometimes the album picture I see belongs to a different artist or album that I also have in my library. It also happens the other way around, i.e, if I display the big album pic and then I switch to the artist/title screen.
    Does anyone know how can I fix this and why does it happen?
    Thanks in advance
    Edit: I have just seen that sometimes the work art displayed is plain wrong in both small and big sizes. I have checked on ITunes and the album art is looks fine there, though. Is it possible that something went wrong during my last iPod-iTunes sync?

    yeah mine too, and i've tried re-setting it, and wiping it and re-sync ing etc,
    still seems to do the same, and is generally rally annoying seeing how it is such a relatively useless feature, it would be nice if it at least worked...!
    any ideas..?

  • Replace sourcefile small or big change in source file if machines are already received old policy how they behaves

    we have deployed package or task sequence into static or dynamic collection with always re-run or re-occurrence re-run settings . issue is need to replace sourcefile small or big change in source file setps need to perform stop advertisement and replace
    new content update source version (update package) re-enable advertisement. now question is if machines are already received old policy how they behaves and if machines already installed package\task sequence how they behaves.

    Peter is correct, however I think the crux of the question is what will the client do when the source files are updated in relation to existing deployments. The answer is nothing. Source file changes do *not* trigger deployments to be rerun. If the deployment
    has not run yet, as Peter noted, the new files will get downloaded, however, if the deployment has already been enforced, there's nothing to be done as the point of the deployment to run the appropriate command-line. Once that's been done, a source file change
    is meaninglessness.
    Jason | http://blog.configmgrftw.com | @jasonsandys

  • Adressbook pictures sometimes small or big

    Hi!
    When I creat a contact on my iPhone and add a picture direct on my iPhone to it I can see a big user picture over the full screen when making phone calls. When I create a contact on my Mac and add a picture to them on my Mac and sync it with my iPhone I can see a small picture in the top right corner when doing phone calls.
    This is very inconsistence and I would like to have the same picture width, height, position whatever I create the contact on my Mac or on my iPhone.
    It should be the same to create a contact on a Mac or on an iPhone.
    Thanks
    Jak

    That can't be right.
    They are thumbnails in my contact application on my iPhone too. Anyway I see a thumbnail when I open my adressbook.
    When I sync my iPhone with iTunes all contacts (the one created on my iPhone and the one created on my Mac) are stored in the Mac OSX adressbook. No I can delete all contacts on my iPhone or simply use the function "replace all contacts on my iPhone with the one from my Mac". With your description the contacts from my Mac, where I have thumbnails only, are copyed to my iPhone. No I should have small pictures for every contact (The way you describe the function). But I have full size pictures for the contacts which are originally created on my iPhone. So there must be differents stored in the appropriate files.
    Or can you explain it to me in other ways?
    Thanks!

  • Workflow question starting big, then small, then big, it goes on

    Hi,
    I have a project. I have several comps, let's call one of them Comp A.
    Comp A is 1920x1080 pixels in size. I am hoping my company will make the switch to blu-ray sooner or later, but it hasn't happend yet, so I was working large.
    I need to output to standard DVD size, 864x486
    So I place Comp A inside of a new comp, let's call it SizerComp. SizerComp is 864x486 pixels in size, and this is the comp that gets rendered, and finally, authored to DVD.
    I notice that the DVD that results from this output, the text is somewhat blurry. Is this because of the workflow I have used? Or maybe I need to scale my text up larger? It's not small text, but definitely on the smaller side.
    Ok onward.
    So I am also rendering videos from 3DS Max. I don't want to render at 1920x1080 because it takes FOREVER. Am I safe to render at the final size my DVD will be? So can I render 864x486, place this file into Comp A, and then scale it up to fill the comp? It would pretty much double the size of the 3D frames that were outputted, but then upon final render, the whole Comp A would get sized back down to 864x486 again, the original size of the 3D frames.
    So for the second scenario, am I looking at a quality loss on my 3D output?

    The quality loss when scaling down is typically less than the quality loss when scaling up, but it does occur.
    Yes, I would recommend working at your output size in most cases.
    You had a good thought, which is to work large if you think that you will be required to output at a large size later---but there are tradeoffs. And, if you're really not likely to have to output large later, then you've made those tradeoffs of quality and time for nothing.
    I made similar points here.

  • Microsoft Jet Provider problem with small or big numbers numbers

    I'm using an script component as a source to process excel files.  Inside the component I'm suing the Microsoft Jet provider with the OleDb connection to open and read the data in the excel file.  Several of the columns on the spread sheet are
    numeric and some of the values are very small.  I found out that when the value is very small the number is represented using the scientific notation, so when the provider try to convert the value to a number fails and send a null value instead.  Does
    anyone know a way to solve this problem?  The reason I'm using an script component is to process multiple file formats in one data flow task using a loop through iterate through all the excel files.
    Thanks,
    Alberto Botero
    Alberto Botero

    Hi Alberto,
    Thank you for your question. I am currently looking into this issue and will give you an update as soon as possible.
    Thank you for your understanding and support.
    If you have any feedback on our support, please click
    here.
    Elvis Long
    TechNet Community Support

  • Small brush big size..Please help!!

    I' m using cs2. my brush is so tiny..it doesn't matter what brush size  i use.... I can't see my actual on sreen brush size
    I took caps lock off..still didn't work..I'm going crazy.
    Your help would be greatly appreciated!!

    There's a known problem with some nVidia video drivers that causes all or part of a brush outline to be hidden.
    Check the version of your video drivers and update from the web site of the maker of your video card.
    -Noel

  • Small problems, big annoyance.

    This is actually a two part problem. First off, whenever I go to play a game, Far Cry and Battlefront mostly, I notice that I go from 7. to 2. sound. The games always reduce me to 2 speakers which i have to go back and fix all my setting when I exit the game. I've changed the settings in both games all over the place and it still does it. Anyone else get this hassle, or do I have to go to the game's website forums and start something?
    The other problem is that I used to be able to play videos in WMP and be able to turn the sound down so i can still hear music using iTunes or Source Player, yet now the volume control in WMP will turn the system volume down. Is there a way to have the WMP volume control independent from the system volume?
    Perhaps these are retaded questions that need to be asked elsewhere, I just cant find solutions for these problems and I know SOMEONE has to have come across one of these at one point or another, so any help would be appreciated.

    sonic8or wrote:
    This is actually a two part problem. First off, whenever I go to play a game, Far Cry and Battlefront mostly, I notice that I go from 7. to 2. sound. The games always reduce me to 2 speakers which i have to go back and fix all my setting when I exit the game. I've changed the settings in both games all over the place and it still does it. Anyone else get this hassle, or do I have to go to the game's website forums and start something?The other problem is that I used to be able to play videos in WMP and be able to turn the sound down so i can still hear music using iTunes or Source Player, yet now the volume control in WMP will turn the system volume down. Is there a way to have the WMP volume control independent from the system volume?Perhaps these are retaded questions that need to be asked elsewhere, I just cant find solutions for these problems and I know SOMEONE has to have come across one of these at one point or another, so any help would be appreciated.
    For WMP, you probably have to check with microsoft, not too sure about that. As for the speaker setting, I'm 99% sure that you have other program that's set and 2. instead of 7. and it's causing the change. You might want to check through your computer and make sure that all those program be set at the correct speaker setting. BTW, what sound card do you have?

  • Small list,big problems

    1. Can't use punch on the fly. Too tired of this one to bother recounting the lame, sorry assed tale by now. Solution - I have no option but to use Cubase if I want any kind of reliable overdub.
    2. Midi sync - oh, where would that be now that Apple have "upgraded" Logic? All over the place, that's where. Tried sync'ing any external units which require midi clock recently? Logic6 did it flawlessly, as does Cubase. Logic7 loses the groove every time. Solution - don't use external gear.
    3. ES2 won't sync when recording another track. Set to play a 16ths LFO the groove more often than not falls over when I record any other track. Solution - never use ES2 again.
    4. Pointer in event editor doesn't correspond to the note just played. Solution - consign yet another piece of Logic's arsenal to the bin, never to be opened again.
    5. Follow tempo - thanks, if I ever need to sound like Donald Duck being sexually abused I'll know which box to tick.
    Great in Logicland these days, innit.

    The site generated by Muse is being uploaded to https://www.ltcpcms.com/rxconnex/. It's then being presented at www.rxconnexttoday.com inside a frameset. The frameset will interfere with the ability for the site to correctly detect the size of the device screen. This frameset needs to be removed. If you load https://www.ltcpcms.com/rxconnex/ on your devices the phone site will resize correctly.

  • How do I enable the big green battery and the plug icon? (R61 - Win7 64)

    I know that this subject is pretty old, but maybe somebody will answer.
    I have a reverse problem from:
    http://forums.lenovo.com/t5/T61-and-prior-T-series-ThinkPad/How-do-I-remove-the-big-green-battery-an...
    I do not have this green battery and the plugin icon, instead I have gray battery like this:
    Strange thing is that it is resistant to any changes in Power Manager Advanced Options - whatever I check: hide, show, small icon, big icon - it stays as it is.
    I use Win7 64bit.
    Any ideas?
    Moderator comment: New thread split from the above link. Subject and post edited to reflect new content.
    Solved!
    Go to Solution.

    Yes, that previous page button is wonderful, isn't it LOL. It has gotten me many times. Some text editors are merciful and will preserve your work if you immediately hit the back button. The Lenovo Forum editor does not but it does autosave your draft ever so often
    Concerning Power Manager: First, let's make sure of the obvious. Have you tried removing and re-installing your battery and making sure it is making good contact?
    Assuming your battery is not the problem,
    go ahead and uninstall "Hotkeys."
    Hotkeys version 3.81.0100 currently includes 5 separate components which you will see in your list of programs:
     - On Screen Display
     - Thinkpad Full Screen Magnifier
     - Lenovo System Interface Driver
     - Lenovo Auto Scroll Utility
     - Lenovo Patch Utility
    Use Control Panel and make sure to un-install all of these. (You may never have installed Hotkeys. If so, skip this step Or, if you have installed a previous version which does not include all of these components, just un-install any of these you find).
    Next, use Control Panel to un-install "Power Manager," and "Lenovo Power Management Driver." Yes, "Power Manager" is different from "Lenovo Power Management Driver." (It sounds like like you may never have installed "Lenovo Power Management Driver" so just skip that one if you don't see it in your list of programs.)
    Tip: Older versions of "Power Manager" may be called "Thinkpad Power Manager" or "Lenovo Power Manager." We're now up to version 6.36.
    Reboot as prompted during the un-installation process.
    Now, go to the Lenovo Drivers and Software page here and enter your type/model number.
    Install the following software in this order:
    (1) First, install "Lenovo Power Management Driver" from the Power Management section.
    (2) Next, install "Hotkey Features Integration" from the Software and Utility section.
    (3) Finally, install "Power Manager" itself. (Version 6.36 you see there is the latest version).
    Reboot as instructed during the installation process.
    As for the Lenovo "anti-shock feature,"  install "ThinkVantage Active Protection System" from the Thinkvantage Technology section
    That should do it. Let us know how you do.
    Moderator comment: Subject edited to match new thread.
    Have a great day. (I do not work for Lenovo)

  • Oracle Small Application

    Hi,
    we are developing risk management solution for small ang big organisations, the problum is that when ever we recommend oracle solution to our clients they allways ask either oracle have any small business application or not ? why should we buy seperate database , developer suite ? why dont we go for microsoft product ?
    Oracle have any future plan to introduce any small business application kind of product ??
    I realy highly appricate you if you give me reply.
    Regards
    Noman ul haq

    What exactly do you mean when you say "small business application"? are you looking for an application or a database for small organizations?
    Check out the Oracle store site http://store.oracle.com and you'll see that you can buy two types of database an enterprise edition and a standard edition. The standard edition is priced to compete with the MS product. You can also buy a user based license which is usually cheaper for smaller organizations.
    Remember that MS might still be cheaper but how much will it cost your customer the next time that a slammer warm or virus will hit their SQL*server and stop their operations for a few days?
    If you are talking about an applications suite for small businesses check out the Oracle Small Business Suite:
    http://www.oracle.com/outsourcing/sbs/
    One thing to consider, is to work in a hosted environment for small businesses. Since everything in Oracle can work in Web deployed way, you can have every piece of software hosted on your servers and offer your end users access from a browser in their organizations.
    This way the small business doesn't need to purchase and install Oracle software, and you can earn money by leasing your software. This is what we call software as a service and this is what we at Oracle do with our Oracle E-Business Suite offering

  • [solved] Small changes to abs PKGBUILDs and maintenance/updating

    Hi!
    Somehow I manage to hoard packages that require intervention on updates. Small things, like p.e. adding a flag to have cups build without the need for avahi or midori (if I rememer tight that one was libsoup) without gconf... or just an own mozconfig for firefox. Nothing that really requires too much thinking/knowing/decision-making - at least to apply the changes to updated PKGBUILDs.
    Now what's the best way to maintain that and is there already a good script or something to do it?
    Something like p.e.:
    - Have a folder with PKGBUILD patches (like "insert additional build flag")
    - If folder for package exists, build from ABS as soon as new abs version exists, apply patch to PKBUILD before that & notify if it fails with the updated PKBUILD (something like just adding the -disable_whatever flag shouldn't require much intervention, should it?)
    - If no folder, take pacman package as soon as soon as ABS is updated (are there lots problems with them not being in sync?)
    Well, but that's just an example... how do you do it? How do you let yourself get informed about repo updates of package you have installed as local slightly modified version? How do you reapply small / medium / big changes to the updated original PKGBUILDs? And slightly related: Do you think it makes sense to provide & request AUR packages that are only slightly different from the original ABS ones (like one line / one configure flag...) or would that just lead to way to many AUR entries that are only used by 1-2 people?
    thx...
    Last edited by whoops (2009-07-24 16:53:08)

    Thanks!
    That doesn't really do everything I had in mind, but as it's bash and I can spend hours screaming at single lines of bash that don't work after I changed/typed them,  it should keep me occupied until I either give up, break something or get it to do what I want...
    Still: If anyone knows something like it that maybe has support for AUR and/or makes it easier to keep patches / custom files (like mozconfig) in the "private ABS tree" for automatic updating / building, just point me into the direction!

  • Large files or small files

    i work with still images and use imovie to make a slide show with music. it works rather well.
    im interested to know if low res jpg allow me to use twice as many images vs. max full size jpgs images, these images will be shown on a 50" flat screen?
    would also like to know is there a way of checking the imovie file size while it is being designed?
    also what type of dvd should i use to record this movie if its going to be played back on a dvd player or a computer?
    thank you

    Hi
    If You are using iDVD SlideShow function - then there is a LIMIT to know - of 99 photos per SlideShow
    You can have up to 99 SlidShows on a DVD
    I make my in any video editor except iMovie'08 to 11 as non of them can deliver interlaced SD-Video as iDVD and other DVD authoring programs demands - ELSE quality will suffer severely.
    I use
    • iMovie HD6
    • FinalCut Express or Pro
    • FotoMagico™ (incl Roxio Toast™ bundle) and burned as Blu-Ray WHEN QUALITY IS IMPORTANT
    Usin HD-Material will not help - but result will suffer here too due to BAD downscaling.
    Small resp Big photo files - YES there has been reported problems with large photos (whatever that is) - and it's not the size of the compressed .jpg files that matters BUT size of the Un-folded photo.
    My are from 2Mb to about 12Mb in .tiff (.tiff not used in projects - but always as .jpg - but to set size as uncompressed) and they work fine.
    But when picture are 50Mb to 500Mb (Yes I got one of those) - I guess that things might go wrong.
    Yours Bengt W

  • Little big disk slow

    Hi Forum
    I purchased a little big disk 512 ssd for video editing
    the unit works great with my laptop achives extreme speeds that i require for handling large projects (well usually 230 gbs per job usually 3 per month)
    I recently upgraded to an imac late 2013 model (current model and i maxed out the optionals)
    it uses the 3tb fusion drive tho
    when i plug in the little big disk into my imac it mounts fine and i can read data fine - however i cannot write data to it at least not quickly it takes 6 hours to transfer 100gb compared to the 10 or so minutes using my laptop
    the copy hangs appx every 50mb for about 30 seconds and then jumps up another 50mb (i can confirm the cable is not faulty as i get this result using 2 seperate cables)
    i tried all the usual steps - restart - repaired disk permissions - even reset the pRam
    i noticed after resetting the pRam that for the first 10 seconds i am able to use the drive normally and then if i have large files copying after about 10 seconds the problem shows again  and the copy hangs at the point it got up to (anything i copy in the first 10 seconds is super fast as the drive should be)
    my theory and the support at lacie is that somhow the boot drive is interfering with the transfer - the lacie specialist suggests that since fusion drives arent very common yet and havent been tested there may be a conflict ...
    i have tried copying from a daisychained thunderbolt drive directly to the new hdd and still experience the problem so i dont think it is a prblem with the internal drive
    black magic disk speed test and it show a perfect working disk and gets files on and off it easily but not anything i want to copy will work
    it soesnt matter the file mp3 or mov small or big the same problem happens
    i have reconfigured the raid and reformated the drives with the laCie support
    they think its a 100% normal functioning drive and that the problem is with my imac as the drive works on all other computers that i have tried
    really im stumped and dont know what i should try next to get the hdd and my imac to become compatable
    Can i get apple to diagnose it remotely
    do they do that?

    Hi there MSPoettl,
    I updated to the new firmware for the 24' when it was released. This largely fixed the problem, although the Lacie's fan makes a very airy noise as it blows. The image on the 24' led apple careen is stable, so good news there. However when plugging the MBair into the Lacie and then into a 27' iMac I still get occasional distortion.
    Good luck.
    David

  • [new] webmin(-minimal)

    Heya all,
    since there were quite some requests for this. I made a PKGBUILD for webmin. I have to say ... this wasn't an easy one for me. I choose for webmin-minimal so that peopel can add the modules they want.
    However, when you look at the code, you'll see that it needs improvements ...
    What is done:
    it builds and installs. It creates a new user and group, both called webmin. these groups will be deleted when you uninstall the package (see comments if this is good or bad).
    ~Todo:
    * No SSL can be used ... this is pretty critical I think. There is an SSLeay package in testing I saw, but webmin couldn't find it.
    * I also get an error in the webmin-log that it can find  a/the perl PAM-module ...
    * The web-interface seems to function, but you can't request a proces-list: this is maybe a bug in the program?? Webmin requests "proc/index_.cgi", but that file doesn't exist. The file "proc/index.cgi" exists however.
    * I've written code the generate a random initial password. However, this code doesn't seem to function. For the moment there is a static password ... but I suppose you'll change it when you install webmin. Anyway, Ithink it would be better if the initial one would be a random password. This code belongs in the install-file to my opinion and not in the PKGVUILD like now, but this requires some effort to implement since there is some code for setting up the password in the setup-file.
    * A lot of comments in the code ...
    Now it's time to sleep ... .
    PKGBUILD:
    #Michel Branbants <[email protected]>
    pkgname=webmin
    pkgver=1.170
    pkgrel=1
    pkgdesc="Webmin is a web-based interface for system administration for Unix. Using any browser that supports tables and forms (and Java for the File Manager module), you can setup user accounts, Apache, DNS, file sharing and so on. Webmin consists of a simple web server, and a number of CGI programs which directly update system files like /etc/inetd.conf and /etc/passwd. The web server and all CGI programs are written in Perl version 5, and use no non-standard Perl modules."
    url="http://www.webmin.com"
    depends=('perl>=5.0' 'coreutils')
    backup=('etc/webmin/miniserv.conf')
    install=webmin.install
    source=(http://belnet.dl.sourceforge.net/sourceforge/webadmin/$pkgname-$pkgver-minimal.tar.gz
    setup.sh.patch
    copyconfig.pl.patch
    webmin.install)
    md5sums=('a2bc5d04524c52af8955c703179e8af4' '0332a42a04a9c522d483e8d2d61fcee1'
    '72f5472f6b8fedf02cf8222cf962053b' '521d14ee48a8203f3765cadc9fbd9379')
    build() {
    cd $startdir/src/$pkgname-$pkgver
    patch ./setup.sh $startdir/setup.sh.patch
    patch ./copyconfig.pl $startdir/copyconfig.pl.patch
    declare -r local installDir="/usr/share/webmin"
    #configdir must be an absolute path
    declare -r local configDir="/etc/webmin"
    #this is the var_dir-variable
    declare -r local logAndPidDir="/var/webmin"
    #I added 2 new dirs to the setup-script, but I'm not completely sure if I just may add them. And what's var_dir's purpose now?So, for the log and run-files these directories should be used
    declare -r local logDir="/var/log/webmin"
    declare -r local pidDir="/var/run/webmin"
    declare -r local os_type="generic-linux"
    declare -r local os_version="2.6"
    declare -r local real_os_type="Generic Linux"
    declare -r local real_os_version="2.6"
    declare -r local webminServerport="10000"
    #username maybe not contain a ':' or a ' '(a space :)) and may not be "webmin"
    declare -r local adminLoginname="admin"
    #password may not contain a ':'.
    #dit moet eigenlijk in de install-file
    echo "generating initial administrator password ..."
    declare -r local adminpass=$(genPassword 8)
    echo "#The first and last quote of the loginpass-value are only to delimit the password and aren't part of the password!
    initial webmin administrator-account:
    loginname:$adminLoginname
    loginpass:"$adminpass"" > $startdir/SHRED or REMOVE ME-webminAdminAccount
    echo "info written to "SHRED or REMOVE ME-webminAdminAccount""
    #no SSL need SSLeay installed somewhere perl can find it!
    #post-setup-script: (line 735) setup-post.sh
    ./setup.sh "$installDir" "$startdir/pkg" "$configDir" "$logAndPidDir" "$webminServerport" "$adminLoginname" "$adminpass" "$os_type" "$os_version" "$real_os_type" "$real_os_version" "$logDir" "$pidDir"
    echo "administrator-account-info written to "$startdir/SHRED or REMOVE ME-webminAdminAccount""
    #$1 = length of Password. Must be AT LEAST 8 CHARACTERS. Some people will say this is not necessary maybe or not enough. Anyway this password is the initial password.
    genPassword() {
    declare -r local passLength=$1
    if [[ 8 -gt $passLength ]]; then
    #writing to stderr
    echo "password length needs to be at least 8 characters" 1>&2
    return 1
    fi
    declare local pass=$(genRandomString $passLength)
    #the password may not contain ':'.
    #Replace all occurences of ':' with another character. Mayeb first check if there is a problem ...
    #could be endless loop .. but I would suppose it is a random generator ... I try maximum 3 times
    #to avoid an endless loop, else the character 'A' will be chosen to replace ':'
    declare local replacement=':';
    declare -i local iter=1;
    while [[ ':' == $replacement ]] && [[ $iter -le 3 ]]; do
    replacement=`head -c 1 /dev/random`
    iter=$iter+1
    done
    if [[ ':' == $replacement ]]; then
    replacement='A'
    fi
    pass=${pass//:/$replacement}
    echo "$pass"
    return 0
    #$1 = length of string.
    genRandomString() {
    declare -ri local stringLength=$1;
    #/dev/random instead od /dev/urandom will be used for more chance on a good random values.
    #/dev/random can however block if not enough input is available
    declare local string
    read -n $stringLength string < /dev/random
    #echo "$string"
    echo "QueCeraCera"
    webmin.install:
    #Contributor: Michel Brabants <[email protected]>
    # This is a default template for a post-install scriptlet. You can
    # remove any functions you don't need (and this header).
    # arg 1: the new package version
    pre_install() {
    /bin/true
    # arg 1: the new package version
    post_install() {
    declare -r local USER="webmin"
    declare -r local GROUP="webmin"
    #searching for free gid in range of 1-100 : error should be captured : todo
    declare -ri freeGid=$(getFreeGid);
    echo -n "Creating group $GROUP : ";
    if [[ 0 -eq `/usr/sbin/groupadd -g $freeGid $GROUP` ]]; then
    echo " OK";
    else
    echo " FAILED";
    fi
    #searching for free uid in range of 1-1000 : error should be captured : todo
    declare -ri freeUid=$(getFreeUid);
    echo -n "Creating user $USER with primary group $GROUP";
    if [[ 0 -eq `/usr/sbin/useradd -c "user for webmin" -g "$GROUP" -G "$AUDIO_GROUP" -s "/bin/false" -u $freeUid $USER` ]]; then
    echo " OK";
    else
    echo " FAILED;"
    fi
    update_permissions $USER $GROUP;
    # arg 1: the new package version
    # arg 2: the old package version
    pre_upgrade() {
    /bin/true
    # arg 1: the new package version
    # arg 2: the old package version
    post_upgrade() {
    #we don't add the user again ... or should we check if it still exists?
    declare -r local USER="webmin"
    declare -r local GROUP="webmin"
    update_permissions $USER $GROUP;
    # arg 1: the old package version
    pre_remove() {
    /bin/true
    # arg 1: the old package version
    post_remove() {
    rm -rf /var/log/webmin
    rm -rf /var/run/webmin
    declare -r local USER="webmin"
    declare -r local GROUP="webmin"
    #delete the webmin user. Mayeb to tricky? Somebody may be using it already
    #userdel seems to delete the user and the group
    echo -n "Deleting user $USER and group $GROUP: ";
    if [[ 0 -eq `/usr/sbin/userdel $USER` ]]
    then
    echo " OK";
    else
    echo " FAILED";
    fi
    #echo -n "Deleting group $GROUP : ";
    #if [[ 6 -eq `/usr/sbin/groupdel $GROUP` ]]
    #then
    # echo " OK";
    # else
    # echo " FAILED";
    #fi
    # arg 1: username
    # arg 2: groupname
    #would be better if we used the file-list that is in the package?
    update_permissions() {
    declare -r local USER=$1;
    declare -r local GROUP=$2;
    echo "Setting owner:group of webmin-files to $USER:$GROUP and setting permissions ...";
    #change file- and directory-permissions
    chown -R $USER:$GROUP /etc/webmin
    chmod -R o= /etc/webmin
    chown -R $USER:$GROUP /usr/share/webmin
    chmod -R o= /usr/share/webmin
    chown -R $USER:$GROUP /var/log/webmin
    chmod u+s,g+s,o=,o+t /var/log/webmin
    chown -R $USER:$GROUP /var/run/webmin
    chmod u+s,g+s,o=,o+t /var/run/webmin
    echo "Setting owner:group and permissions : DONE"
    #the almighty bash :). You can use functions together with pipes :).
    getFreeUid() {
    echo "$(uidRangeFilter 1 1000 | sort -g | getFreeId 1 1000)";
    getFreeGid() {
    echo "$(gidRangeFilter 1 100 | sort -g | getFreeId 1 100)"
    #give all existing uid's back within the range of $1-$2
    uidRangeFilter() {
    #going into restricted mode
    set -r;
    declare -ri local minId=$1;
    declare -ri local maxId=$2;
    if [[ $maxId -lt $minId ]]; then
    echo "maximum rangebound is smaller than minimum rangebound.";
    echo "command: ./uidRangeFilter minimumBound maximumBound"
    exit 1;
    fi
    #should mayeb check on overflow. Surely since this is a critical file
    #IFS = internal field separator/delimiter
    IFS=:;
    while read name passwd uid theRest; do
    if [[ $uid -ge $minId ]] && [[ $uid -le $maxId ]]; then
    echo "$uid";
    fi;
    done < /etc/passwd;
    #give all existing gid's back within the range of $1-$2
    gidRangeFilter() {
    #going into restricted mode
    set -r;
    declare -ri local minId=$1;
    declare -ri local maxId=$2;
    if [[ $maxId -lt $minId ]]; then
    echo "maximum rangebound is smaller than minimum rangebound.";
    echo "command: ./gidRangeFilter minimumBound maximumBound"
    exit 1;
    fi
    #should mayeb check on overflow. Surely since this is a critical file
    #IFS = internal field separator/delimiter
    IFS=:;
    while read name passwd gid theRest; do
    if [[ $gid -ge $minId ]] && [[ $gid -le $maxId ]]; then
    echo "$gid";
    fi;
    done < /etc/group;
    #find a freeId that is in the range of $1-$2 given that the input-stream contains already occupied id's, sorted from small to big.
    getFreeId() {
    #enter restricted mode
    set -r;
    declare -ri local minId=$1;
    declare -ri local maxId=$2;
    if [[ $maxId -lt $minId ]]; then
    echo "maximum id is smaller than minimum id.";
    echo "command: ./freeId minimumId maximumId"
    exit 1;
    fi;
    declare -i local freeId=$minId;
    #uid's are within the requested range and sorted from small to big
    while read uid; do
    #userId is occupied
    if [[ $freeId -eq $uid ]]; then
    let freeId+=1;
    else
    echo "$freeId";
    return;
    fi;
    done
    if [[ $maxId -ge $freeId ]]; then
    echo "$freeId";
    return;
    fi;
    #no free userId found
    echo "";
    return;
    op=$1
    shift
    $op $*
    setup.sh.patch:
    --- setup.sh 2004-12-03 01:19:35.000000000 +0100
    +++ setup-new.sh 2004-12-03 01:53:42.000000000 +0100
    @@ -32,6 +32,22 @@
    PERLLIB="$PERLLIB:$perllib"
    fi
    +declare -r local DESTDIR=$2;
    +declare -r local config_dir=$3;
    +#what is the purpose for var_dir?
    +declare -r local var_dir=$4;
    +#what is the influence of placing the log- and pid-files in another directory than var_dir?
    +declare -r local os_type=$8;
    +#leaned something new: from $9 paramters need to be surrounded by brackets!!
    +declare -r local os_version=${9};
    +declare -r local real_os_type=${10};
    +declare -r local real_os_version=${11};
    +declare -r local port=$5;
    +declare -r local login=$6;
    +declare -r local password=$7;
    +declare -r local log_dir=${12};
    +declare -r local pid_dir=${13};
    +
    echo "***********************************************************************"
    echo "* Welcome to the Webmin setup script, version $ver *"
    echo "***********************************************************************"
    @@ -40,40 +56,40 @@
    echo ""
    # Only root can run this
    -id | grep "uid=0(" >/dev/null
    -if [ $? != "0" ]; then
    - uname -a | grep -i CYGWIN >/dev/null
    - if [ $? != "0" ]; then
    - echo "ERROR: The Webmin install script must be run as root";
    - echo "";
    - exit 1;
    - fi
    -fi
    +#id | grep "uid=0(" >/dev/null
    +#if [ $? != "0" ]; then
    +# uname -a | grep -i CYGWIN >/dev/null
    +# if [ $? != "0" ]; then
    +# echo "ERROR: The Webmin install script must be run as root";
    +# echo "";
    +# exit 1;
    +# fi
    +#fi
    # Use the supplied destination directory, if any
    if [ "$1" != "" ]; then
    wadir=$1
    - echo "Installing Webmin from $srcdir to $wadir ..."
    - if [ ! -d "$wadir" ]; then
    - mkdir "$wadir"
    + echo "Installing Webmin from $srcdir to $DESTDIR$wadir ..."
    + if [ ! -d "$DESTDIR$wadir" ]; then
    + mkdir -p "$DESTDIR$wadir"
    if [ "$?" != "0" ]; then
    - echo "ERROR: Failed to create $wadir"
    + echo "ERROR: Failed to create $DESTDIR$wadir"
    echo ""
    exit 1
    fi
    else
    # Make sure dest dir is not in use
    - ls "$wadir" | grep -v rpmsave >/dev/null 2>&1
    - if [ "$?" = "0" -a ! -r "$wadir/setup.sh" ]; then
    - echo "ERROR: Installation directory $wadir contains other files"
    + ls "$DESTDIR$wadir" | grep -v rpmsave >/dev/null 2>&1
    + if [ "$?" = "0" -a ! -r "$DESTDIR$wadir/setup.sh" ]; then
    + echo "ERROR: Installation directory $DESTDIR$wadir contains other files"
    echo ""
    exit 1
    fi
    fi
    else
    - echo "Installing Webmin in $wadir ..."
    + echo "Installing Webmin in $DESTDIR$wadir ..."
    fi
    -cd "$wadir"
    +cd "$DESTDIR$wadir"
    # Validate source directory
    allmods=`cd "$srcdir"; echo */module.info | sed -e 's//module.info//g'`
    @@ -108,16 +124,16 @@
    echo ""
    exit 2
    fi
    -if [ ! -d $config_dir ]; then
    - mkdir $config_dir;
    +if [ ! -d $DESTDIR$config_dir ]; then
    + mkdir -p $DESTDIR$config_dir;
    if [ $? != 0 ]; then
    - echo "ERROR: Failed to create directory $config_dir"
    + echo "ERROR: Failed to create directory $DESTDIR$config_dir"
    echo ""
    exit 2
    fi
    fi
    -if [ -r "$config_dir/config" ]; then
    - echo "Found existing Webmin configuration in $config_dir"
    +if [ -r "$DESTDIR$config_dir/config" ]; then
    + echo "Found existing Webmin configuration in $DESTDIR$config_dir"
    echo ""
    upgrading=1
    fi
    @@ -197,9 +213,9 @@
    rm -f $config_dir/module.infos.cache
    else
    # Config directory exists .. make sure it is not in use
    - ls $config_dir | grep -v rpmsave >/dev/null 2>&1
    + ls $DESTDIR$config_dir | grep -v rpmsave >/dev/null 2>&1
    if [ "$?" = "0" -a "$config_dir" != "/etc/webmin" ]; then
    - echo "ERROR: Config directory $config_dir is not empty"
    + echo "ERROR: Config directory $DESTDIR$config_dir is not empty"
    echo ""
    exit 2
    fi
    @@ -223,14 +239,55 @@
    exit ""
    exit 3
    fi
    - if [ ! -d $var_dir ]; then
    - mkdir $var_dir
    + if [ ! -d $DESTDIR$var_dir ]; then
    + mkdir -p $DESTDIR$var_dir
    if [ $? != 0 ]; then
    - echo "ERROR: Failed to create directory $var_dir"
    + echo "ERROR: Failed to create directory $DESTDIR$var_dir"
    echo ""
    exit 3
    fi
    fi
    +
    + abspath=`echo $log_dir | grep "^/"`
    + if [ "$abspath" = "" ]; then
    + echo "Log-file-directory(log_dir) must be an absolute path"
    + echo ""
    + exit 3
    + fi
    + if [ "$log_dir" = "/" ]; then
    + echo "Log directory(log_dir) cannot be /"
    + echo ""
    + exit 3
    + fi
    + if [ ! -d $DESTDIR$log_dir ]; then
    + mkdir -p $DESTDIR$log_dir;
    + if [[ $? != 0 ]]; then
    + echo "ERROR: Failed to create directory $DESTDIR$log_dir"
    + echo ""
    + exit 3
    + fi
    + fi
    +
    + abspath=`echo $pid_dir | grep "^/"`
    + if [ "$abspath" = "" ]; then
    + echo "Pid-file-directory(pid_dir) must be an absolute path"
    + echo ""
    + exit 3
    + fi
    + if [ "$pid_dir" = "/" ]; then
    + echo "Pid directory(pid_dir) cannot be /"
    + echo ""
    + exit 3
    + fi
    + if [ ! -d $DESTDIR$pid_dir ]; then
    + mkdir -p $DESTDIR$pid_dir;
    + if [[ $? != 0 ]]; then
    + echo "ERROR:Failed to create directory $DESTDIR$log_dir"
    + echo ""
    + exit 3
    + fi
    + fi
    +
    echo ""
    # Ask where perl is installed
    @@ -256,7 +313,7 @@
    fi
    else
    printf "Full path to perl (default $perldef): "
    - read perl
    +# read perl
    if [ "$perl" = "" ]; then
    perl=$perldef
    fi
    @@ -386,6 +443,7 @@
    echo ""
    exit 14
    fi
    +
    printf "Login password: "
    if [ "$password" = "" -a "$crypt" = "" ]; then
    stty -echo
    @@ -425,82 +483,84 @@
    fi
    # Ask whether to run at boot time
    - if [ "$atboot" = "" ]; then
    - initsupp=`grep "^os_support=" "$srcdir/init/module.info" | sed -e 's/os_support=//g' | grep $os_type`
    - atboot=0
    - if [ "$initsupp" != "" ]; then
    - printf "Start Webmin at boot time (y/n): "
    - read atbootyn
    - if [ "$atbootyn" = "y" -o "$atbootyn" = "Y" ]; then
    - atboot=1
    - fi
    - else
    - echo "Webmin does not support being started at boot time on your system."
    - fi
    - fi
    + #if [ "$atboot" = "" ]; then
    + # initsupp=`grep "^os_support=" "$srcdir/init/module.info" | sed -e 's/os_support=//g' | grep $os_type`
    + # atboot=0
    + # if [ "$initsupp" != "" ]; then
    + # printf "Start Webmin at boot time (y/n): "
    + # read atbootyn
    + # if [ "$atbootyn" = "y" -o "$atbootyn" = "Y" ]; then
    + # atboot=1
    + # fi
    + # else
    + # echo "Webmin does not support being started at boot time on your system."
    + # fi
    + #fi
    + #user has to decide this for him/herself
    + atboot=0
    makeboot=$atboot
    # Copy files to target directory
    echo "***********************************************************************"
    - if [ "$wadir" != "$srcdir" ]; then
    - echo "Copying files to $wadir .."
    - (cd "$srcdir" ; tar cf - . | (cd "$wadir" ; tar xf -))
    + if [ "$DESTDIR$wadir" != "$srcdir" ]; then
    + echo "Copying files to $DESTDIR$wadir .."
    + (cd "$srcdir" ; tar cf - . | (cd "$DESTDIR$wadir" ; tar xf -))
    echo "..done"
    echo ""
    fi
    # Create webserver config file
    - echo $perl > $config_dir/perl-path
    - echo $var_dir > $config_dir/var-path
    + echo $perl > $DESTDIR$config_dir/perl-path
    + echo $var_dir > $DESTDIR$config_dir/var-path
    echo "Creating web server config files.."
    cfile=$config_dir/miniserv.conf
    - echo "port=$port" >> $cfile
    - echo "root=$wadir" >> $cfile
    - echo "mimetypes=$wadir/mime.types" >> $cfile
    - echo "addtype_cgi=internal/cgi" >> $cfile
    - echo "realm=Webmin Server" >> $cfile
    - echo "logfile=$var_dir/miniserv.log" >> $cfile
    - echo "errorlog=$var_dir/miniserv.error" >> $cfile
    - echo "pidfile=$var_dir/miniserv.pid" >> $cfile
    - echo "logtime=168" >> $cfile
    - echo "ppath=$ppath" >> $cfile
    - echo "ssl=$ssl" >> $cfile
    - echo "env_WEBMIN_CONFIG=$config_dir" >> $cfile
    - echo "env_WEBMIN_VAR=$var_dir" >> $cfile
    - echo "atboot=$atboot" >> $cfile
    - echo "logout=$config_dir/logout-flag" >> $cfile
    - echo "listen=10000" >> $cfile
    - echo "denyfile=\.pl$" >> $cfile
    - echo "log=1" >> $cfile
    - echo "blockhost_failures=5" >> $cfile
    - echo "blockhost_time=60" >> $cfile
    - echo "syslog=1" >> $cfile
    + echo "port=$port" >> $DESTDIR$cfile
    + echo "root=$wadir" >> $DESTDIR$cfile
    + echo "mimetypes=$wadir/mime.types" >> $DESTDIR$cfile
    + echo "addtype_cgi=internal/cgi" >> $DESTDIR$cfile
    + echo "realm=Webmin Server" >> $DESTDIR$cfile
    + echo "logfile=$log_dir/miniserv.log" >> $DESTDIR$cfile
    + echo "errorlog=$log_dir/miniserv.error" >> $DESTDIR$cfile
    + echo "pidfile=$pid_dir/miniserv.pid" >> $DESTDIR$cfile
    + echo "logtime=168" >> $DESTDIR$cfile
    + echo "ppath=$ppath" >> $DESTDIR$cfile
    + echo "ssl=$ssl" >> $DESTDIR$cfile
    + echo "env_WEBMIN_CONFIG=$config_dir" >> $DESTDIR$cfile
    + echo "env_WEBMIN_VAR=$var_dir" >> $DESTDIR$cfile
    + echo "atboot=$atboot" >> $DESTDIR$cfile
    + echo "logout=$config_dir/logout-flag" >> $DESTDIR$cfile
    + echo "listen=10000" >> $DESTDIR$cfile
    + echo "denyfile=\.pl$" >> $DESTDIR$cfile
    + echo "log=1" >> $DESTDIR$cfile
    + echo "blockhost_failures=5" >> $DESTDIR$cfile
    + echo "blockhost_time=60" >> $DESTDIR$cfile
    + echo "syslog=1" >> $DESTDIR$cfile
    if [ "$allow" != "" ]; then
    - echo "allow=$allow" >> $cfile
    + echo "allow=$allow" >> $DESTDIR$cfile
    fi
    if [ "$session" != "" ]; then
    - echo "session=$session" >> $cfile
    + echo "session=$session" >> $DESTDIR$cfile
    else
    - echo "session=1" >> $cfile
    + echo "session=1" >> $DESTDIR$cfile
    fi
    if [ "$pam" != "" ]; then
    - echo "pam=$pam" >> $cfile
    + echo "pam=$pam" >> $DESTDIR$cfile
    fi
    md5pass=`$perl -e 'print crypt("test", "\$1\$A9wB3O18\$zaZgqrEmb9VNltWTL454R/") eq "\$1\$A9wB3O18\$zaZgqrEmb9VNltWTL454R/" ? "1n" : "0n"'`
    ufile=$config_dir/miniserv.users
    if [ "$crypt" != "" ]; then
    - echo "$login:$crypt:0" > $ufile
    + echo "$login:$crypt:0" > $DESTDIR$ufile
    else
    if [ "$md5pass" = "1" ]; then
    - $perl -e 'print "$ARGV[0]:",crypt($ARGV[1], "$1$XXXXXXXX"),":0n"' "$login" "$password" > $ufile
    + $perl -e 'print "$ARGV[0]:",crypt($ARGV[1], "$1$XXXXXXXX"),":0n"' "$login" "$password" > $DESTDIR$ufile
    else
    - $perl -e 'print "$ARGV[0]:",crypt($ARGV[1], "XX"),":0n"' "$login" "$password" > $ufile
    + $perl -e 'print "$ARGV[0]:",crypt($ARGV[1], "XX"),":0n"' "$login" "$password" > $DESTDIR$ufile
    fi
    fi
    - chmod 600 $ufile
    - echo "userfile=$ufile" >> $cfile
    + chmod 600 $DESTDIR$ufile
    + echo "userfile=$ufile" >> $DESTDIR$cfile
    kfile=$config_dir/miniserv.pem
    openssl version >/dev/null 2>&1
    @@ -517,74 +577,74 @@
    root@$host
    EOF
    if [ "$?" = "0" ]; then
    - cat $tempdir/cert $tempdir/key >$kfile
    + cat $tempdir/cert $tempdir/key >$DESTDIR$kfile
    fi
    rm -f $tempdir/cert $tempdir/key
    fi
    if [ ! -r $kfile ]; then
    # Fall back to the built-in key
    - cp "$wadir/miniserv.pem" $kfile
    + cp "$DESTDIR$wadir/miniserv.pem" $DESTDIR$kfile
    fi
    - chmod 600 $kfile
    - echo "keyfile=$config_dir/miniserv.pem" >> $cfile
    + chmod 600 $DESTDIR$kfile
    + echo "keyfile=$config_dir/miniserv.pem" >> $DESTDIR$cfile
    - chmod 600 $cfile
    + chmod 600 $DESTDIR$cfile
    echo "..done"
    echo ""
    echo "Creating access control file.."
    afile=$config_dir/webmin.acl
    - rm -f $afile
    + rm -f $DESTDIR$afile
    if [ "$defaultmods" = "" ]; then
    - echo "$login: $allmods" >> $afile
    + echo "$login: $allmods" >> $DESTDIR$afile
    else
    - echo "$login: $defaultmods" >> $afile
    + echo "$login: $defaultmods" >> $DESTDIR$afile
    fi
    - chmod 600 $afile
    + chmod 600 $DESTDIR$afile
    echo "..done"
    echo ""
    if [ "$login" != "root" -a "$login" != "admin" ]; then
    # Allow use of RPC by this user
    - echo rpc=1 >>$config_dir/$login.acl
    + echo rpc=1 >>$DESTDIR$config_dir/$login.acl
    fi
    fi
    if [ "$noperlpath" = "" ]; then
    echo "Inserting path to perl into scripts.."
    - (find "$wadir" -name '*.cgi' -print ; find "$wadir" -name '*.pl' -print) | $perl "$wadir/perlpath.pl" $perl -
    + (find "$DESTDIR$wadir" -name '*.cgi' -print ; find "$DESTDIR$wadir" -name '*.pl' -print) | $perl "$DESTDIR$wadir/perlpath.pl" $perl -
    echo "..done"
    echo ""
    fi
    echo "Creating start and stop scripts.."
    -rm -f $config_dir/stop $config_dir/start $config_dir/restart
    -echo "#!/bin/sh" >>$config_dir/start
    -echo "echo Starting Webmin server in $wadir" >>$config_dir/start
    -echo "trap '' 1" >>$config_dir/start
    -echo "LANG=" >>$config_dir/start
    -echo "export LANG" >>$config_dir/start
    -echo "#PERLIO=:raw" >>$config_dir/start
    -echo "unset PERLIO" >>$config_dir/start
    -echo "export PERLIO" >>$config_dir/start
    -echo "PERLLIB=$PERLLIB" >>$config_dir/start
    -echo "export PERLLIB" >>$config_dir/start
    +rm -f $DESTDIR$config_dir/stop $DESTDIR$config_dir/start $DESTDIR$config_dir/restart
    +echo "#!/bin/sh" >>$DESTDIR$config_dir/start
    +echo "echo Starting Webmin server in $wadir" >>$DESTDIR$config_dir/start
    +echo "trap '' 1" >>$DESTDIR$config_dir/start
    +echo "LANG=" >>$DESTDIR$config_dir/start
    +echo "export LANG" >>$DESTDIR$config_dir/start
    +echo "#PERLIO=:raw" >>$DESTDIR$config_dir/start
    +echo "unset PERLIO" >>$DESTDIR$config_dir/start
    +echo "export PERLIO" >>$DESTDIR$config_dir/start
    +echo "PERLLIB=$PERLLIB" >>$DESTDIR$config_dir/start
    +echo "export PERLLIB" >>$DESTDIR$config_dir/start
    uname -a | grep -i 'HP/*UX' >/dev/null
    if [ $? = "0" ]; then
    - echo "exec '$wadir/miniserv.pl' $config_dir/miniserv.conf &" >>$config_dir/start
    + echo "exec '$wadir/miniserv.pl' $config_dir/miniserv.conf &" >>$DESTDIR$config_dir/start
    else
    - echo "exec '$wadir/miniserv.pl' $config_dir/miniserv.conf" >>$config_dir/start
    + echo "exec '$wadir/miniserv.pl' $config_dir/miniserv.conf" >>$DESTDIR$config_dir/start
    fi
    -echo "#!/bin/sh" >>$config_dir/stop
    -echo "echo Stopping Webmin server in $wadir" >>$config_dir/stop
    -echo "pidfile=`grep "^pidfile=" $config_dir/miniserv.conf | sed -e 's/pidfile=//g'`" >>$config_dir/stop
    -echo "kill `cat $pidfile`" >>$config_dir/stop
    +echo "#!/bin/sh" >>$DESTDIR$config_dir/stop
    +echo "echo Stopping Webmin server in $wadir" >>$DESTDIR$config_dir/stop
    +echo "pidfile=`grep "^pidfile=" $config_dir/miniserv.conf | sed -e 's/pidfile=//g'`" >>$DESTDIR$config_dir/stop
    +echo "kill `cat $pidfile`" >>$DESTDIR$config_dir/stop
    -echo "#!/bin/sh" >>$config_dir/restart
    -echo "$config_dir/stop && $config_dir/start" >>$config_dir/restart
    +echo "#!/bin/sh" >>$DESTDIR$config_dir/restart
    +echo "$config_dir/stop && $config_dir/start" >>$DESTDIR$config_dir/restart
    -chmod 755 $config_dir/start $config_dir/stop
    +chmod 755 $DESTDIR$config_dir/start $DESTDIR$config_dir/stop
    echo "..done"
    echo ""
    @@ -593,13 +653,13 @@
    else
    echo "Copying config files.."
    fi
    -$perl "$wadir/copyconfig.pl" "$os_type" "$os_version" "$wadir" $config_dir "" $allmods
    +$perl "$DESTDIR$wadir/copyconfig.pl" "$os_type" "$os_version" "$wadir" $config_dir "$DESTDIR" "" $allmods
    if [ "$upgrading" != 1 ]; then
    # Store the OS and version
    - echo "os_type=$os_type" >> $config_dir/config
    - echo "os_version=$os_version" >> $config_dir/config
    - echo "real_os_type=$real_os_type" >> $config_dir/config
    - echo "real_os_version=$real_os_version" >> $config_dir/config
    + echo "os_type=$os_type" >> $DESTDIR$config_dir/config
    + echo "os_version=$os_version" >> $DESTDIR$config_dir/config
    + echo "real_os_type=$real_os_type" >> $DESTDIR$config_dir/config
    + echo "real_os_version=$real_os_version" >> $DESTDIR$config_dir/config
    if [ -r /etc/system.cnf ]; then
    # Found a caldera system config file .. get the language
    source /etc/system.cnf
    @@ -608,61 +668,62 @@
    elif [ "$CONF_LST_LANG" = "uk" ]; then
    CONF_LST_LANG=en
    fi
    - grep "lang=$CONF_LST_LANG," "$wadir/lang_list.txt" >/dev/null 2>&1
    + grep "lang=$CONF_LST_LANG," "$DESTDIR$wadir/lang_list.txt" >/dev/null 2>&1
    if [ "$?" = 0 ]; then
    - echo "lang=$CONF_LST_LANG" >> $config_dir/config
    + echo "lang=$CONF_LST_LANG" >> $DESTDIR$config_dir/config
    fi
    fi
    # Turn on logging by default
    - echo "log=1" >> $config_dir/config
    + echo "log=1" >> $DESTDIR$config_dir/config
    else
    # one-off hack to set log variable in config from miniserv.conf
    - grep log= $config_dir/config >/dev/null
    + grep log= $DESTDIR$config_dir/config >/dev/null
    if [ "$?" = "1" ]; then
    - grep log= $config_dir/miniserv.conf >> $config_dir/config
    - grep logtime= $config_dir/miniserv.conf >> $config_dir/config
    - grep logclear= $config_dir/miniserv.conf >> $config_dir/config
    + grep log= $DESTDIR$config_dir/miniserv.conf >> $DESTDIR$config_dir/config
    + grep logtime= $DESTDIR$config_dir/miniserv.conf >> $DESTDIR$config_dir/config
    + grep logclear= $DESTDIR$config_dir/miniserv.conf >> $DESTDIR$config_dir/config
    fi
    fi
    -echo $ver > $config_dir/version
    +echo $ver > $DESTDIR$config_dir/version
    echo "..done"
    echo ""
    # Set passwd_ fields in miniserv.conf from global config
    for field in passwd_file passwd_uindex passwd_pindex passwd_cindex passwd_mindex; do
    - grep $field= $config_dir/miniserv.conf >/dev/null
    + grep $field= $DESTDIR$config_dir/miniserv.conf >/dev/null
    if [ "$?" != "0" ]; then
    - grep $field= $config_dir/config >> $config_dir/miniserv.conf
    + grep $field= $DESTDIR$config_dir/config >> $DESTDIR$config_dir/miniserv.conf
    fi
    done
    -grep passwd_mode= $config_dir/miniserv.conf >/dev/null
    +grep passwd_mode= $DESTDIR$config_dir/miniserv.conf >/dev/null
    if [ "$?" != "0" ]; then
    - echo passwd_mode=0 >> $config_dir/miniserv.conf
    + echo passwd_mode=0 >> $DESTDIR$config_dir/miniserv.conf
    fi
    # If Perl crypt supports MD5, then make it the default
    if [ "$md5pass" = "1" ]; then
    - echo md5pass=1 >> $config_dir/config
    + echo md5pass=1 >> $DESTDIR$config_dir/config
    fi
    # Set a special theme if none was set before
    if [ "$theme" = "" ]; then
    - theme=`cat "$wadir/defaulttheme" 2>/dev/null`
    + theme=`cat "$DESTDIR$wadir/defaulttheme" 2>/dev/null`
    fi
    -oldthemeline=`grep "^theme=" $config_dir/config`
    +oldthemeline=`grep "^theme=" $DESTDIR$config_dir/config`
    oldtheme=`echo $oldthemeline | sed -e 's/theme=//g'`
    -if [ "$theme" != "" ] && [ "$oldthemeline" = "" ] && [ -d "$wadir/$theme" ]; then
    - echo "theme=$theme" >> $config_dir/config
    - echo "preroot=$theme" >> $config_dir/miniserv.conf
    +if [ "$theme" != "" ] && [ "$oldthemeline" = "" ] && [ -d "$DESTDIR$wadir/$theme" ]; then
    + echo "theme=$theme" >> $DESTDIR$config_dir/config
    + echo "preroot=$theme" >> $DESTDIR$config_dir/miniserv.conf
    fi
    # Set the product field in the global config
    -grep product= $config_dir/config >/dev/null
    +grep product= $DESTDIR$config_dir/config >/dev/null
    if [ "$?" != "0" ]; then
    - echo product=webmin >> $config_dir/config
    + echo product=webmin >> $DESTDIR$config_dir/config
    fi
    +#I disbled makeboot. If enabled, then $DESTIDIR needs tp be added to this section
    if [ "$makeboot" = "1" ]; then
    echo "Configuring Webmin to start at boot time.."
    (cd "$wadir/init" ; WEBMIN_CONFIG=$config_dir WEBMIN_VAR=$var_dir "$wadir/init/atboot.pl")
    @@ -671,8 +732,8 @@
    fi
    if [ "$nouninstall" = "" ]; then
    - echo "Creating uninstall script $config_dir/uninstall.sh .."
    - cat >$config_dir/uninstall.sh <<EOF
    + echo "Creating uninstall script $DESTDIR$config_dir/uninstall.sh .."
    + cat >$DESTDIR$config_dir/uninstall.sh <<EOF
    #!/bin/sh
    printf "Are you sure you want to uninstall Webmin? (y/n) : "
    read answer
    @@ -688,89 +749,91 @@
    echo "Done!"
    fi
    EOF
    - chmod +x $config_dir/uninstall.sh
    + chmod +x $DESTDIR$config_dir/uninstall.sh
    echo "..done"
    echo ""
    fi
    echo "Changing ownership and permissions .."
    -chown -R root $config_dir
    -chgrp -R bin $config_dir
    -chmod -R og-rw $config_dir
    -chmod 755 $config_dir/{sendmail,qmailadmin,postfix}*/config >/dev/null 2>&1
    -chmod 755 $config_dir/{sendmail,qmailadmin,postfix}*/autoreply.pl >/dev/null 2>&1
    -chmod 755 $config_dir/{sendmail,qmailadmin,postfix}*/filter.pl >/dev/null 2>&1
    -chmod 755 $config_dir/squid*/squid-auth.pl >/dev/null 2>&1
    -chmod 755 $config_dir/squid*/users >/dev/null 2>&1
    -chmod +r $config_dir/version
    +chown -R root $DESTDIR$config_dir
    +chgrp -R bin $DESTDIR$config_dir
    +chmod -R og-rw $DESTDIR$config_dir
    +chmod 755 $DESTDIR$config_dir/{sendmail,qmailadmin,postfix}*/config >/dev/null 2>&1
    +chmod 755 $DESTDIR$config_dir/{sendmail,qmailadmin,postfix}*/autoreply.pl >/dev/null 2>&1
    +chmod 755 $DESTDIR$config_dir/{sendmail,qmailadmin,postfix}*/filter.pl >/dev/null 2>&1
    +chmod 755 $DESTDIR$config_dir/squid*/squid-auth.pl >/dev/null 2>&1
    +chmod 755 $DESTDIR$config_dir/squid*/users >/dev/null 2>&1
    +chmod +r $DESTDIR$config_dir/version
    if [ "$nochown" = "" ]; then
    - chown -R root "$wadir"
    - chgrp -R bin "$wadir"
    - chmod -R og-w "$wadir"
    - chmod -R a+rx "$wadir"
    -fi
    -if [ $var_dir != "/var" ]; then
    - chown -R root $var_dir
    - chgrp -R bin $var_dir
    - chmod -R og-rwx $var_dir
    + chown -R root "$DESTDIR$wadir"
    + chgrp -R bin "$DESTDIR$wadir"
    + chmod -R og-w "$DESTDIR$wadir"
    + chmod -R a+rx "$DESTDIR$wadir"
    +fi
    +if [ $DESTDIR$var_dir != "/var" ]; then
    + chown -R root $DESTDIR$var_dir
    + chgrp -R bin $DESTDIR$var_dir
    + chmod -R og-rwx $DESTDIR$var_dir
    fi
    echo "..done"
    echo ""
    # Save target directory if one was specified
    -if [ "$wadir" != "$srcdir" ]; then
    - echo $wadir >$config_dir/install-dir
    +if [ "$DESTDIR$wadir" != "$srcdir" ]; then
    + echo $wadir >$DESTDIR$config_dir/install-dir
    else
    - rm -f $config_dir/install-dir
    + rm -f $DESTDIR$config_dir/install-dir
    fi
    -if [ "$nopostinstall" = "" ]; then
    - echo "Running postinstall scripts .."
    - (cd "$wadir" ; WEBMIN_CONFIG=$config_dir WEBMIN_VAR=$var_dir "$wadir/run-postinstalls.pl")
    - echo "..done"
    - echo ""
    -fi
    +#This is not for now ... this is for in the install-script
    +#if [ "$nopostinstall" = "" ]; then
    +# echo "Running postinstall scripts .."
    +# (cd "$wadir" ; WEBMIN_CONFIG=$config_dir WEBMIN_VAR=$var_dir "$wadir/run-postinstalls.pl")
    +# echo "..done"
    +# echo ""
    +#fi
    # Run package-defined post-install script
    -if [ -r "$srcdir/setup-post.sh" ]; then
    - . "$srcdir/setup-post.sh"
    -fi
    -if [ "$nostart" = "" ]; then
    - if [ "$inetd" != "1" ]; then
    - echo "Attempting to start Webmin mini web server.."
    - $config_dir/start
    - if [ $? != "0" ]; then
    - echo "ERROR: Failed to start web server!"
    - echo ""
    - exit 14
    - fi
    - echo "..done"
    - echo ""
    - fi
    - echo "***********************************************************************"
    - echo "Webmin has been installed and started successfully. Use your web"
    - echo "browser to go to"
    - echo ""
    - host=`hostname`
    - if [ "$ssl" = "1" ]; then
    - echo " https://$host:$port/"
    - else
    - echo " http://$host:$port/"
    - fi
    - echo ""
    - echo "and login with the name and password you entered previously."
    - echo ""
    - if [ "$ssl" = "1" ]; then
    - echo "Because Webmin uses SSL for encryption only, the certificate"
    - echo "it uses is not signed by one of the recognized CAs such as"
    - echo "Verisign. When you first connect to the Webmin server, your"
    - echo "browser will ask you if you want to accept the certificate"
    - echo "presented, as it does not recognize the CA. Say yes."
    - echo ""
    - fi
    -fi
    +#if [ -r "$srcdir/setup-post.sh" ]; then
    +# . "$srcdir/setup-post.sh"
    +#fi
    +
    +#don't start the webserver
    +#if [ "$nostart" = "" ]; then
    +# if [ "$inetd" != "1" ]; then
    +# echo "Attempting to start Webmin mini web server.."
    +# $config_dir/start
    +# if [ $? != "0" ]; then
    +# echo "ERROR: Failed to start web server!"
    +# echo ""
    +# exit 14
    +# fi
    +# echo "..done"
    +# echo ""
    +# fi
    +
    +# echo "***********************************************************************"
    +# echo "Webmin has been installed and started successfully. Use your web"
    +# echo "browser to go to"
    +# echo ""
    +# host=`hostname`
    +# if [ "$ssl" = "1" ]; then
    +# echo " https://$host:$port/"
    +# else
    +# echo " http://$host:$port/"
    +# fi
    +# echo ""
    +# echo "and login with the name and password you entered previously."
    +# echo ""
    +# if [ "$ssl" = "1" ]; then
    +# echo "Because Webmin uses SSL for encryption only, the certificate"
    +# echo "it uses is not signed by one of the recognized CAs such as"
    +# echo "Verisign. When you first connect to the Webmin server, your"
    +# echo "browser will ask you if you want to accept the certificate"
    +# echo "presented, as it does not recognize the CA. Say yes."
    +# echo ""
    +# fi
    +#fi
    if [ "$oldwadir" != "$wadir" -a "$upgrading" = 1 -a "$deletedold" != 1 ]; then
    echo "The directory from the previous version of Webmin"
    copyconfig.pl.patch:
    --- copyconfig.pl 2004-12-02 23:17:37.000000000 +0100
    +++ copyconfig-new.pl 2004-12-03 01:00:26.000000000 +0100
    @@ -9,12 +9,13 @@
    $ver = $ARGV[1];
    $wadir = $ARGV[2];
    $confdir = $ARGV[3];
    +$DESTDIR = $ARGV[4];
    # Find all clones
    -opendir(DIR, $wadir);
    +opendir(DIR, $DESTDIR.$wadir);
    foreach $f (readdir(DIR)) {
    - if (readlink("$wadir/$f")) {
    - @st = stat("$wadir/$f");
    + if (readlink("$DESTDIR.$wadir/$f")) {
    + @st = stat("$DESTDIR.$wadir/$f");
    push(@{$clone{$st[1]}}, $f);
    @@ -24,7 +25,7 @@
    @mods = @ARGV[4..$#ARGV];
    foreach $m (@mods) {
    # Find any range-number config files
    - $srcdir = "$wadir/$m";
    + $srcdir = "$DESTDIR.$wadir/$m";
    $rangefile = undef;
    opendir(DIR, $srcdir);
    while($f = readdir(DIR)) {

    Goto settings general usage there u will see your apps and under documents &amp;data u will see wot each app uses, the only way to get rid of it is by deleting the app and reinstalling this will free up space..

Maybe you are looking for

  • CMD Tab not switching to apps in different Spaces

    This has been a problem in the past and looks like it's still lingering in Mavericks. Yes I do have the Preferences option set btw I think it seems to be triggered for me when disconnecting my external monitor (connected via Thunderolt aka MiniDispla

  • External mic won;t work

    imovie won't record voice over using my Plantonics USB mic. It worked on my last project several months ago I've checked prefs and its selected input and output... I'm stumped

  • I am going to go to hong kong and i 've got a ipod nano 1.generation

    like the title, i want attend ipod nano 1.generation changing program(something like this) i dont attend this program from my country because i'm living in Turkey, there isn't any Apple Store and on the website of apple, there isn't any information a

  • Message types for ALE distribution

    Hi, I am working on SRM 7.0. I need to copy the org structure from one client to another. For that I am using the ALE distribution model. Can anyone please let me know all the message types reqired for transferring the org structure. Thanks, Bhakti

  • Slideshow geeks needed

    I know one of us geeks has created an amazing slideshow not made by the Apple guys. Can someone pass the info from their monstrous cranium to my sub-standard prozaic sponge? But seriously. I've seen a few decent Flash slideshows, but I don't have Fla